Commit Graph

57 Commits (9654b4dfb122b54b04369fe80a2f9c95811478e8)

Author SHA1 Message Date
Gabriel Luong 9654b4dfb1 For #27667 - Remove import-ordering from the list of disabled ktlint rules 2 years ago
mcarare ffcef5ff2e For #26844: Fix ktlint issues and remove them from baseline. 2 years ago
mcarare 68f71c6f1d For #24761: Remove wrapper from autoplay settings metrics. 2 years ago
mike a a0f02b27be Closes #24276: add documentation to classes marked as UndocumentedPublicClass by lint 2 years ago
mike a 5b481ad204 Closes #24276:
– make comments inside HistoryDataSource capitalized and informative
– remove scroll to first item in swipe-to-refresh
– change adapter initialization
– fixed SitePermissionsExceptionsFragment flickering empty state
2 years ago
mike a be3c53a73c Closes #24276: removed deprecated paging from SitePermissionsExceptionsFragment 2 years ago
mike a 7b5d3181df Closes #24276: updating pagination library, changing history related classes 2 years ago
Gabriel Luong 331dc3a8ec For #24252 - Rename secondaryText attribute to textSecondary 2 years ago
Alexandru2909 7e1edc828e For #23719 - Replace preference framework strings with string resources 2 years ago
Geordan Neukum 23036680c2 For #16395 - Use Secondary Text for the Site Permissions subtext 2 years ago
Arturo Mejia 277e94881b For #22995: Address crash when switching languages. 2 years ago
Mugurell 34c0a17b4d For #22852 - Add a new "Storage access" permission 3 years ago
Gabriel Luong 76c746b982 For #21776 - Remove unnecessary type argument 3 years ago
Gabriel Luong 1039a92281 For #21776 - Remove reductant SAM constructor 3 years ago
Sebastian Kaspari 971b419d77 Run ktlintFormat to adapt to latest formatting rules. 3 years ago
mcarare cca7892e91 For #17917: Use View binding in settings screens. 3 years ago
Roger Yang 74c1cc82fb Closes #19921: Update appcompat and fragment dependencies to 1.3.x 3 years ago
Arturo Mejia 251bfc7fe9 Improvements to site permissions 3 years ago
Arturo Mejia 2f879f8e9d Fix site permissions breaking changes 3 years ago
MarcLeclair 990bfa7e6d
16900 make navgraph inflation asynchronous (#18889)
* For #16900: implement async navgraph inflation

For #16900: removed nav graph from xml

For #16900: inflate navGraph programatically

For #16900: Made NavGraph inflation asynchronous

For #16900: Changed to block with runBlocking

For #16900: Refactored blocking call into a function

For 16900: NavGraph inflation is now async

We now attach the nav graph (or check if its attached) on every nav call ( an extension function for NavController).
This is done by checking the value of the job stored in PerfNavController.map which keeps track of the job with the NavController as a Key.
If the job hasn't been completed, it will block the main thread until the job is done. The job itself is responsible for attaching the navgraph
to the navcontroller (and the inflation of the latter too)

For 16900: rebased upstream master

For 16900: Rebase on master

For #16900: Fixed Async Navgraph navigation per review comments.

1)The Asynchronous method is now found in NavGraphProvider.kt. It creates a job on the IO dispatcher
2)The Job is tracked through a WeakHashMap from Controller --> NavGraph
3)The Coroutine scope doesn't use MainScope() anymore
4)The Coroutine is cancelled if the Activity is destroyed
5)The tests mockk the blockForNavGraphInflation method through the FenixReoboelectricTestApplication instead of calling the mock every setup()

For #16900: inflateNavGraphAsync now takes navController

For #16900: Pass lifecycleScope to NavGraphProvider

For #16900: removed unused mock

For #16900: Added linter rules for navigate calls

We need linting rules to make sure no one calls the NavController.navigate() methods

For #16900: Added TestRule to help abstract the mocks in the code

For 16900: Fix linting problems

For #16900: Cleaned duplicated code in tests

For #16900: cleaned up NavGraphTestRule for finished test

For #16900: had to revert an accidentally edited file

For #16900: rebased master

* For #16900: Review nits for async navgraph

This is composed of squash commits, the original messages can be found below:

-> DisableNavGraphProviderAssertionRule + kdoc.

Use test rule in RobolectricApplication.

Fix failing CrashReporterControllerTest

Fix blame by -> navigate in tests.

