[DRAFT]: refactor(card-browser) extract menu to CardBrowserFragment#20211
Draft
david-allison wants to merge 13 commits intoankidroid:mainfrom
Draft
[DRAFT]: refactor(card-browser) extract menu to CardBrowserFragment#20211david-allison wants to merge 13 commits intoankidroid:mainfrom
david-allison wants to merge 13 commits intoankidroid:mainfrom
Conversation
to `R.id.action_preview_many` This ID was shared between two menus: `card_browser` and `note_editor` which will appear on the same screen This causes issues with menu APIs, as they expect distinct IDs: `menu.findItem(id)`; `menu.removeItem(id)` etc...
Handling fragments belongs in the Activity The rest of the logic should be pushed down
We previously had one provider for both single select and multiselect. This made logic difficult to reason about
Returning `true` stops further processing
5 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
MenuProvider#20208Purpose / Description
I want to move the
MenuHostto theSearchBarin the fragment for a redesignSome logic should still be in the activity (Navigation Drawer handling; fragment handling).
Actions on selected cards/notes are fragment-only
Search logic is going to be heavily refactored, with most of the menu items removed. Splitting it out now makes it easier to handle this case.
Fixes
Approach
See commits: lots of refactors
How Has This Been Tested?
Checklist