Skip to content
This repository has been archived by the owner on Nov 1, 2022. It is now read-only.

Commit

Permalink
Merge branch 'master' into edit-top-site
Browse files Browse the repository at this point in the history
  • Loading branch information
mergify[bot] authored Feb 23, 2021
2 parents c350bd9 + 69a800e commit f84dc4e
Show file tree
Hide file tree
Showing 162 changed files with 2,852 additions and 535 deletions.
4 changes: 4 additions & 0 deletions .buildconfig.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,10 @@ projects:
path: components/concept/sync
description: 'An abstract definition of a browser data synchronization layer.'
publish: true
feature-autofill:
path: components/feature/autofill
description: 'Component adding support for Android`s Autofill framework.'
publish: true
feature-awesomebar:
path: components/feature/awesomebar
description: 'Component connecting a concept-toolbar with a concept-awesomebar.'
Expand Down
2 changes: 1 addition & 1 deletion .mergify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ pull_request_rules:
conditions:
- author=mozilla-l10n-automation-bot
- status-success=complete-pr
- files~=(strings.xml)
- files~=(strings.xml|l10n.toml)
actions:
review:
type: APPROVE
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,6 @@ Before you attempt to make a contribution please read the [Community Participati

* Matrix: [android-components:mozilla.org chat room](https://chat.mozilla.org/#/room/#android-components:mozilla.org) ([How to connect](https://wiki.mozilla.org/Matrix#Connect_to_Matrix)).

* Subscribe to our mailing list [android-components@](https://lists.mozilla.org/listinfo/android-components) to keep up to date ([Archives](https://lists.mozilla.org/pipermail/android-components/)).

* Localization happens on [Pontoon](https://pontoon.mozilla.org/projects/android-l10n/). Please get in touch with delphine (at) mozilla (dot) com directly for more information.

# Maven repository
Expand Down Expand Up @@ -128,6 +126,8 @@ _Combined components to implement feature-specific use cases._

* 🔵 [**Accounts Push**](components/feature/accounts-push/README.md) - Feature of use cases for FxA Account that work with push support.

* 🔴 [**Autofill**](components/feature/autofill/README.md) - A component that provides support for Android's Autofill framework.

* 🔵 [**Awesomebar**](components/feature/awesomebar/README.md) - A component that connects a [concept-awesomebar](components/concept/awesomebar/README.md) implementation to a [concept-toolbar](components/concept/toolbar/README.md) implementation and provides implementations of various suggestion providers.

* 🔴 [**Containers**](components/feature/containers/README.md) - A component for working with contextual identities also known as containers.
Expand Down
7 changes: 5 additions & 2 deletions buildSrc/src/main/java/Dependencies.kt
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

// Synchronized version numbers for dependencies used by (some) modules
object Versions {
const val kotlin = "1.4.21"
const val kotlin = "1.4.30"
const val coroutines = "1.4.2"

const val junit = "4.12"
Expand All @@ -30,7 +30,7 @@ object Versions {
const val disklrucache = "2.0.2"
const val leakcanary = "2.4"

const val mozilla_appservices = "70.0.0"
const val mozilla_appservices = "71.0.0"

const val mozilla_glean = "34.1.0"

Expand All @@ -40,6 +40,7 @@ object Versions {
const val annotation = "1.1.0"
const val appcompat = "1.2.0"
const val browser = "1.2.0"
const val biometric = "1.1.0"
const val cardview = "1.0.0"
const val constraintlayout = "2.0.4"
const val coordinatorlayout = "1.1.0"
Expand Down Expand Up @@ -86,6 +87,7 @@ object Dependencies {
const val androidx_appcompat = "androidx.appcompat:appcompat:${Versions.AndroidX.appcompat}"
const val androidx_arch_core_common = "androidx.arch.core:core-common:${Versions.AndroidX.arch}"
const val androidx_arch_core_testing = "androidx.arch.core:core-testing:${Versions.AndroidX.arch}"
const val androidx_biometric = "androidx.biometric:biometric:${Versions.AndroidX.biometric}"
const val androidx_browser = "androidx.browser:browser:${Versions.AndroidX.browser}"
const val androidx_cardview = "androidx.cardview:cardview:${Versions.AndroidX.cardview}"
const val androidx_constraintlayout = "androidx.constraintlayout:constraintlayout:${Versions.AndroidX.constraintlayout}"
Expand Down Expand Up @@ -138,6 +140,7 @@ object Dependencies {

const val mozilla_glean_forUnitTests = "org.mozilla.telemetry:glean-forUnitTests:${Versions.mozilla_glean}"

const val mozilla_sync_autofill = "org.mozilla.appservices:autofill:${Versions.mozilla_appservices}"
const val mozilla_sync_logins = "org.mozilla.appservices:logins:${Versions.mozilla_appservices}"
const val mozilla_places = "org.mozilla.appservices:places:${Versions.mozilla_appservices}"
const val mozilla_sync_manager = "org.mozilla.appservices:syncmanager:${Versions.mozilla_appservices}"
Expand Down
6 changes: 3 additions & 3 deletions buildSrc/src/main/java/Gecko.kt
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,17 @@ internal object GeckoVersions {
/**
* GeckoView Nightly Version.
*/
const val nightly_version = "87.0.20210216094005"
const val nightly_version = "88.0.20210223085042"

/**
* GeckoView Beta Version.
*/
const val beta_version = "86.0.20210212222924"
const val beta_version = "87.0.20210222154334"

/**
* GeckoView Release Version.
*/
const val release_version = "85.0.20210208133944"
const val release_version = "86.0.20210222142601"
}

@Suppress("Unused", "MaxLineLength")
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<!-- Description for the button to accept the search suggestion and continue editing the search. -->
<string name="mozac_browser_awesomebar_edit_suggestion">सूचना स्वीकारा व संपादित करा</string>
</resources>
15 changes: 5 additions & 10 deletions components/browser/engine-gecko-beta/docs/metrics.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,8 @@ The following metrics are added to the ping:

| Name | Type | Description | Data reviews | Extras | Expiration | [Data Sensitivity](https://wiki.mozilla.org/Firefox/Data_Collection) |
| --- | --- | --- | --- | --- | --- | --- |
| avif.aom_decode_error |[quantity](https://mozilla.github.io/glean/book/user/metrics/quantity.html) |Image-decode Error from AOM decoder |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1670827#c9)|<ul><li>unit: error code</li></ul>|never | |
| avif.aom_decode_error |[labeled_counter](https://mozilla.github.io/glean/book/user/metrics/labeled_counters.html) |Image-decode Error from AOM decoder |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1690406#c3)|<ul><li>error</li><li>mem_error</li><li>abi_mismatch</li><li>incapable</li><li>unsup_bitstream</li><li>unsup_feature</li><li>corrupt_frame</li><li>invalid_param</li></ul>|never | |
| avif.bit_depth |[labeled_counter](https://mozilla.github.io/glean/book/user/metrics/labeled_counters.html) |Bits per pixel of AVIF image. |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1670827#c9)|<ul><li>color_8</li><li>color_10</li><li>color_12</li><li>color_16</li><li>unknown</li></ul>|never | |
| avif.dav1d_decode_error |[quantity](https://mozilla.github.io/glean/book/user/metrics/quantity.html) |Image-decode Error from dav1d decoder |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1670827#c9)|<ul><li>unit: error code</li></ul>|never | |
| avif.decode_result |[labeled_counter](https://mozilla.github.io/glean/book/user/metrics/labeled_counters.html) |Decode result of AVIF image. |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1670827#c9)|<ul><li>success</li><li>parse_error</li><li>no_primary_item</li><li>decode_error</li><li>size_overflow</li><li>out_of_memory</li><li>pipe_init_error</li><li>write_buffer_error</li><li>alpha_y_sz_mismatch</li><li>alpha_y_bpc_mismatch</li></ul>|never | |
| avif.decoder |[labeled_counter](https://mozilla.github.io/glean/book/user/metrics/labeled_counters.html) |Decoder of AVIF image. |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1670827#c9)|<ul><li>dav1d</li><li>aom</li></ul>|never | |
| avif.yuv_color_space |[labeled_counter](https://mozilla.github.io/glean/book/user/metrics/labeled_counters.html) |YUV color space of AVIF image. |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1670827#c9)|<ul><li>bt601</li><li>bt709</li><li>bt2020</li><li>identity</li><li>unknown</li></ul>|never | |
Expand All @@ -37,8 +36,8 @@ The following metrics are added to the ping:
| geckoview.version |[string](https://mozilla.github.io/glean/book/user/metrics/string.html) |The version of the Gecko engine, example: 74.0a1 |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1611240#c2)||never | |
| gfx.adapter.primary.description |[string](https://mozilla.github.io/glean/book/user/metrics/string.html) |Long form description of the Graphics adapter |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1594145#c4)||never | |
| gfx.adapter.primary.device_id |[string](https://mozilla.github.io/glean/book/user/metrics/string.html) |Graphics adapter device identification |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1594145#c4)||never | |
| gfx.adapter.primary.driver_date |[string](https://mozilla.github.io/glean/book/user/metrics/string.html) |Graphics adapter driver date |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1594145#c4)||2023-02-01 | |
| gfx.adapter.primary.driver_files |[string](https://mozilla.github.io/glean/book/user/metrics/string.html) |List of graphics adapter driver files |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1594145#c4)||2022-02-01 | |
| gfx.adapter.primary.driver_date |[string](https://mozilla.github.io/glean/book/user/metrics/string.html) |Graphics adapter driver date |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1594145#c4)||never | |
| gfx.adapter.primary.driver_files |[string](https://mozilla.github.io/glean/book/user/metrics/string.html) |List of graphics adapter driver files |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1594145#c4)||never | |
| gfx.adapter.primary.driver_vendor |[string](https://mozilla.github.io/glean/book/user/metrics/string.html) |Graphics adapter driver vendor identification |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1594145#c4)||never | |
| gfx.adapter.primary.driver_version |[string](https://mozilla.github.io/glean/book/user/metrics/string.html) |Graphics adapter driver version |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1594145#c4)||never | |
| gfx.adapter.primary.ram |[quantity](https://mozilla.github.io/glean/book/user/metrics/quantity.html) |Graphics adapter dedicated memory |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1594145#c4)|<ul><li>unit: Megabytes</li></ul>|never | |
Expand All @@ -62,8 +61,8 @@ The following metrics are added to the ping:
| gfx.display.primary_width |[quantity](https://mozilla.github.io/glean/book/user/metrics/quantity.html) |Width of the primary display, takes device rotation into account. |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1594145#c4)|<ul><li>unit: Pixels</li></ul>|never | |
| gfx.feature.webrender |[string](https://mozilla.github.io/glean/book/user/metrics/string.html) |Whether webrender is enabled or disabled, and why. |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1687312#c5)||never | |
| gfx.scroll_present_latency |[timing_distribution](https://mozilla.github.io/glean/book/user/metrics/timing_distribution.html) |Time between receiving a scroll event on the event loop and compositing its result onto the screen (ms). |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1604818#c4)||never | |
| gfx.status.compositor |[string](https://mozilla.github.io/glean/book/user/metrics/string.html) |Name of the graphics compositor in use. Possible values are "opengl, d3d11, client, webrender or basic" |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1594145#c4)||2022-02-01 | |
| gfx.status.headless |[boolean](https://mozilla.github.io/glean/book/user/metrics/boolean.html) |Boolean indicated whether graphics is running in headless (no display) mode |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1594145#c4)||2022-02-01 | |
| gfx.status.compositor |[string](https://mozilla.github.io/glean/book/user/metrics/string.html) |Name of the graphics compositor in use. Possible values are "opengl, d3d11, client, webrender or basic" |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1594145#c4)||never | |
| gfx.status.headless |[boolean](https://mozilla.github.io/glean/book/user/metrics/boolean.html) |Boolean indicated whether graphics is running in headless (no display) mode |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1594145#c4)||never | |
| gfx.webrender.framebuild_time |[timing_distribution](https://mozilla.github.io/glean/book/user/metrics/timing_distribution.html) |The time taken to build a webrender frame. This involves calculating the visibility of primitives, requesting resources, and building the render passes which will be used to render the frame. |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1584109#c1)||never | |
| gfx.webrender.scenebuild_time |[timing_distribution](https://mozilla.github.io/glean/book/user/metrics/timing_distribution.html) |The time taken to build a webrender scene. This occurs each time webrender receives a new display list. This additionally includes blob rasterization time. |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1584109#c1)||never | |
| gfx.webrender.sceneswap_time |[timing_distribution](https://mozilla.github.io/glean/book/user/metrics/timing_distribution.html) |The time taken to do a webrender scene swap. This is book-keeping that APZ must perform once webrender has built a new scene. |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1584109#c1)||never | |
Expand Down Expand Up @@ -106,11 +105,7 @@ The following metrics are added to the ping:
| performance.time.dom_content_loaded_start |[timing_distribution](https://mozilla.github.io/glean/book/user/metrics/timing_distribution.html) |Time from navigationStart to domContentLoadedEventStart as per the W3C Performance Timing API. |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1580077#c10)||never | |
| performance.time.dom_interactive |[timing_distribution](https://mozilla.github.io/glean/book/user/metrics/timing_distribution.html) |Time from navigationStart to domInteractive as per the W3C Performance Timing API. |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1580077#c10)||never | |
| performance.time.load_event_end |[timing_distribution](https://mozilla.github.io/glean/book/user/metrics/timing_distribution.html) |Time from navigationStart to loadEventEnd as per the W3C Performance Timing API. |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1580077#c10)||never | |
| performance.time.load_event_end_no_preload |[timing_distribution](https://mozilla.github.io/glean/book/user/metrics/timing_distribution.html) |Time from navigationStart to [`loadEventEnd`](https://www.w3.org/TR/ navigation-timing/#dom-performancetiming-loadend) as per the W3C Performance Timing API. This is only submitted on when the document would not preload a resource. |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1657188#c5)||2021-02-24 | |
| performance.time.load_event_end_preload |[timing_distribution](https://mozilla.github.io/glean/book/user/metrics/timing_distribution.html) |Time from navigationStart to [`loadEventEnd`](https://www.w3.org/TR/ navigation-timing/#dom-performancetiming-loadend) as per the W3C Performance Timing API. This is only submitted on when the document would preload a resource (i.e., if it encounters a `<link>` element or a `Link` header with `rel="preload"`), even if the `network.preload` pref is disabled. |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1657188#c5)||2021-02-24 | |
| performance.time.load_event_start |[timing_distribution](https://mozilla.github.io/glean/book/user/metrics/timing_distribution.html) |Time from navigationStart to loadEventStart as per the W3C Performance Timing API. |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1580077#c10)||never | |
| performance.time.load_event_start_no_preload |[timing_distribution](https://mozilla.github.io/glean/book/user/metrics/timing_distribution.html) |Time from navigationStart to [`loadEventStart`](https://www.w3.org/TR/ navigation-timing/#dom-performancetiming-loadstart) as per the W3C Performance Timing API. This is only submitted on when the document would not preload a resource. |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1657188#c5)||2021-02-24 | |
| performance.time.load_event_start_preload |[timing_distribution](https://mozilla.github.io/glean/book/user/metrics/timing_distribution.html) |Time from navigationStart to [`loadEventStart`](https://www.w3.org/TR/ navigation-timing/#dom-performancetiming-loadstart) as per the W3C Performance Timing API. This is only submitted on when the document would preload a resource (i.e., if it encounters a `<link>` element or a `Link` header with `rel="preload"`), even if the `network.preload` pref is disabled. |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1657188#c5)||2021-02-24 | |
| performance.time.response_start |[timing_distribution](https://mozilla.github.io/glean/book/user/metrics/timing_distribution.html) |Time from navigationStart to responseStart as per the W3C Performance Timing API. |[1](https://bugzilla.mozilla.org/show_bug.cgi?id=1580077#c10)||never | |
| test.glean.geckoview.streaming |[timing_distribution](https://mozilla.github.io/glean/book/user/metrics/timing_distribution.html) |A test-only, disabled metric. This is required to guarantee that a `GleanGeckoHistogramMapping` is always generated, even though the GeckoView AAR exports no metric. Please note that the data-review field below contains no review, since this metric is disabled and not allowed to collect any data. |[1](https://bugzilla.mozilla.org/1566374)||never | |

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ class GeckoEngineSession(
}

geckoSession.load(loader)
Fact(Component.BROWSER_ENGINE_GECKO_BETA, Action.IMPLEMENTATION_DETAIL, "GeckoSession.load").collect()
Fact(Component.BROWSER_ENGINE_GECKO_NIGHTLY, Action.IMPLEMENTATION_DETAIL, "GeckoSession.load").collect()
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,12 @@ class GeckoEngineView @JvmOverloads constructor(
@VisibleForTesting(otherwise = VisibleForTesting.PRIVATE)
internal var currentSelection: BasicSelectionActionDelegate? = null

/**
* Cache of the last valid input result we got from GeckoView.
*/
@VisibleForTesting
internal var lastInputResult: EngineView.InputResult = EngineView.InputResult.INPUT_RESULT_UNHANDLED

override var selectionActionDelegate: SelectionActionDelegate? = null

init {
Expand Down Expand Up @@ -174,12 +180,19 @@ class GeckoEngineView @JvmOverloads constructor(
// Direct mapping of GeckoView's returned values.
// If not fail fast to allow for a quick fix.
val input = geckoView.inputResult
return when (input) {
lastInputResult = when (input) {
0 -> EngineView.InputResult.INPUT_RESULT_UNHANDLED
1, 3 -> EngineView.InputResult.INPUT_RESULT_HANDLED
1 -> EngineView.InputResult.INPUT_RESULT_HANDLED
2 -> EngineView.InputResult.INPUT_RESULT_HANDLED_CONTENT
else -> throw IllegalArgumentException("Unexpected geckoView.inputResult: \"${geckoView.inputResult}\"")
3 -> {
// Drop this result and return the previous.
// See https://bugzilla.mozilla.org/show_bug.cgi?id=1687430 for details
lastInputResult
}
else -> throw IllegalArgumentException("Unexpected geckoView.inputResult: \"$input\"")
}

return lastInputResult
}

override fun setVerticalClipping(clippingHeight: Int) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import mozilla.components.browser.engine.gecko.GeckoEngineSession
import mozilla.components.browser.engine.gecko.await
import mozilla.components.concept.engine.mediasession.MediaSession
import org.mozilla.geckoview.GeckoSession
import org.mozilla.geckoview.Image.ImageProcessingException
import org.mozilla.geckoview.MediaSession as GeckoViewMediaSession

private const val ARTWORK_RETRIEVE_TIMEOUT = 1000L
Expand Down Expand Up @@ -42,7 +43,7 @@ internal class GeckoMediaSessionDelegate(
withTimeoutOrNull(ARTWORK_RETRIEVE_TIMEOUT) {
it.getBitmap(ARTWORK_IMAGE_SIZE).await()
}
} catch (e: IllegalArgumentException) {
} catch (e: ImageProcessingException) {
null
}
}
Expand Down
Loading

0 comments on commit f84dc4e

Please sign in to comment.