This commit was generated by the following commands only:
```
find app/src/test -type f -exec sed -i '' "/import org.mozilla.fenix.ext.navigateBlockingForAsyncNavGraph/d" {} \;
find app/src/test -type f -exec sed -i "" "s/navigateBlockingForAsyncNavGraph/navigate/g" {} \;
git checkout app/src/test/resources/mockito-extensions/org.mockito.plugins.MockMaker
```

Fix various blame

This is expected to be squashed into the first commit so, if so, it'd
fix the blame.

Move test rule to helpers pkg.

add missing license header

Add import change I missed

fix unused imports

Replace robolectricTestrunner with test rule.

Improve navGraphProvider docs

Remove unnecessary rule as defined by robolectric.

add clarifying comment to robolectric

remove unnecessary space

* For #16900: nit fixes for MozillaNavigateCheck and lint fixes

3 squash commits:
 *Changed violation message and fixed the lint rule for MozillaNavigateCheck
 *Added suppression to NavController.kt
 *Fixed detekt violations

* For 16900: Fixed failing tests

Co-authored-by: Michael Comella <michael.l.comella@gmail.com>
3 years ago
Arturo Mejia 8ca9f94abb For issue #16557 set autoplay block audio only
by default
3 years ago
Arturo Mejia 0e8dc6164d Target Android 11 3 years ago
Christian Sadilek 3dc638700f Refactor tryReloadTabBy to use browser store 3 years ago
Arturo Mejia b9bdc288cb For issue: #16846 Add ui for controlling exceptions for auto play 3 years ago
Arturo Mejia f263b7333a For issue #16847 Show the autoplay icon in the toolbar 4 years ago
Emilio Cobos Álvarez 9d5afd501e Add support for EME permission.
This accompanies the changes in mozilla-mobile/android-components#9121.

Closes #1175
4 years ago
Jonathan Almeida 666781aa62 Fix lint warnings and test in site permissions 4 years ago
Arturo Mejia de521192e0 Add support for local storage permission 4 years ago
Grisha Kruglov 51dab196c4 Closes #15443: Use fragment's lifecycleScope for AlertDialog actions 4 years ago
Tiger Oakes 113241e8ce
Enforce IO thread inside of components (#14704)
* Automatically run PermissionStorage on IO thread

* Run TabCollectionStorage on dedicated scope + IO

* Update findSitePermissionsBy calls
4 years ago
Tiger Oakes a8291bf641
Remove un-needed nullables (#13816) 4 years ago
Jeff Boek 12b95b4902 For #11579 - Adds telemetry for autoplay settings in Site Permissions 4 years ago
Tiger Oakes 1ab5fe3eb9
Add method to test fragments in roboletric (#12261) 4 years ago
ekager 06e6cfa696 For #5636 - Unregisters wifiConnectedListener when setting changes, sets default blocked 4 years ago
Tiger Oakes c503798cd6 Replace PhoneFeature.getPreferenceKey 4 years ago
Tiger Oakes 45ef88f6b9 Replace requireNotNull(findPreference()) 4 years ago
Tiger Oakes 1a19b06227
Simplify `PhoneFeature` code (#10810) 4 years ago
ekager 7fe6f68e00 For #10485 - Restore block video/audio on cellular data radio button 4 years ago
Simon Chae a851b76ea3
Update Android Components version to 41.0.20200506130132 (#10443) 4 years ago
Arturo Mejia 956bf01cd5 For issue #9493: Reload after cleaning individual site permissions exceptions 4 years ago
ekager c4e83367f6 For #6832 - Fix various fragment not attached to a context crashes 4 years ago
Arturo Mejia 995da59fa8 For issue #9493: Reload after cleaning all site permissions exceptions 4 years ago
Arturo Mejia f9cc2ccfe2 For issue #8017 enable SitePermissionsWifiIntegration 4 years ago
Arturo Mejia fa9dae0d72 For issue #9364 Crash when blocking app permissions and returning to
the app
4 years ago
Severin Rudie 35a132d7ff
8017 advanced autoplay controls. (#8978)
* For #8017: add advanced autoplay controls
4 years ago
Severin Rudie 69c6de7cd4
For #8411: integrate AC permissions changes (#8618) 4 years ago
Sebastian Kaspari f0af6d6f6e Update Mozilla Android Components to 32.0.0-SNAPSHOT. 4 years ago
Sawyer Blatz 0a6881d470
For #255: Removes autoplay media feature flag (#8198) 4 years ago
Tiger Oakes c0d7bc5bd5 Use navArgs helper in fragments 4 years ago
Emma Malysz 5e9b753acb For #7473, delay inflation of toolbar
Improve performance of HomeActivity.onCreate by delaying this inflation.
We use a ViewStub and inflate the first time the actionbar is accessed.
4 years ago