Commit Graph

1266 Commits (1f633edd7d4436f20ead4ba657b1284b94cca0c6)

Author SHA1 Message Date
Roger Yang c4347a9492 Closes #19847: Add telemetry for the default browser notification 3 years ago
Mugurell 1251894933 For #19933 - Show a media tab item on homescreen for the last tab with media 3 years ago
Mugurell f95567912f For #20229 - Use the AC common implementation for ads/search telemetry
Everything should work exactly as before.
3 years ago
Marc Leclair 298ec5cce1 For #19804: Restore logic to original behavior 3 years ago
Michael Comella 79fcbcba83 Closes #20127: fix app_received_intent extras.
Apparently, it had been using the wrong mapping this whole time. I can't
wrap my head around fenix's glean wrapper so I'm not sure if this
resulted in bugs or if my change changes the behavior. However, I don't
think anyone is using this probe so I'm requesting to remove it. If we
don't end up removing it, then we can check for bugs/changes in
behavior. This isn't ideal but I'd rather not spend the time on it if we
don't have to.
3 years ago
Michael Comella be64ee4159 For #20127: remove app_opened_all_startup integration. 3 years ago
Elise Richards 9bfe9b0787
For FNX-22339: Recently saved bookmarks (#19835)
* Title and button for home screen recently saved bookmarks section

Create bookmark item view with favicon and title

* View holders and interactors for recently saved bookmarks

Recent bookmark item view holder binding

Create adapter for recent bookmarks. Implement controller methods. Implement view holder bindings for items

Top level adapter for recent bookmarks section

Retrieve list of recent bookmarks on home

View holders and interactors for recently saved bookmarks

Recent bookmark item view holder binding

Create adapter for recent bookmarks. Implement controller methods. Implement view holder bindings for items

Top level adapter for recent bookmarks section

Retrieve list of recent bookmarks on home

Update list on app start and when bookmarks are added

View holders and interactors for recently saved bookmarks

Recent bookmark item view holder binding

Create adapter for recent bookmarks. Implement controller methods. Implement view holder bindings for items

Top level adapter for recent bookmarks section

Retrieve list of recent bookmarks on home

Update list on app start and when bookmarks are added

Make a use case for retrieving and updating the list of recently saved bookmarks

Add adapter items and define header viewholder binding

Use session interactor for header button clicks. Bind in the adapter

* Retrieve list of bookmarks asynchronously on home

Interactor and controller tests

Address review comments

Split up tests for recent bookmarks

Update to new interactors

Dark mode and light mode styles

Refactor bookmarks home stuff

* Add RecentBookmarksFeature to home

Move interactor to SessionControlInteractor

Clean up lint, styles, and dimens.

* Bookmarks use case tests for retrieving recently saved bookmarks. Linting.

* View holder tests

* Match ux to designs for colors, margins, and scrolling

* Clean up clean up

* Tests for the view bound feature

* Controller test

* Clean up: check state of store in feature tests; ellipsize textviews for bookmark item; remove unused attr; format

Co-authored-by: Jonathan Almeida <jalmeida@mozilla.com>
3 years ago
codrut.topliceanu ce0773fcdc For #19558 - Adds proper tint to "Report Site Issue" 3 years ago
Roger Yang 74c1cc82fb Closes #19921: Update appcompat and fragment dependencies to 1.3.x 3 years ago
codrut.topliceanu 2c538dbb5d For #16330 - Replaces Sentry.capture with submitCaughtException 3 years ago
Mugurell b3a6dcccd7 For #19797 - Remove FenixAccountManager#authenticatedAccount
This api had a bug stemming from the property name - authenticatedAccount which
may return even an unauthenticated account.
After the recent refactorings it was left unused so best to remove it to
prevent from future misuses.
3 years ago
Mugurell ce64c2439d For #19797 - Use the FXA email only if the account is authenticated
An account may exist but it may need to be re-authenticated.
In this case also the email should not be exposed to the app.
3 years ago
Mugurell 19af5e9b15 For #19797 - Remove FenixAccountManager#signedInToFxa
After the changes from this patch this api is not used anymore so to prevent
future misuses of it this is removed in favor of the new "accountState".
3 years ago
Mugurell 3d071dd049 For #19797 - Browser menu: go to problems page if account exists but not signed in 3 years ago
Mugurell d663383cf7 For #19797 - New FenixAccountManager#getAccountState()
This new method allows a single source of truth for getting the up-to-date
account status without clients interesting in this needing to know what to
check for.
3 years ago
Arturo Mejia c2439914fa For #19881 add telemetry for start on Home. 3 years ago
Sammy Khamis 950e36c053 changes required for uniffi-ing logins component= 3 years ago
Christian Sadilek ba19960b7e Issue FNX-22435: Introduce History metadata
Co-authored-by: Grisha Kruglov <gkruglov@mozilla.com>
3 years ago
Jan-Erik Rediger d55f55d70c Suppress deprecation warnings for now-deprecated Glean APIs
Glean v39 allows to specify types for event extra keys.
The old API is therefore deprecated.
To avoid to much churn right now and keep the build going let's suppress
the deprecation warnings.
3 years ago
mcarare 2d2be26fbc For #19915: Add telemetry for the toolbar Home screen button. 3 years ago
Sebastian Kaspari c0531ffa82
Update Android Components to 91.0.20210610143711. (#19946) 3 years ago
Arturo Mejia 2f879f8e9d Fix site permissions breaking changes 3 years ago
Sebastian Kaspari 4753a1d494 Complete browser-state migration and remove browser-session dependency.
Co-authored-by: Christian Sadilek <christian.sadilek@gmail.com>
3 years ago
Gabriel Luong 044c9a5b40 For #19876 - Part 2: Add a Home screen button to the browser toolbar 3 years ago
Gabriel Luong 86a9c56782 For #19876 - Part 1: Refactor BrowserToolbarInteractor
- Renames `BrowserInteractor` to `DefaultBrowserTolbarInteractor`
- Renames `BrowserTooolbarViewInteractor` to `BrowserToolbarInteractor`
- Refactors `BrowserToolbarViewInteractor` interface from `BrowserToolbarView.kt` to  `BrowserToolbarInteractor` as `BrowserToolbarInteractor`
3 years ago
Roger Yang 2e4635334a
Closes #19090: Show snackbar on adding to bookmarks from tabs tray (#19807) 3 years ago
Jonathan Almeida bf3f81d271 Issue #19112: Remove old Synced Tabs code 3 years ago
Jonathan Almeida dc11c334b6 Issue #19112: Remove old tab tray code 3 years ago
Gabriel Luong a5110f8c0a
For #19746 - Remove FeatureFlags.nimbusExperiments (#19771) 3 years ago
Elise Richards 6dbe5acc5b
For #19746 - Remove feature flag for the three-dot menu redesign (#19750)
* Remove feature flag for the three-dot menu redesign

* Remove menu feature flag from unit tests
3 years ago
codrut.topliceanu 13f9a35131 For #19571 - Adds gdprForgetMe when stopping Adjust 3 years ago
Gabriel Luong 172a118a51
For #18711 - Refactor credit card telemetry under the Metrics ping (#19733) 3 years ago
Grisha Kruglov daba5595f6 Enable addresses sync for nightly/debug builds 3 years ago
Elise Richards e0b410efdf
For #18711: Telemetry for credit card autofill (#19548) 3 years ago
Christian Sadilek 9d1e51dfff Fix breaking change in MetricController 3 years ago
James Hugman ab678a21ff Add an experiment to demontrate the Feature API
This is not visible in production, but only debug. It shows three variables
being used to change the settings screen (title, icon and title-punctuation).
3 years ago
mcarare 0141d96465 For #19554: Add SyncEngine.CreditCards to sync supportedEngines. 3 years ago
Sebastian Kaspari 761752e382 AutofillConfiguration: Correctly specify autofill confirm activity. 3 years ago
Gabriel Luong 75fc116043
For #18287 - Display a credit card autofill prompt (#19477) 3 years ago
Arturo Mejia bf42a1786e For issue AC#10231 update proton icons third batch 3 years ago
Roger Yang f13560ae52 Issue #19147: Move set startup metrics off main thread 3 years ago
Jonathan Almeida e66983d093 Issue #19002: Use AbstractBinding from lib-state 3 years ago
Roger Yang a9e0557d83
Closes #3728: Add secret menu switch for allowing third party root certificates (#19398) 3 years ago
Arturo Mejia 9bfb31519a For issue #19290 update to proton icons second batch 3 years ago
Roger Yang 74047cdceb
Closes #19147: Move startup metrics to right after Glean initialization (#19252) 3 years ago
Roger Yang 59de530a9c
Closes #18253: Remove spaces from Addons telemetry comma-separated list (#19292) 3 years ago
Arturo Mejia 21cf0b31a4 For issue #18132 update to proton icons first batch 3 years ago
Sebastian Kaspari 7d690219ea Issue #19040: Remove Leanplum (Nightly) 3 years ago
Grisha Kruglov 4e16c46b27 Fix breaking changes introduced by credit card encryption APIs 3 years ago
Mugurell dc51cd47b5 For #18591 - Make the navbar sticky in the new menu 3 years ago
Sebastian Kaspari cf4847dc17 Remove browser-search references. 3 years ago
Elise Richards db76b8fe21
For #19114: check state of sync account when navigating from sync sign in menu item (#19118) 3 years ago
mcarare 8f1b3e03f1 For #18608: Also add default browser item in new menu. 3 years ago
Arturo Mejia acb24396e5 Address WebExtensionBrowserMenuBuilder breaking change 3 years ago
Sebastian Kaspari a126f0913a Update to Mozilla Android Components 90.0 3 years ago
mcarare 8b3a878062 No issue: Rename Event for naming consistency. 3 years ago
mcarare f693375270 For #18852: Add metrics for default browser settings experiment. 3 years ago
Michael Comella a64540bd06 For #18836: add StartupPathProvider + tests. 3 years ago
Elise Richards 3d226429aa
For #18867: remove "signed in as" string in three-dot menu (#19035)
* Remove signed in as string from sync menu item

* Nav to sync account settings on click

For #18806: navigate to settings account page or sign in on clicking menu item.

* Confirm account exists and retrieve item title

* Remove string
3 years ago
Arturo Mejia a3f4cee388 Telemetry for #18855, #18851 and #18857
For #18857 [Telemetry] Send a Glean event when users change their default browser

For #18855 [Telemetry] Send an event when users open the toolbar menu

For #18851 [Telemetry] Send an event when users click on the "set as default browser" entry in the toolbar menu
3 years ago
Roger Yang 8246f81c97
Closes #18948: Update tabstray telemetry (#19004) 3 years ago
mcarare cea869c276 For #18854: Add metrics for home screen being displayed. 3 years ago
mcarare dbae5dd3c0 For #18853: Add metrics for default browser new tab experiment. 3 years ago
mcarare 920c1285e4 For #18856: Add metrics for opening settings screen from home menu. 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
Michael Comella 000bef020a For #18836: replace StartupActivityStateProvider with StartupStateProvider.
The StartupActivityStateProvider uses an imperative implementation,
driven by callbacks, to set the state of the application. This is hard
to follow as you need to understand which callbacks will be called in
which order. For example, to make sense of an implementation like this,
COLD, WARM, AND HOT would likely need to be implemented in separate
ActivityLifecycleCallbacks.

I feel the StartupStateProvider is an improvement because it leverages
the StartupActivityLog to query a linear state for a more understandable
implementation. Furthermore, it seems accessible to write COLD, WARM,
and HOT in the same class because they can all be approached the same
way.
3 years ago
Michael Comella 0cbedaadb1 For #18836: add StartupStateProvider. 3 years ago
Michael Comella cde954f3a7 For #18836: add StartupActivityLog, tests. 3 years ago
Christian Sadilek 72230377f4 Upgrade to Android Components 75.0.20210413143139 3 years ago
Elise Richards 761d6babb9
For #18806: Show sync tabs or sync account sign in based on feature flag (#18859)
* Show sync tabs or sync account sign in based on feature flag. Sign in navigates to account settings on click.

* lint and nits
3 years ago
Jonathan Almeida f3df2c73d9
Close #18862: Add multi-select banner to tabs tray (#18932)
* Issue #18862: Add new addBookmark BookmarksUseCase

* Issue #18862: Add class for state binding features

* Issue #18862: Add delete multiple tabs to tray interactor

* Issue #18862: Add new actions to navigation interactor

* Issue #18862: Enable select mode from main tray menu

* Issue #18862: Add menu when in select mode

* Close #18862: Add multi-select banner to tabs tray

* Close #18862: Add select support for handle UI

We apply various layout changes to the "handle" UI in the tabs tray when
switching modes. It isn't quite clear to my, why we do this, if it's
really needed to meet the end result, and if there is a better way.

For now, we're simplying moving over that logic that we can re-evaluate
at a later time.
3 years ago
Arturo Mejia fc1739624d For #18608 only show the experiment for set default browser MenuItem when Nightly, Beta, Release are not the default browser 3 years ago
Sören Hentzschel 51df37cde5
For #18898 - implement quit button in page menu (#18942) 3 years ago
Mugurell 660f0609cb For #18122 - Update browser layout for find in page bar with bottom toolbar
With a dynamic bottom toolbar the  browser extends all the way to the bottom of
the screen and so when the find in page bar is shown it will be so above the
bottom part of the browser which may contain exactly the searched for items.

To fix the browser must effectively be placed at the top of the newly shown
find in page bar.
3 years ago
Mugurell b36431a6df For #18616 - Update browser and toolbar layout when toolbar is at top
FindInPageIntegration which already updated the toolbar to make room for the
find in page bar now receives more data based on which it will be able to
better update the layout of BrowserFragment to to support showing the find in
page bar.
3 years ago
Sebastian Kaspari 54d46c7e94 Move TelemetryMiddleware to telemetry sub package. 3 years ago
mcarare c30d0f9240 For #18829: Adjust bookmark item color to UX specs. 3 years ago
Arturo Mejia db9b3676d3 For #18608 Add experiment for set default browser MenuItem. 3 years ago
Elise Richards e5e9ceba5a
Settings menu item should be tinted if there is an account issue (#18849) 3 years ago
Elise Richards ba111dabaa
PWA install to homescreen is available in main menu (#18850) 3 years ago
rxu efdb30483a Add domestic China FxA service for Mozilla Online builds
China fxa related string

Add switch preference in settings to use local/global fxa server

inherit fennec FxA settings

Present or hide fxa switch according to isMozillaonline

Allow China fxa server auto login during migration
3 years ago
Arturo Mejia 8ca9f94abb For issue #16557 set autoplay block audio only
by default
3 years ago
Elise Richards 547a843c5c
For #18770 - Correct addons position in three dot menu based on toolbar position (#18828) 3 years ago
Kate Glazko 841dacb69e For 17798: Sync Menu Item 3 years ago
Gabriel Luong 1f320fd2ad
No issue - Remove generic strings for more specificity (#18769) 3 years ago
Mugurell 0f0c319896 For #17772 - Collapse browser menu to "Add to Home screen"
The menu will start as collapsed.
Users can then swipe up to expand it.
3 years ago
Gabriel Luong 3f21a63c3c
For #18729 - Use consistent string naming for generic strings (#18730) 3 years ago
Elise Richards ca33aef036
For #17770: New tab three-dot menu reorder (#18427)
* Create new menu order for new tab

* Add new tab menu navigation. Dynamically update menu when sync auth is needed. Make new tab menu and browser menu consistent.

* Lint

Lint and refactoring tests

* Tests for default toolbar menu

* Feature flag for request desktop site

Add todos for UI test issue 17979

Add todos for UI tests
3 years ago
mcarare 6f17e329c4 For #17797: Add bookmarks menu item. 3 years ago
Michael Comella ac34432176 For #18426: warn about flaw in `app_opened_all_startup` probe. 3 years ago
Michael Comella ade38246be For #18426: record cold start duration telemetry. 3 years ago
Michael Comella 2be9fb61d0 For #18426: add StartupActivityStateProvider.
This will be used to filter conditions for the start up telemetry we're
adding.
3 years ago
Michael Comella edd49b286d For #18426: add ApplicationStartReasonProvider.
We need to know this state to add a correct COLD MAIN probe.
3 years ago
rxumoz 46af52d254
Update top sites to add PDD for MozillaOnline builds (#18615) 3 years ago
Roger Yang 34a7bc0baa
For #17644: Record when user taps on a add-on's setting (#18504) 3 years ago
Elise Richards 559cf54798
For #17190: notifications are updated when locale is changed (#18179)
* Add intent processor for locale changes

* Recreate notification and notify in the service

* Use locale use cases to update notification

* Use notification id instead of tag

* Add locale use cases and restore locale in application

* Send locale to service instead of string

* Controller tests for locale

* Update Android Components version to 74.0.20210323143308

Co-authored-by: Arturo Mejia <arturomejiamarmol@gmail.com>
3 years ago
Roger Yang a8c53c6bf1
Closes #17791: Use updated URL with custom tabs when copying to clipboard (#18590) 3 years ago
mcarare d0a45bab21 For #17799: Add extensions submenu item. 3 years ago
Roger Yang d2ffaa85f9
Closes #17531: Use shared preference to store top sites count for telemetry (#18557) 3 years ago
Mihai Adrian Carare 79794962d0
Closes #12565: Clean up use of Context within ReviewPromptController. (#18537) 3 years ago
Roger Yang 8a7c50bbef
For #17644: Always update add-on's telemetry values before sending metric ping (#18529) 3 years ago
Gabriel Luong 35bae17e86 For #18408 - Add a lazy getter for AutofillCreditCardsAddressStorage 3 years ago
Mugurell 1e30744c64 For #17869 - New AndroidKeystoreExperiment telemetry 3 years ago
Mugurell ec0176275b For #17869 - Start the Android Keystore experiment
Only on API 23+ (minimum Android version needed for SecureAbove22Preferences)
and only if enabled by a Nimbus experiment.

The Nimbus experiment will have the key `fenix-android-keystore` and use the
default branches - "control" and "treatment".
3 years ago
Gabriel Luong 3a056bf850
For #18036 - Add TrackKeyInfo to Ad Click Metrics (#18159) 3 years ago
Jan-Erik Rediger c47f43608d Set `distributionId` right after initializing Glean
Previously setting it might have been arbitrarily delayed, resulting in
this metrics missing from pings that get submitted earlier.
Setting it early should prevent that.
The performance impact is negligible, Glean dispatches recording that
data off-main-thread anyway.
3 years ago
Sebastian Kaspari 8856a3c1d7 Integrate Android Autofill support into Nightly and debug builds. 3 years ago
Elise Richards b15c3ff864
Add open in app to main three dot menu (#18462) 3 years ago
Elise Richards f5a1a01e06 Remove sync sign in and keep it as synced tabs 3 years ago
Elise Richards d34848a5d9 Add report site issue to new three dot menu 3 years ago
Elise Richards 4b84503813 Remove disabled color for icons 3 years ago
Roger Yang 9049513017
Closes #18178: Rework History Telemetry (#18261) 3 years ago
Roger Yang 56b08abe0f
Closes #18173: Add Telemetry When User Opens a Bookmark (#18174) 3 years ago
Roger Yang 2322cbdd0e
Closes #18068: Use AwesomeBarFacts for AwesomeBar Telemetry (#18090) 3 years ago
Roger Yang aada459428
Closes #18163: Use SyncedTabsFacts for Synced Tab Telemetry (#18172) 3 years ago
Mihai Adrian Carare 5c7a01ba6f
For #17971: Add Reader view appearance controls in three-dot main menu. (#18340) 3 years ago
Elise Richards 42cc4cb452
For #17802: Match the design for three-dot menu navigation (#17875)
* Feature flag for toolbar menu redesign. Add new items to menu and reorder.

* Handle toolbar items in menu controller

* Remove bookmark from toolbar nav

* Respect toolbar position

* Inline toolbar orientation checks

* Add Todos for bookmark UI tests

* Make variable names consistent
3 years ago
Mugurell cf483ef580 For #18034 - Don't animate the toolbar while the tab is loading
Use the new controller offered by AC to resolve some browser layout issues and
also offer an experience consistent with that of other browsers.
3 years ago
Christian Sadilek dc002f0508 Remove Session[Manager] references from Fennec intent processors 3 years ago
Mugurell 0a0f75d2ab For #18027 - Also fix the bottom toolbar in place when a11y is enabled
We previously only set the top toolbar as fixed if an a11y service was running.
3 years ago
Jonathan Almeida 2f6fcbf196 Close #13892: Remove Synced Tabs appended to tabs tray 3 years ago
Mugurell 6e0a64897b For #17899 - Expand toolbar when returning from fullscreen video
This was the previous behavior for both the top and bottom toolbars.
Regressed when changing to use a new custom behavior for the top toolbar.

When entering fullscreen we will now collapse and hide the toolbar, allow the
browser to expand to the entire screen estate and then, when exiting fullscreen
expand the toolbar.
Collapsing and then expanding the toolbar will trigger the
EngineViewBrowserToolbarBehavior to place the browser below the toolbar.
3 years ago
Roger Yang 64f32b9d95
Closes #17089: Add metric to track both normal and private URI opened (#17935) 3 years ago
Christian Sadilek e07f4ac590 Deprecate SessionManager component 3 years ago
Christian Sadilek 2d87307144 Remove remaining usages of Session[Manager] in BrowserFragment 3 years ago
Christian Sadilek c9b8f57f96 Refactor BrowserToolbarMenuController to use browser store 3 years ago
Christian Sadilek 5a5cf9cd12 Refactor BrowserToolbarController to use browser store 3 years ago
Elise Richards d0fd3e82c5
For #17771: three-dot menu reorder (#17838)
* Feature flag for toolbar menu redesign. Add new items to menu and reorder.

* Handle toolbar items in menu controller

* Menu controller tests

* Make icons invisible

* Lint

* UI tests reflect design change

* Refactor test names

* Lint fixes

* UI tests
3 years ago
Codrut Topliceanu d56b4a2b92
For #17418 - Added telemetry for Google Default Top Site (#17637)
* For #17418 - Adds channel "ts" to TrackKey

This is used to track if the `InContentTelemetry` is a result of the user using the Google Top Site. It looks for `&channel=ts` within the uri.

* For #17418 - Adds TopSite PerformedSearch back in

* For #17418 - Check now looks for equality with GOOGLE_URL

* For #17418 - Adds test for topSite changes
3 years ago
Sebastian Kaspari a3b556aa35 ToolbarIntegration: Use global public suffix list instance. 3 years ago
Roger Yang 993cf74e72
Closes #17174: Remove the New Media Session API Feature Flag (#17863) 3 years ago
Mugurell 8bf1cae2ca For #10686 - Use the AC custom behavior for both the top and bottom toolbars
This comes to unify the experience (with improvements but also specific issues)
for the url toolbar irrespective of it being placed at the bottom or at the top
Going further this will ease development and ensure the best UX for users.
3 years ago
Gabriel Luong a3d401a3b7
For #17418 - Add event ping telemetry for the Google Top Site click (#17862)
Co-authored-by: codrut.topliceanu <codrut.topliceanu@softvision.ro>
Co-authored-by: Gabriel Luong <gabriel.luong@gmail.com>
3 years ago
MickeyMoz 378e68f3a6 Update Android Components version to 73.0.20210204143136. 3 years ago
jhugman 72f977771d
Re-enable Nimbus with Off the main thread I/O and non-blocking networking (#17684)
* Moved Nimbus setup from Analytics to its own file

* Change experiment identifiers to fit new run of the experiment

* Re-enable nimbus for debug and nightly builds

* ./gradlew ktlint && detekt
3 years ago
Christian Sadilek d8085480ad Increase AMO collection cache timeout to 2 days 3 years ago
MickeyMoz 4bc6b85237 Update Android Components version to 73.0.20210129195412. 3 years ago
Roger Yang d434ff13a5
For #17092: Dismiss toolbar menu when configuration change occurs (#17682) 3 years ago
Codrut Topliceanu e188185b15
For #16828 - Adds telemetry for open in app banner (#17049)
* For #16828 - Adds telemetry for open in app banner

Specifically: Banner displayed, Dismiss action, Go to Settings action.
3 years ago
Roger Yang 124c2baf30
Closes #17531: Use top sites count fact for top sites telemetry (#17664) 3 years ago
Roger Yang eaef276345
Closes #17530: Update has open tabs metrics when tabs are opened or closed (#17557) 3 years ago
Elise Richards f7b7b25213
For #16485: Tabs tray grid view telemetry (#17442)
* Tabs tray CFR telemetry interactions

* Create CFR events and implementation

* Tests for tab tray controller
3 years ago
Arturo Mejia f99c175ceb Remove autoplay indicator FeatureFlags 3 years ago
William Durand 0537594810 Add new BuildConfig variables to support AMO non-production envs 3 years ago
Codrut Topliceanu 928ad21c51
For #17481 - Remove unused long_press_tapped metric (#17544) 3 years ago
Arturo Mejia 570383a54d Add dot notification for autoplay blocked content 3 years ago
Jonathan Almeida d3dcf69064 A-C 71.0.20210118134928: Fix breaking API in TabCounterToolbarButton 3 years ago
MickeyMoz d945cdc4c8 Update Android Components version to 71.0.20210117143132. 3 years ago
Sebastian Kaspari 051988ecff Migrate some "selected tab" reads from SessionManager to BrowserStore. 3 years ago
jhugman 7a3524fae5
SDK-158 Use disabled/no-op version of Nimbus object to eliminate unnecessary Rust call (#17372) r=christian 3 years ago
Arturo Mejia 00d971e9d3 For #16847: Allow autoplay to controlled via the toolbar. 3 years ago
Sebastian Kaspari 0761f391fc Update to latest feature-intent and feature-recentlyclosed APIs (and update Android Components). 3 years ago
Sebastian Kaspari 1b6cebf4d4 Switch to new SessionStorage / session restore API. 3 years ago
Codrut Topliceanu c0f0c401f3
For #11580 - Tracks text selection context menu usage (#16968)
* For #11580 - Tracks text selection context menu usage

Tracks Copy, Search, Select All and Share items from the text selection context menu. Uses AC's DefaultSelectionActionDelegate to achieve this.

Co-authored-by: Gabriel Luong <gabriel.luong@gmail.com>
3 years ago
Arturo Mejia 81f208bda1 For issue #13981 Use DEEP_LINK_SCHEME instead of hard-coded fenix 4 years ago
Elise Richards 6dadecacc2
For #15703 and #17133: allow ETP redirect trackers setting to be customized (#17137)
* Remove ETP redirect trackers feature flag. Add category to ETP panel view.

* Add redirect tracker category to ETP custom settings
4 years ago
jhugman 4565d7381b
No bug- protect nimbus init from StrictMode (#17033) r=christian 4 years ago
Sebastian Kaspari d2b8decaeb Switch to new feature-tab-collections API. 4 years ago
Gabriel Luong 846d618c06
For #16941 - [Telemetry] Bookmark Counts (#16942) 4 years ago
Codrut Topliceanu d0b09b7d69
For #15368 - Adds telemetry for fullscreen, pip (#16833) 4 years ago
mcarare 01db5160ee For #16827: Add copy url from long press metrics. 4 years ago
mcarare 93b13ac977 For #15369: Add synced tabs usage metrics. 4 years ago
mcarare 2f360eb474 For #15366: Add recently closed tabs metrics. 4 years ago
Mugurell 574eac4636
For #15367 - DownloadsFragment telemetry (#16728)
Adds a counter for how many times the user does the following action:
- opens the Downloads section inside the app
- tap to open an item from inside Downloads / from the download dialog
- tap to delete one or more downloads at once
4 years ago
Mugurell d5b33aec43
For #11578 - Add telemetry for how many times we download something (#16730) 4 years ago
Arturo Mejia f263b7333a For issue #16847 Show the autoplay icon in the toolbar 4 years ago
Roger Yang ca605d8a95
Closes #16075: Add distribution_id in telemetry startup metrics (#16821) 4 years ago
jhugman 459f1e970f
Fixes #16948: call nimbus.updateExperiments on startup (#16950) r=gl 4 years ago
mcarare 0a77f4bccf For #16775: Fallback to light mode drawable when ui mode is not resolved 4 years ago
Christian Sadilek faf765a57d Update IntentProcessors after breaking API change 4 years ago
Christian Sadilek d1345e8f93 Closes #11290: Refactor ToolbarMenu to use browser store 4 years ago
Roger Yang 2ff7ba75c7
Closes #16896: Integrate new MediaSession API to nightly or debug builds (#16909) 4 years ago
Sebastian Kaspari 2cada405d8 Update Android Components to 69.0.20201207103252. 4 years ago
Elise Richards 77f061c362 Closes #8791: Use A-C tab counter and upgrades to A-C 69.0.20201203202830
Upgrades to A-C 69.0.20201203202830 and addresses breaking changes:
- Upgrades androidx workmanager to 2.4.0 in line with A-C.
- RecordingDevicesNotificationFeature was removed
- SearchUseCases accept parent session ID instead of session itself
4 years ago
Codrut Topliceanu 79d1c08402
For #16629 - Fix for collection snackbar View button (#16679) 4 years ago
jhugman ea9f692007
Nimbus-SDK-119 Get Nimbus server endpoint at build time. (#16682)
This PR builds on [AC##9024][1], and implements setting the Nimbus endpoints from [a secret set at build time][2].

For production use, this requires a secret named `nimbus_url` to be put into CI.

Note: Nimbus is currently behind a feature flag.

If developers wish to use a Nimbus server for local development, you can set the url by adding an entry into local.properties, e.g.:

```
nimbus.remote-settings.url=https://settings.stage.moz4ws.net
```

Without setting server, Nimbus will be able to function, except no experimental definitions will be fetched, and features under experiment will be configured as if not enrolled in the experiment.

[1]: https://github.com/mozilla-mobile/android-components/pull/9024
[2]: https://groups.google.com/a/mozilla.com/g/android-components-team/c/lAGVKQy8aiA/m/rY3uGAwhBAAJ
4 years ago
Christian Sadilek 3722033a5c For #16032: Support installing recommended add-ons from AMO 4 years ago
Sebastian Kaspari 788a8309c2 Issue #16435: Open custom tab in Fenix: Force launch outside of and remove current task. 4 years ago
ekager d49d710343 For #16676 - Do not switch mode on last private tab via tab context menu 4 years ago
Sebastian Kaspari 2b759e9d6f Integrate new search code from Android Components into Fenix. 4 years ago
MickeyMoz 2904ca8ac0 Update Android Components version to 68.0.20201120125142. 4 years ago
jhugman 9cdfb6db4a
Nimbus Global Opt Out (#16543) r=gl 4 years ago
Jonathan Almeida cebab81e07
Update Android Components to 67.0.20201117165227 (#16619) 4 years ago
Christian Sadilek 88f3f3564e Issue #16587: Make sure tab counter correctly reflects private/normal tab counts 4 years ago
Christian Sadilek fbbc25b54e Closes #16053: Fix crash when closing private tabs via notification 4 years ago
Michael Comella e8bf955893 No issue: move StrictModeManager to perf package.
While StrictMode is not exclusively used for performance purposes, it's
primarily used for perf purposes so let's move it to the perf package
and code owner it.
4 years ago
LeoMaldonado a06b30a73d Fixes Comment on #16563: DefaultToolbarMenu registering for bookmark changes
comment link: https://github.com/mozilla-mobile/fenix/pull/16536#discussion_r522387945
4 years ago
LeoMaldonado 2d8fe7a9ad Closes #16345: Update share icon shape
updating share icon to a filled shape, like default toolbar menu across all app
4 years ago
LeoMaldonado 84eda3d38f For #16345: use same share icon across all app
replace mozac_ic_share for ic_hollow_share on DefaultToolbarMenu
4 years ago
rxumoz 409041ae3b
For #16451 - Change default top sites to Baidu & JD in China build (#16515)
* Add top sites related strings

* Change default top sites to Baidu & JD in China build
4 years ago
Mugurell a097b135b3 For #16076 - Add new "share_image" telemetry event 4 years ago
Codrut Topliceanu 6e4393a199
For #15720 - Remove unused telemetry (#15887) 4 years ago
Christian Sadilek 96e2123f86
Update Android Components version to 66.0.20201106143126 (#16439) 4 years ago
Christian Sadilek 4abd399002 Closes #16327: Refactor MenuPresenter to use browser store 4 years ago
Michael Comella 090650485f For #15279: remove redundant lazy wrapper from storage APIs.
They're currently lazy { lazy { value } }. Accessing `lazy.value`
directly allows us to make it lazy { value }. This should be more
performant and prevents us from double-counting these components.
4 years ago
Michael Comella 89541a17f7 For #15279: LazyMonitored implement Lazy + update built-in API use.
By having LazyMonitored implement Lazy, we can continue to pass these
values directly into the ac APIs that require Lazy references. For some
reason, implementing `Lazy.value` can replace `operator fun getValue`
required for delegates.
4 years ago
Michael Comella 901c78684c For #15279: replace lazy with lazyMonitored in component groups.
By component groups, I mean I applied this to any class with the
class kdoc, "Component group for...".

There are a few instances of lazy we had to keep using the old API to
avoid having to update constructor arguments.
4 years ago
ekager c0e01373e1 No issue: Update stable androidx and material versions 4 years ago
Mugurell 34f0c84d46
For #16339 - Initialize FxaAccountManager with also a CrashReporter (#16340) 4 years ago
MarcLeclair 7b1af41b40
15278 detekt rule runblocking (#15942)
* For #15278: added CoroutineManager to count runBlocking calls

* For #15278: Added actual detekt rule for runblocking and its config to the yaml

* For #15278: Added unit test for RunblockingCounter

* For #15278: renamed StrictModeStartupSuppressionCountTest.kt to PerformanceStartupTest.kt and added runBlockingCount test

* Lint fix

* For #15278: made runblocking a Long to prevent overflow

* For #15278: fixed MozRunblocking name, description and moved RunBlockingCounter to perf package

* For #15278:Renamed MozillaRunblockingCheck to MozillaRunBlockingCheck

* For #15278: Added setup for unit test, since it failed without restting counter

* For #15278: Fixed naming for RunBlocking lint check

* For #15278: removed changes made to test to use runBlockingIncrement

* For #15728: added test exclusion for runBlocking check

* For #15278: changed null check and added Synchronized to count setter

* For #15278: fix for nits

* For #15278: added StartupExcessiveResourceUseTest to CODEOWNERS

* For #15278: fixed for nits

* For #15278: Moved increment function to extension function and fixed indentation

* For #15278: Added tests for Atomic Integer extension and nit fix
4 years ago
mcarare 3cb2c83980 For #16250: Disable remote USB debugging for SDK <23. 4 years ago
Mihai Adrian Carare 0ee7e1c28d
For # 15929: Remove the search widget discoverability experiment. (#16081)
* For #15929: Remove SearchWidgetCFR telemetry.

* For #15929: Remove SearchWidgetCFR and search widget experiment.

* For #15929: Remove unit tests references to search widget experiment.
4 years ago
mcarare 9748c65c71 For #15413: Use proper url when bookmarking a page. 4 years ago
mcarare 21a67de947 For #15379: Use proper url when sharing. 4 years ago
ekager e15f50712a For #6313 - Set session ClearColor through Engine DefaultSettings 4 years ago
ekager d5cb9c599c
For #15910 - Adds back automatic toggle, disables slider when enabled (#16070) 4 years ago
Elise Richards 7e3c26914c
For #15080: Handle default search engine when editing or removing (#15768) 4 years ago
Juan C. Goncalves eb0712d9b4
For #11397 - Add lint rule for AppCompatResources instead of ContextCompat (#16011) 4 years ago
Mihai Adrian Carare b1bc024ff5
For #11631: Move report site issue extension to main menu. (#15884)
* For #11631: Move report site issue extension to main menu.

* For #11631: Update UI test for installing add-on.
4 years ago
mcarare 9274558e2f For #15688: Navigate to home screen with arguments on new tab action. 4 years ago
ekager d208ffe002
For #7345 - Update new shield icons, remove lottie (#15909) 4 years ago
Christian Sadilek c852301c93 Closes #11286: Add TelemetryMiddleware to remove Session[Manager] observers 4 years ago
Michael Comella 4a000ab4f9 For #15644: change apply to with in GleanMetricsService.
While the callback receiver is identical in these two methods, they're
semantically different: apply is for initializing the receiver while with
is anything else benefiting from a new `this` receiver.

I didn't change the usage of apply that has a return statement because I
was afraid my change might change behavior.
4 years ago
Michael Comella 690554b5c6 For #15644: mock package inspection dependencies in GleanMetricsService.
The new robolectric version changed the behavior such that the app ID
that was returned for our app was `org.mozilla.fenix.debug` instead of
(I guess) `org.mozilla.fenix`. In general, relying on robolectric can be
fragile, such as this case, so it's better to mock. Also, this test
behavior should theoretically have varied between build flavors so
mocking prevents the tests from breaking across flavors.
4 years ago
ekager 4d348dd26a Fixes existing lint errors 4 years ago
ekager 508ec8b8ff For #15347 - Adds telemetry for tabs settings 4 years ago
ekager b6587455f8 fix detekt errors 4 years ago
Sebastian Kaspari 430282c8ec Use new SearchEngineProvider interface. 4 years ago
ekager cbe293d3e4 For #12062 - Launch back to browser if we previoulsy had tabs 4 years ago
Michael Comella a1bbd2589e For #10069 - review: change extra name to firstFramePreDrawNanos. 4 years ago
sraturi 8f16f9cb37 for #10069 added AppLaunchTimeMeasurement.kt to handle logic of startup time for cold, warm, and hot startup types. 4 years ago
ekager 881e3d6ccd For #14923 - Removes auto size preference toggle 4 years ago
mcarare 9845626eca For #15711: Also add custom engines to fallback list. 4 years ago
Michael Comella 50959d997e For #13959: add marker when StrictMode is suppressed. 4 years ago
ekager ec3595d4fc For #15600 - Move removal of timed out sessions to immediately after restoration 4 years ago
Jeff Boek 41a92a8d8b For #15593 - Reverts back to simple UUID creation without Fenix side caching 4 years ago
Stefan Arentz ff930175de
For #15537 - Be more verbose about leanplum identifiers (#15538) 4 years ago
Michael Comella 56f78cb30c No issue: elaborate on Components class doc.
This is to clarify a misunderstanding I found in PR review.
4 years ago
ekager e49cd9c558 For #15503 - Change recently closed max to 10 4 years ago
Michael Comella f19c9920f9 For #13959: move resetAfter into StrictModeManager.
In a followup PR, we need to add state to strictModeManager (the
number of suppressions). This is much simpler to do when this is defined
as a class rather than an object. However, when this is defined as a
class, `resetAfter` needs access to the strictModeManager. Instead of
passing it in as an argument, it made sense to move this function onto
the strictModeManager instead.

Since folks are used to calling:
```
StrictMode.ThreadPolicy.allowThreadDiskReads().resetAfter
```

We're going to have to add a lint check to prevent them from doing that.
4 years ago
Michael Comella 6abeb2d9e7 For #13959: change StrictModeManager to class from object.
I originally tried to create this PR leaving this as an object to keep
the change simple but it wasn't worth it - once the object started to
keep state, we'd need to manually reset the state between runs. Also,
the tests were already getting hacky with static mocking so it was
easier to address some of those issues this way too.
4 years ago
Christian Sadilek d4ab728cff For #14034: Add debug preference to override AMO collection in Nightly 4 years ago
Sebastian Kaspari 3983c509dc Use "undo" implementation from Android Components.
This is not the super fancy version yet - since we still need to restore into SessionManager and
haven't fully switched to BrowserStore yet. However AC having knowledge about "undo" and whether
it was performed or not, will help us with features like "recently closed tabs". And once we
can improve "undo", Fenix will get all the nice things automatically.

Requires:
https://github.com/mozilla-mobile/android-components/pull/8449
4 years ago
ekager 0d0a28d551 No issue: Update AC to 61.0.20200925190057 4 years ago
ekager 7d5c199e51 For #12383 #15407 #12860 - Switch to using shared view model for session to delete on home 4 years ago
Elise Richards 1adf467248
For #14280, #14743: Remove old search fragment (#15169)
* Remove search fragment

* Use new folder to search dialog

* Rebase and lint

* Update tests with search dialog nav directions

* Rename interactor to match naming convention. Remove old controller and point everything to the dialog controller.
4 years ago
Grisha Kruglov 71b51146cb Update breaking changes in the FxA/Sync integration 4 years ago
ekager 030d6a5b36 For #15121 - Ensure tabs removed while on browser select an available parent session 4 years ago
ekager 9a2103a9a7 For #13934 - Make TabHistory work on PWA/Custom Tabs 4 years ago
ekager 9e876ebc44 For #14982 - Show snackbars with padding with static bottom toolbar 4 years ago
Tiger Oakes b563576335
Closes #14131: Move constants to dimens.xml (#14135)
Co-authored-by: Elise Richards <erichards@mozilla.com>
4 years ago
Elise Richards a4ff782565
For #13812: add ETP category for redirect trackers (#15139)
* Feature flag for ETP cookie purging

* Strings for new ETP description

* Remove icons from ETP info screeen and add category for redirect trackers

* ETP policy factory tests

* Remove icons from ETP panel and add cross tracking allowed field.

* Remove icons on ETP panel. Add blocked category for redirect trackers to panel.

* Add margins to tracking protection settings
4 years ago
Jeff Boek 6781018556 For mozilla-mobile/android-components#8429 - Dont initialize MLS if token is null 4 years ago
Jeff Boek 8bdc9d0431 Revert "For #12544 - Prevent search engines mixup"
This reverts commit 0a4a170f7e.
4 years ago
Sawyer Blatz 1f17371df6 For #14565: Add telemetry for top sites 4 years ago
mcarare e5a9311613 For #15116: Also do not expand or set bottom toolbar behavior on TWA tabs. 4 years ago
mcarare 83478b9db4 For #15116: Do not set bottom toolbar behavior on PWA tabs. 4 years ago
mcarare c5a2e2e5a0 For #15116: Do not expand toolbar on PWA tabs. 4 years ago
mcarare 1f004aff8c For #15116: Use safe cast for layout params. 4 years ago
codrut.topliceanu b892af773e For #14546 - Speculative fix for ANR 4 years ago