diff options
author | Docile-Alligator <25734209+Docile-Alligator@users.noreply.github.com> | 2024-08-20 17:09:27 +0000 |
---|---|---|
committer | Docile-Alligator <25734209+Docile-Alligator@users.noreply.github.com> | 2024-08-20 17:09:27 +0000 |
commit | 6b11f35f046bdd94ed8006ee2935aecdc96f4b23 (patch) | |
tree | 011b80c3c8e3d6d6e6a0da07abafbc36cbe01812 | |
parent | 88691c109ab59dace0082e1e264f89055ce8c65e (diff) | |
download | infinity-for-reddit-6b11f35f046bdd94ed8006ee2935aecdc96f4b23.tar infinity-for-reddit-6b11f35f046bdd94ed8006ee2935aecdc96f4b23.tar.gz infinity-for-reddit-6b11f35f046bdd94ed8006ee2935aecdc96f4b23.tar.bz2 infinity-for-reddit-6b11f35f046bdd94ed8006ee2935aecdc96f4b23.tar.lz infinity-for-reddit-6b11f35f046bdd94ed8006ee2935aecdc96f4b23.tar.xz infinity-for-reddit-6b11f35f046bdd94ed8006ee2935aecdc96f4b23.tar.zst infinity-for-reddit-6b11f35f046bdd94ed8006ee2935aecdc96f4b23.zip |
Show anonymous subscribed subreddits in CustomizePostFilterActivity.
-rw-r--r-- | app/src/main/java/ml/docilealligator/infinityforreddit/activities/CustomizePostFilterActivity.java | 16 |
1 files changed, 2 insertions, 14 deletions
diff --git a/app/src/main/java/ml/docilealligator/infinityforreddit/activities/CustomizePostFilterActivity.java b/app/src/main/java/ml/docilealligator/infinityforreddit/activities/CustomizePostFilterActivity.java index 67d3301f..d9df88d2 100644 --- a/app/src/main/java/ml/docilealligator/infinityforreddit/activities/CustomizePostFilterActivity.java +++ b/app/src/main/java/ml/docilealligator/infinityforreddit/activities/CustomizePostFilterActivity.java @@ -33,7 +33,6 @@ import javax.inject.Named; import ml.docilealligator.infinityforreddit.Infinity; import ml.docilealligator.infinityforreddit.R; import ml.docilealligator.infinityforreddit.RedditDataRoomDatabase; -import ml.docilealligator.infinityforreddit.account.Account; import ml.docilealligator.infinityforreddit.customtheme.CustomThemeWrapper; import ml.docilealligator.infinityforreddit.databinding.ActivityCustomizePostFilterBinding; import ml.docilealligator.infinityforreddit.postfilter.PostFilter; @@ -55,7 +54,6 @@ public class CustomizePostFilterActivity extends BaseActivity { private static final String POST_FILTER_STATE = "PFS"; private static final String ORIGINAL_NAME_STATE = "ONS"; private static final int ADD_SUBREDDITS_REQUEST_CODE = 1; - private static final int ADD_SUBREDDITS_ANONYMOUS_REQUEST_CODE = 2; private static final int ADD_USERS_REQUEST_CODE = 3; @Inject @@ -133,15 +131,8 @@ public class CustomizePostFilterActivity extends BaseActivity { }); binding.addSubredditsImageViewCustomizePostFilterActivity.setOnClickListener(view -> { - if (accountName.equals(Account.ANONYMOUS_ACCOUNT)) { - Intent intent = new Intent(this, SearchActivity.class); - intent.putExtra(SearchActivity.EXTRA_SEARCH_ONLY_SUBREDDITS, true); - intent.putExtra(SearchActivity.EXTRA_IS_MULTI_SELECTION, true); - startActivityForResult(intent, ADD_SUBREDDITS_ANONYMOUS_REQUEST_CODE); - } else { - Intent intent = new Intent(this, SubredditMultiselectionActivity.class); - startActivityForResult(intent, ADD_SUBREDDITS_REQUEST_CODE); - } + Intent intent = new Intent(this, SubredditMultiselectionActivity.class); + startActivityForResult(intent, ADD_SUBREDDITS_REQUEST_CODE); }); binding.addUsersImageViewCustomizePostFilterActivity.setOnClickListener(view -> { @@ -515,9 +506,6 @@ public class CustomizePostFilterActivity extends BaseActivity { if (requestCode == ADD_SUBREDDITS_REQUEST_CODE) { ArrayList<String> subredditNames = data.getStringArrayListExtra(SubredditMultiselectionActivity.EXTRA_RETURN_SELECTED_SUBREDDITS); updateExcludeSubredditNames(subredditNames); - } else if (requestCode == ADD_SUBREDDITS_ANONYMOUS_REQUEST_CODE) { - ArrayList<String> subredditNames = data.getStringArrayListExtra(SearchActivity.RETURN_EXTRA_SELECTED_SUBREDDIT_NAMES); - updateExcludeSubredditNames(subredditNames); } else if (requestCode == ADD_USERS_REQUEST_CODE) { ArrayList<String> usernames = data.getStringArrayListExtra(SearchActivity.RETURN_EXTRA_SELECTED_USERNAMES); String currentUsers = binding.excludesUsersTextInputEditTextCustomizePostFilterActivity.getText().toString().trim(); |