Граф коммитов

31513 Коммитов

Автор SHA1 Сообщение Дата
Eemeli Aro 1662ea09fa Bug 1789406 - Remove brand.dtd files as unused. r=flod,geckoview-reviewers,owlish
After the preceding changes, brand.dtd has no more actual users and may be removed.

One mochitest is switched to use a different DTD file which will still remain in the tree.

The dependency in aboutSupport.xhtml appears to have been accidentally left in when its localization was migrated to Fluent.

Differential Revision: https://phabricator.services.mozilla.com/D156668
2022-10-07 18:40:28 +00:00
Makoto Kato a66ffe1baa Bug 1714496 - Part 2. geckoview-junit test for image keyboard support. r=geckoview-reviewers,owlish
Although this test doesn't run on our CI since CI uses Android 7.0, I would
like to add this for the future.

Image keyboard support requires content:// uri for image, so we need content
provider for testing this feature.

Differential Revision: https://phabricator.services.mozilla.com/D157714
2022-10-07 09:03:31 +00:00
Makoto Kato 8821cd8445 Bug 1714496 - Part 1. Implement Image keyboard support. r=geckoview-reviewers,calu
GBoard has image keyboard support, and spec issue is resolved [*1]. So this
adds image keyboard support via GBoard and Android 7.1+.

*1 https://github.com/w3c/input-events/issues/117

Differential Revision: https://phabricator.services.mozilla.com/D157713
2022-10-07 09:03:31 +00:00
Andreea Pavel 86cc5257f0 Bug 1754570 - temporarily disable capturePixelsAfterGpuProcessCrash on opt r=intermittent-reviewers,geckoview-reviewers,m_kato,MasterWayZ
Differential Revision: https://phabricator.services.mozilla.com/D158340
2022-10-03 12:11:51 +00:00
Ryan VanderMeulen a5656862a6 Bug 1791878 - Update to kotlin 1.7.20 and gradle plugin 7.3.0. r=geckoview-reviewers,m_kato
Differential Revision: https://phabricator.services.mozilla.com/D157864
2022-09-29 21:05:51 +00:00
Mark Banner 8d1ebcb9d6 Bug 1792365 - Convert toolkit/modules consumers to use ES module imports directly. r=webdriver-reviewers,perftest-reviewers,geckoview-reviewers,extension-reviewers,preferences-reviewers,desktop-theme-reviewers,application-update-reviewers,pip-reviewers,credential-management-reviewers,robwu,Gijs,sgalich,bytesized,AlexandruIonescu,dao,m_kato
Differential Revision: https://phabricator.services.mozilla.com/D158094
2022-09-29 06:52:34 +00:00
Jamie Nicol 49c0f0ed43 Bug 1780093 - Use custom SurfaceView which allows magnifier widget to work. r=geckoview-reviewers,owlish
The android magnifier widget does not work when using our
SurfaceControl rendering path, as we no longer render in to the
Surface provided by the SurfaceView, but instead into a child Surface
we have created and attached the SurfaceControl.

To fix this, we create a SurfaceView subclass, MagnifiableSurfaceView,
which allows us to set an override Surface to be used by the
magnifier. This class works by overriding getHolder() to return a
custom SurfaceHolder, which returns our override Surface rather than
the default one when called by the Magnifier class.

Depends on D157308

Differential Revision: https://phabricator.services.mozilla.com/D157309
2022-09-21 17:30:26 +00:00
Jamie Nicol 5e60f35505 Bug 1780093 - Remove code for enabling/disabling SurfaceControl rendering path. r=geckoview-reviewers,owlish
In order to fix the magnifier widget being broken, the previous patch
in this bug added a mechanism to disable and enable the SurfaceControl
rendering path. This caused some glitches to occur, so we removed the
calls to that code in bug 1783542, but the code remained.

