Using `onNextLayout` has the side-effect of showing the thumbnail with
the tab.id from a recycled view.
The root cause of needing that call is to retrieve the measured
height/width from the view first before requesting. A simpler solution
to avoid the complexity is to retrieve these values from the dimen
resources.
Co-authored-by: Gabriel Luong <gabriel.luong@gmail.com>
Following user requests and UX recommendations we'll have all menus have a
dynamic width between 112dp and 314dp, automatically wrapping the widest
element.
* Set edit text listeners
* Set clearable icons and change with error states
* Clear text buttons show and hide
* Move error checks to afterTextChanged. Refactor. Remove unused color.
Currently we support sorting by name and by last used. Also, the selected
option is saved in shared preferences so that the last option chosen by
the user is properly displayed even after the app was restarted.
Created a dimension for the correct height that the EditText in the
fragment_edit_bookmark.xml has to have.
Co-authored-by: DrCesar <josuejacobstercero@gmail.com>
Instead of having a fixed width of 250dp the BrowserMenu will now have a
dynamic width between 250dp and 314dp allowing for a better fit for the menu
items it could display.
Added kapt plugin + dependencies in order to be able to use Room
Added recent apps to share fragment (top 6)
Extracted dimens of share_to_apps.xml in the dimens file
Reduced the margin start value of the progress bar in order to leave more space between it and the
text.
Moved hardcoded margin values into dimens resources.
* For #220
- Added advanced header + locale settings item in the settings fragment
* For #220
- Added locale selection page with lib state + handling of locale changes
* For #220
- Removed registering for locale changes in the manifest, allow system
to restart activity in that scenario
* For #220
- Added unit tests for locale settings page
* For #220: fixed an outdated unit test
ga-a
Co-authored-by: Severin Rudie <Baron-Severin@users.noreply.github.com>
* For #4281: small ToolbarMenu refactor
This makes it easier to see how items are ordered in the menuItems list
* For 4281: add QAB buttons to menu
* For 4281: removed menu back button per mocks
I double checked with UX, and we'll be relying on the hardware back button for its functionality
* For 4281: add content descriptions for bookmarking
* For 4281: updated BrowserToolbarController for new functionality
* For 4281: provided simple dependencies to browser controller
More complex changes will be in a following commit, for review readability
* For 4281: move toolbar controller dependencies up to BaseBrowserFragment
The functionality they control is being moved into the toolbar menu, which is shared by both normal tabs and custom ones
* For 4281: removed (now unused) code related to QAB
* For 4281: fix test compilation after QAB removal
Tests still need to be expanded to include added functionality
* For 4281: updated menu to show if url is bookmarked
This sloppy workaround is required because TwoStateButton requires that `isInPrimaryState` be a synchronous call, and checking whether or not the current site is bookmarked is quite slow (10-50 MS, in my tests). After days of work and many attempted solutions, this was the least abhorrent among them.
https://github.com/mozilla-mobile/android-components/issues/4915 was opened against AC to evaluate potentially supporting async `isInPrimaryState` functions.
https://github.com/mozilla-mobile/fenix/issues/6370 was opened against Fenix to investigate the unexpectedly slow call to `BookmarkStorage`.
* For 4281: update reader mode switch
* For 4281: selectively show/hide menu items
* For 4281: add reader mode appearance
* For 4281: update bookmark button when it is clicked
* For 4281: removed unused QAB code
* For 4281: removed QAB robot, updated UI tests
* For 4281: removed QuickActionSheet metrics
Since this behavior now lives in the toolbar, it is tracked via Event.BrowserMenuItemTapped
* For 4281: fixed lint errors
* For 4281: add new strings for buttons added to menu
This is necessary because the location change (from QAB to toolbar menu) could affect the grammar in some languages
* For 4281: remove outdated TODOs
* For 4281: removed QAB container
* For 4281: removed back button reference from UI test
This button no longer exists
* For 4821: Fixes a visual defect (extra padding on top of toolbar)
* For 4281: update copy on reader mode
* For 4281: fixed review nits