As we now have an alternative solution to fix the magnifier widget, we
no longer require this code. This patch therefore reverts the original
patch, to lead the way for the new solution in the next patch.

Differential Revision: https://phabricator.services.mozilla.com/D157308
2022-09-21 17:30:25 +00:00
owlishDeveloper 5f3ce8227f Bug 1791046 - Remove deprecated cookie lifetime policy API and deprecated set permission API r=geckoview-reviewers,calu
Differential Revision: https://phabricator.services.mozilla.com/D157523
2022-09-20 19:32:51 +00:00
Andreea Pavel daea5b0dd9 Backed out changeset 2c2bc5fd317f (bug 1791046) for lint failure on a CLOSED TREE 2022-09-20 19:39:47 +03:00
owlishDeveloper 7264f7ca97 Bug 1791046 - Remove deprecated cookie lifetime policy API r=geckoview-reviewers,calu
Differential Revision: https://phabricator.services.mozilla.com/D157523
2022-09-20 16:15:14 +00:00
Eemeli Aro 90bc1261e7 Bug 1786186 - Migrate mobile about:config to Fluent. r=geckoview-reviewers,fluent-reviewers,flod,owlish
This migration creates the first FTL file under mobile/android/.
As GeckoView isn't actually localised (see bug 1605358), this file
is not exposed to localisers.

A migration script is still included, as previous localisations of
the about:config view's strings are available from its Fennec days.
Running the script will fail in an m-c checkout bootstrapped for
desktop development; it's possible to hack around this by manually
setting the `l10n_toml` value in `python/l10n/test_fluent_migrations/fmt.py`.

Differential Revision: https://phabricator.services.mozilla.com/D155450
2022-09-20 11:53:37 +00:00
Dana Keeler 923d7b2029 Bug 1790451 - make nsIChannel.securityInfo concrete as nsITransportSecurityInfo r=kershaw,necko-reviewers,valentin,geckoview-reviewers,owlish
Differential Revision: https://phabricator.services.mozilla.com/D157136
2022-09-20 03:58:49 +00:00
samihda 462e29480e Bug 1510975 - Match package name with file path. r=m_kato,geckoview-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D157335
2022-09-19 10:53:37 +00:00
Ryan VanderMeulen defeab2235 Backed out changeset 6376af715fb9 (bug 1787274) for Fenix UI test failures. 2022-09-15 13:10:33 -04:00
Morgan Rae Reschenberg 5afbf8d60d Bug 1787274: Use mCachedFields viewport cache for determining offscreen state r=Jamie,geckoview-reviewers,owlish
Differential Revision: https://phabricator.services.mozilla.com/D155903
2022-09-14 22:02:06 +00:00
Butkovits Atila 4fc48f6705 Backed out changeset 7d2bb2e5fb73 (bug 1787274) for causing geckoview failures. 2022-09-14 22:09:11 +03:00
Morgan Rae Reschenberg f7de79f06d Bug 1787274: Use mCachedFields viewport cache for determining offscreen state r=Jamie,geckoview-reviewers,owlish
Differential Revision: https://phabricator.services.mozilla.com/D155903
2022-09-14 17:47:43 +00:00
Makoto Kato e73b7956db Bug 1776829 - Implement "Paste" permission action for clipboard.readText. r=geckoview-reviewers,owlish
When calling `clipboard.readText` on content script, Gecko dispatches
`MozClipboardReadPaste` event.  On Desktop Firefox uses XUL pop up window
to handle it, then it shows "Paste" button whether user can allow to read
clipboard data.

But GeckoView doesn't have XUL pop up. To implement this feature, we show
"Paste" pop up using action mode as default. Also, browser side can override
delegated methods if it wants another permission pop up or to support Android L
(Android L doesn't have action mode).

Differential Revision: https://phabricator.services.mozilla.com/D151102
2022-09-12 07:36:52 +00:00
Makoto Kato 6f6a4de1ef Bug 1786452 - Finish overscroll animation when finishing pan. r=geckoview-reviewers,owlish,m_kato
(Co-authored with m_kato)

GeckoView's overscroll is implemented by OS side using
`WidgetOverscrollEffect`.

When not releasing finger during overscroll, stretched animation is kept on
Android 12+ since `EdgeEffect.onRelease` isn't called. Then, when releasing
finger, this animation isn't finished on GeckoView with Android 12+.

When this situation, APZ doesn't call
`WidgetOverscrollEffect::HandleFlingOverscroll` by releasing finger due to too
small velocity value in `AsyncPanZoomController::HandleEndOfPan`. So there is
no way to detect whether releasing finger on GeckoView side.

I think We should notify GeckoView of releasing finger to finish animation.

This won't occurs on `GenericOverscollEffect` on macOS since overscoll
animation is managed by APZ and this animation will be finished by
`UpdateAnimation`.

Differential Revision: https://phabricator.services.mozilla.com/D156611
2022-09-12 07:25:05 +00:00
Makoto Kato 708604622a Bug 1786862 - Add try-catch block for SecurityException by autofill manager. r=geckoview-reviewers,calu
Original issue was bug 1701283, but that fix was removed by bug 1755094
unfortunately.

Some devices (autofill service?) seem to throw a `SecurityException` when
calling autofill manager. So we need try-catch block for it.

Differential Revision: https://phabricator.services.mozilla.com/D156501
2022-09-12 03:20:51 +00:00
Eemeli Aro a293e05849 Bug 1734217 - Drop netError.dtd and appstrings.properties from mobile as unused. r=geckoview-reviewers,nalexander,calu
These files were made available as:
- `chrome://browser/locale/netError.dtd`
- `chrome://browser/locale/appstrings.properties`

For desktop, overrides are defined in `browser/base/jar.mn` that map the corresponding `global/` paths to the above:
```
 % override chrome://global/locale/appstrings.properties chrome://browser/locale/appstrings.properties
 % override chrome://global/locale/netError.dtd chrome://browser/locale/netError.dtd
```

For mobile, similar overrides were earlier defined in `mobile/android/chrome/jar.mn`, but that file was removed in bug 1589182 three years ago.

Consequently, the `global/` paths for these files that are used under `docshell/` and `dom/` have resolved to the non-overridden `dom/` files since Firefox 72.

It should therefore be safe to remove them.

Differential Revision: https://phabricator.services.mozilla.com/D156403
2022-09-09 06:47:45 +00:00
Ryan VanderMeulen 998208305e Bug 1786164 - Add more Gradle JVM memory flags. r=geckoview-reviewers,jonalmeida
See https://github.com/mozilla-mobile/fenix/pull/26542 for more discussion.
Also specify a lower maximum heap size more in line with other projects and
remove some redundant settings in other gradle.properties files.

Differential Revision: https://phabricator.services.mozilla.com/D155179
2022-08-31 22:10:39 +00:00
Ryan VanderMeulen 450ee76669 Bug 1786174 - Fix some other WebExtension warnings from the linting logs. r=geckoview-reviewers,calu
Differential Revision: https://phabricator.services.mozilla.com/D155153
2022-08-31 22:10:39 +00:00
Ryan VanderMeulen 3744dc5f92 Bug 1786174 - Update Android linter to v30.2.2 and fix newly-flagged errors. r=geckoview-reviewers,jonalmeida
Differential Revision: https://phabricator.services.mozilla.com/D155152
2022-08-31 22:10:39 +00:00
Ryan VanderMeulen 893cf3efd4 Bug 1786164 - Update gradle and plugin to the latest versions. r=geckoview-reviewers,jonalmeida
Differential Revision: https://phabricator.services.mozilla.com/D155151
2022-08-31 22:10:38 +00:00
Ryan VanderMeulen b3938e97ab Bug 1785838 - Bump Kotlin to version 1.6.21 and a update a few other gradle dependencies. r=geckoview-reviewers,calu
Differential Revision: https://phabricator.services.mozilla.com/D154988
2022-08-31 22:10:37 +00:00
Olivia Hall fd773b706c Bug 1765835 - Adjustments to Location Provider r=geckoview-reviewers,owlish,m_kato,smaug
In Geolocation.cpp, the call to start the geolocation device always
had HighAccuracyRequested() set to false because no callbacks were
listening. Changed to set the callbacks first, before listening.

In Android, this patch stops the use of checking for last known location
on high accuracy location requests, adjusts comparing locations,
and also streamlines the criteria for picking the best location provider.

Differential Revision: https://phabricator.services.mozilla.com/D153226
2022-08-31 18:50:16 +00:00
Makoto Kato 3577ed2643 Bug 1786449 - Revert overscroll support part of bug 1724480. r=geckoview-reviewers,calu
To support overscroll drawing on old Andorid (9 or early), we use the
reflection to access `Paint` object. But this is removed by bug 1724480. So I
would like to revert overscroll part for Android 9 or early.

I tested on old Galaxy S7 (Android 9).

Differential Revision: https://phabricator.services.mozilla.com/D155716
2022-08-31 14:31:14 +00:00
Dana Keeler b4c45d4248 Bug 1781104 - remove unnecessary bits parameter from nsICertOverrideService r=djackson,necko-reviewers,geckoview-reviewers,extension-reviewers,kershaw,calu
Differential Revision: https://phabricator.services.mozilla.com/D152826
2022-08-26 18:48:38 +00:00
Makoto Kato 236776ef99 Bug 1786119 - Set current size to EdgeEffect when reinitializing OverscrollEdgeEffect. r=geckoview-reviewers,owlish
When switching to previous tab, overscroll animation doesn't work since new
`EdgeEffect` doesn't have size. So we should set it from previous information.
If new size is available, `GeckoSession.onWindowBoundsChanged` will set new
size.

Also, this fix includes that `OverscrollEdgeEffect` doesn't use current
`GeckoSession` to draw edge effect. When switching to new `GeckoSession`,
we should set it to `OverscrollEdgeEffect`. `OverscrollEdgeEffect` is public
API, so I don't modify it for this.

Differential Revision: https://phabricator.services.mozilla.com/D155144
2022-08-26 16:11:19 +00:00
Mark Banner baa8dfdef9 Bug 1786197 - Turn on ESLint rule for prefer-boolean-length-check for mobile/android. r=geckoview-reviewers,owlish
Differential Revision: https://phabricator.services.mozilla.com/D155171
2022-08-26 13:39:36 +00:00
Botond Ballo 8466c5994a Bug 1786974 - Avoid PanZoomControllerTest#scrollToVerticalOnZoomedContent{Smooth,Auto} failure due to rounding. r=hiro,geckoview-reviewers,owlish
window.innerHeight is rounded to integer because of dom.innerSize.rounded=true,
so the quantity being compared to it needs to be rounded as well.

Differential Revision: https://phabricator.services.mozilla.com/D155519
2022-08-25 01:25:25 +00:00
Luca Greco 9efa813720 Bug 1760608 - Restrict MV2 pageAction/browserAction setPopup to same extension urls on GeckoView. r=mixedpuppy,geckoview-reviewers,owlish
This patch extends restricts setPopup to extension url to MV2 extensions running on GeckoView.

Differential Revision: https://phabricator.services.mozilla.com/D154549
2022-08-23 10:35:58 +00:00
Luca Greco 28400cd40e Bug 1760608 - Fix and reenable GeckoView ExtensionActionTest.testOpenPopup. r=geckoview-reviewers,ohall
This patch fixes a pre-existing "setPopup + openPopup" GeckoView test case that was apparently disable
because it was failing intermittently.

While trying to run it locally I noticed that the test was getting stuck because there is no
tab delegate that would be allowing the test extension to update the current tab from
http://example.com to the extension page that was meant to be triggering the openPopup API call.

Loading the extension page using mainSession.loadUrl seems to be making the test able to fully
run and pass.

It is possible that the test case was originally working but got broken while it started to be ignored,
the test was missing to await for the setPopup call to be fully handled and that may have been likele
a source of intermittent failures over a larger number of runs.

Differential Revision: https://phabricator.services.mozilla.com/D154548
2022-08-23 10:35:58 +00:00
Emilio Cobos Álvarez c20ec755c9 Bug 1782751 - Make desktop viewport mode a synced BrowsingContext field. r=twisniewski
So that it's preserved properly across replacements (bug 1781936).

Differential Revision: https://phabricator.services.mozilla.com/D155274
2022-08-22 22:12:07 +00:00
Olivia Hall 4a2c220e7c Bug 1780557 - High Rate Sensor Android Permission r=geckoview-reviewers,calu
Beginning in Android 12, apps needing to use high sensor rates need to
have the HIGH_SAMPLING_RATE_SENSORS permission requested.

Differential Revision: https://phabricator.services.mozilla.com/D155238
2022-08-22 17:57:39 +00:00
Jamie Nicol 88814ceb27 Bug 1783542 - Temporarily stop toggling SurfaceControl usage. r=geckoview-reviewers,calu
In bug 1780093 we discovered that our usage of the SurfaceControl
compositing path was preventing the text selection magnifier from
working. We attempted to toggle the SurfaceControl compositing path
off when the magnifier was active, however this has caused much more
severe issues with rendering content at the wrong size after the
keyboard has been dismissed.

For now, stop toggling SurfaceControl usage until we have found out
how to do so without rendering at the wrong size. This will mean the
magnifier will once again not work.

Differential Revision: https://phabricator.services.mozilla.com/D155202
2022-08-22 17:44:41 +00:00
Olivia Hall 8454981589 Bug 1771012 - GeckoView Open Tabs Test Utility r=geckoview-reviewers,owlish
Adds event "GeckoView:Test:NewTab”, which allow testers to create tabs.

`GeckoViewTestUtils.jsm` sends the event from the JavaScript side for
use in testing.

A `ServiceWorkerDelegate` is required to be set for the
`GeckoRuntime` to use these events, which was setup on the test
runner.

Differential Revision: https://phabricator.services.mozilla.com/D152891
2022-08-22 14:44:38 +00:00
Sylvestre Ledru 128c74caac Bug 1785451 - Ride along: Fix some typos r=linter-reviewers,fluent-reviewers,geckoview-reviewers,extension-reviewers,keeler,rpl,calu,ahal,flod DONTBUILD
Differential Revision: https://phabricator.services.mozilla.com/D154946
2022-08-18 07:29:08 +00:00
Botond Ballo cd56c8b9ae Bug 1746336 - Add a new geckoview-junit test. r=hiro,geckoview-reviewers,calu
Depends on D152351

Differential Revision: https://phabricator.services.mozilla.com/D152352
2022-08-18 02:15:39 +00:00
Botond Ballo 65a722e6e1 Bug 1746336 - Treat nsEventStatus_eIgnore as INPUT_RESULT_UNHANDLED consistently. r=hiro,geckoview-reviewers,owlish
Differential Revision: https://phabricator.services.mozilla.com/D152351
2022-08-18 02:07:14 +00:00
Ryan VanderMeulen b99ba1c11c Bug 1785302 - Fix GeckoView gradle warnings. r=geckoview-reviewers,owlish
Differential Revision: https://phabricator.services.mozilla.com/D154927
2022-08-17 22:04:29 +00:00
Agi Sferro cd000ebc03 Bug 1648158 - Store SHIP (Session History in Parent Process) support on Android. r=geckoview-reviewers,owlish
Instead of using SessionStateAggregator.js send() to collect history data and send the event StateUpdated to the app, the new GeckoViewSessionStore is used. It is enabled when fission is true and initialized by GeckoViewStartup when Services.appinfo.sessionHistoryInParent is true. It will observe two existing topics: browsing-context-did-set-embedder, which creates the history listener, and browsing-context-discarded, which unregisters it. When the history listener is created, it will collect history from the parent. It will only collect data when the current uri is not “about:blank” and when the history count is greater than 0. It uses SessionHistory’s collectFromParent.

The new code path was manually confirmed by debugging the app history delegate to see that the state map contains all the history data.

Differential Revision: https://phabricator.services.mozilla.com/D150020
2022-08-17 17:03:27 +00:00
Makoto Kato a2a31e8702 Bug 1783804 - Use std::move for InputData since copy constructor of InputData doesn't copy all member variable. r=geckoview-reviewers,calu
When turning on fission, OOP child frame doesn't receive touch events such as
`touchstart`.

When dispatching touch event from GeckoView side, some informations such as
`mLayersId` are missing since copy constructor of `MultiTouchInput` doesn't
copy all information.

Since the structure of Input data has a lot of members, we should use
`std::move` instead of copy constructor of `InputData`. It can avoid
unnecessary copy.

Differential Revision: https://phabricator.services.mozilla.com/D154242
2022-08-15 08:47:35 +00:00
Sylvestre Ledru 8a829cb5fa Bug 1783917 - geckoview doc: Remove references to arc r=geckoview-reviewers,calu DONTBUILD
Differential Revision: https://phabricator.services.mozilla.com/D154120
2022-08-10 15:54:42 +00:00
Jamie Nicol 8f3214f02a Bug 1783542 - Disable SurfaceControl only when magnifier is active. r=geckoview-reviewers,owlish
Rather than when a selection is active. Originally we chose to disable
SurfaceControl whenever a selection was active, as it is then likely
the magnifiers may be shown soon, but it reduced the amount of times
we switch between SurfaceControl being enabled and disabled when the
selection is frequently modified.

However, that has 2 issues: First, the magnifier can be shown when
dragging a single caret in a form, rather than just when a selection
is active. With the original fix, the magnifier did not work in this
case. And second, we encountered a bug when the widget is resized at
the same time as SurfaceControl is toggled, where we end up rendering
the page at the wrong size.

This patch therefore makes us only disable SurfaceControl when the
magnifier is actually being shown. This may cause us to enable or
disable it more frequently, but that doesn't appear to be a big deal.

Differential Revision: https://phabricator.services.mozilla.com/D154086
2022-08-09 18:50:41 +00:00
Kagami Sascha Rosylight 16ea24f6cc Bug 1769290 - Part 26: Emit errors from JSHandleRootedTypedefChecker r=andi,geckoview-reviewers,owlish
Differential Revision: https://phabricator.services.mozilla.com/D151842
2022-08-09 14:13:30 +00:00
Rob Wu 7e7534ced4 Bug 1780747 - Register DNR schema and permissions r=rpl,geckoview-reviewers,owlish,flod
This patch adds the minimum necessary to register the
declarativeNetRequest API and its permissions, behind prefs.

Tests have been added/updated to verify that the permissions and API
access are enforced correctly (effectiveness of preferences, API
visibility, permission warnings).

Before landing this, we need to register the permission warning in
Android-Components too, as mentioned in the bug (i.e. bug 1671453).

Differential Revision: https://phabricator.services.mozilla.com/D152503
2022-08-09 12:16:34 +00:00
Cristian Tuns a96814126e Backed out 2 changesets (bug 1780747) for causing xpcshell failures on test_ext_permission_warnings.js CLOSED TREE
Backed out changeset be950e847c33 (bug 1780747)
Backed out changeset b07c7315a02a (bug 1780747)
2022-08-08 19:04:56 -04:00