Commit Graph

26977 Commits

Author SHA1 Message Date
Jim Chen
0f87b879ff Bug 1489250 - Don't send window changed event if a11y is off; r=eeejay
Don't send window changed event if a11y has been turned off in the mean
time.

Differential Revision: https://phabricator.services.mozilla.com/D5192

--HG--
extra : moz-landing-system : lando
2018-09-06 19:05:13 +00:00
arthur.iakab
c66e0f9611 Merge mozilla-central to autoland 2018-09-06 19:50:32 +03:00
Coroiu Cristina
4391e69fb4 Backed out changeset b9e56df24edc (bug 1488174) for fennec crashing at startup a=backout 2018-09-06 18:16:18 +03:00
Imanol Fernandez
046418d262 Bug 1474847 - Fix GeckoSurfaceTexture not correctly removed from container when released: r=snorp,rbarker
When entering and exiting immersive mode multiple time (~30) the WebGL context can be lost. This is caused because GeckoSurfaceTexture things there are more than 200 textures created.

Differential Revision: https://phabricator.services.mozilla.com/D4235

--HG--
extra : moz-landing-system : lando
2018-09-06 15:35:31 +00:00
Andreea Pavel
746993f3e1 Merge mozilla-inbound to mozilla-central. a=merge 2018-09-06 07:37:40 +03:00
Jan Henning
b61527c675 Bug 1485151 - Part 2 - Switch our whitelisting of StrictMode violations to try-with-resources. r=jchen
In my opinion this is an altogether nicer way of setting and resetting temporary
StrictMode exceptions. The only fly in the ointment is that this causes a
warning about a technically unused variable that subsequently needs suppressing.

Differential Revision: https://phabricator.services.mozilla.com/D4889

--HG--
extra : rebase_source : 706af6665b709c2ed29730cf266c3267417e4a52
extra : source : 54a3c14eff313baade8bc40523f69fa9c7aaba75
2018-09-04 22:28:22 +02:00
Jan Henning
d56c15bf20 Bug 1485151 - Part 1 - Import StrictModeContext from Chromium. r=jchen,mhoye
Differential Revision: https://phabricator.services.mozilla.com/D4888

--HG--
extra : rebase_source : ddef96908ba44f5360efd5eb7b58a6396a2c0a2e
extra : source : f65da9b6f22e2d4f1cf59c39c590f726637a5764
2018-09-04 22:28:19 +02:00
Jan Henning
4377355106 Bug 1488174 - Use UpdateServiceHelper to decide on whether to add Updater notification channel. r=jchen
That way, we only add that notification channel if the updater really is active,
i.e. not if we've been installed from the Play Store.
Unfortunately, using the UpdateServiceHelper requires a Context, so adding/re-
moving the UPDATER_CHANNEL_TAG cannot be done during variable initialisation.

Differential Revision: https://phabricator.services.mozilla.com/D4890

--HG--
extra : moz-landing-system : lando
2018-09-05 19:07:50 +00:00
Jan Henning
aae0fb6c01 Bug 1479532 - Part 2 - Use more sensible importance level for default notification channel. r=jchen
Previously, most of our notifications were silent, so we adopt a default
priority of IMPORTANCE_LOW instead of IMPORTANCE_DEFAULT.

Since we cannot change the priority setting for existing users on Nightly any
more, we technically have to retire the old default channel and replace it by
a new channel with a different ID. While in a way this is circumventing Google's
API design and destroys any existing customisation users have set for that
channel, we are only using this exceptionally to *lower* the initial priority of
our default notification channel, which we accidentally set too high. Besides,
it is unlikely that there are many users who really want to receive all kinds of
random Firefox notifications with a high priority.

Differential Revision: https://phabricator.services.mozilla.com/D4364

--HG--
extra : moz-landing-system : lando
2018-09-05 18:47:04 +00:00
Margareta Eliza Balazs
b5430ee4da Merge mozilla-central to autoland. a=merge CLOSED TREE 2018-09-05 15:42:52 +03:00
Nicholas Nethercote
13643f64e8 Bug 1488321 - Fix up nsISHEntry.{index,getEntryAtIndex()}. r=nika
nsISHEntry.index is readonly, but if you pass `true` as getEntryAtIndex()'s
second argument, nsISHEntry.index will be modified. This is pretty gross.

This patch changes `index` so it's not readonly (because it's not!) and removes
getEntryAtIndex()'s second argument.

--HG--
extra : rebase_source : c519d77fcc1c3bda2f260b5888ce9cd0f6cfdab5
2018-09-05 09:02:37 +10:00
Petru Lingurar
817c2cd883 Bug 1480083 - After exiting PIP the restarted activity should have device's orientation; r=sdaswani
Differential Revision: https://phabricator.services.mozilla.com/D4939

--HG--
extra : moz-landing-system : lando
2018-09-04 16:14:30 +00:00
Bogdan Tara
f302cbb0b3 Merge inbound to mozilla-central. a=merge 2018-09-05 02:24:27 +03:00
Gurzau Raul
9e0f009576 Backed out 2 changesets (bug 1485151) on developer's request
Backed out changeset 2e667a7854b6 (bug 1485151)
Backed out changeset bae80c903001 (bug 1485151)
2018-09-04 23:38:35 +03:00
Mark Banner
c6885f5391 Bug 1488445 - Remove and replace obsolete ESLint rules. r=mossop
This removes a number of references to rules that are now deprecated or removed from ESLint.

- no-native-reassign is replaced with no-global-assign
- no-spaced-func is replaced with func-call-spacing (where enabled)

Depends on D4944

Differential Revision: https://phabricator.services.mozilla.com/D4946

--HG--
extra : moz-landing-system : lando
2018-09-04 18:08:43 +00:00
Kris Maglione
8aa378b328 Bug 1486249: Part 2 - Convert JS nsISimpleEnumerator implements to JS enumerators. r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D4291

--HG--
extra : rebase_source : be92be2a429c3ccd85898eb7f76404154eaf1287
2018-08-25 18:31:44 -07:00
Jan Henning
aa90eb25e9 Bug 1487834 - Test fallback URL support for Intent URIs. r=esawin
Differential Revision: https://phabricator.services.mozilla.com/D4781

--HG--
extra : moz-landing-system : lando
2018-09-03 23:10:47 +00:00
Andrei Lazar
e67236138a Bug 1486432 Leanplum push notifications are not received on devices with Android O or above r=JanH,flod
Added a default channel for Leanplum push notifications as fallback to cover the cases where we receive
push notifications from server with an invalid channel and the case where there are no channels configured
on server.

Provided a valid default icon for push notifications in Leanplum required for fallback strategy.

Differential Revision: https://phabricator.services.mozilla.com/D4704

--HG--
extra : moz-landing-system : lando
2018-09-03 10:21:51 +00:00
Ciure Andrei
e136281b52 Merge inbound to mozilla-central. a=merge 2018-09-03 12:35:26 +03:00
Nicholas Nethercote
70d22aa86a Bug 1487328 - Remove nsISHistoryListener.OnHistoryGo{Back,Forward}. r=nika
As per the previous commit, they are now subsumed by OnHistoryGotoIndex.

--HG--
extra : rebase_source : 627a32ed9378c7dd5364323183297933f90f9d72
2018-09-03 09:27:37 +10:00
Jan Henning
75f22f0fe1 Bug 1479532 - Part 1 - Create notification channel for receiving synced tabs. r=jchen
Differential Revision: https://phabricator.services.mozilla.com/D4366

--HG--
extra : moz-landing-system : lando
2018-09-02 20:09:09 +00:00
Jan Henning
238c91a232 Bug 1484001 - Avoid ending up with a null mRuntime after restoring state in GeckoView. r=snorp
If we don't have a saved session, we do nothing. If somebody called setSession
beforehand, we continue using that session, otherwise we create a fallback
session in onAttachedToWindow().

If we have a saved session and nobody called setSession, we use the saved
session. If the saved session was closed and doesn't have a runtime, we use the
default runtime as a fallback.

If we have both a saved session and somebody already called setSession, we
transfer what can be transferred from the saved session, unless the saved
session is closed and the session from setSession is open.
If the saved session was open, we use its runtime as well going forward (since
transferring the state from an open session transfers the window and the runtime
as well), otherwise we keep the old mRuntime.

Differential Revision: https://phabricator.services.mozilla.com/D4711

--HG--
extra : moz-landing-system : lando
2018-08-30 20:09:02 +00:00
Andrei Lazar
217881e6c8 Bug 1485719 (New_Tab_Deeplink) Deeplink to open new tab experience in app r=jchen
Added an extra check for package name for a better user experience, because the push notifications with "about" protocol
in the URL message were still firing the chooser dialog.

Differential Revision: https://phabricator.services.mozilla.com/D4578

--HG--
extra : moz-landing-system : lando
2018-08-30 18:15:15 +00:00
Vlad Baicu
3eda54b1e1 Bug 1479314 - Prevent media control notification flashing. r=jchen
Instead of stopping the foreground service whenever ACTION_PAUSE was triggered,
I created a new event where we notify the service to clear its foreground state.
Cleared usages of the NotificationManager and the onGoing attribute of the
MediaNotification because they are redundant. As of Android 4.3 a service in the
foreground state will always force the notification to be persistent and callling
stopForeground(false) will clear the onGoing flag while maintaining the notification.

Differential Revision: https://phabricator.services.mozilla.com/D4567

--HG--
extra : moz-landing-system : lando
2018-08-30 17:47:51 +00:00
Petru Lingurar
c224a4cef6 Bug 1480091 - Don't hide the status bar when exiting PIP mode; r=jchen
From the PIP window the user can either return to the fullscreen app or exit
it entirely.
Fullscreen and subsequently hiding the status bar should only be done if the
user is returning to the app.

Differential Revision: https://phabricator.services.mozilla.com/D4676

--HG--
extra : moz-landing-system : lando
2018-08-30 17:49:29 +00:00
Jan Henning
a0441dcfc3 Bug 1485151 - Part 2 - Switch our whitelisting of StrictMode violations to try-with-resources. r=jchen
In my opinion this is an altogether nicer way of setting and resetting temporary
StrictMode exceptions. The only fly in the ointment is that this causes a
warning about a technically unused variable that subsequently needs suppressing.

Differential Revision: https://phabricator.services.mozilla.com/D4889

--HG--
extra : source : ac7659d4135e270b6d787499680aefc39a01fb4f
extra : histedit_source : bdffd8eee3fcf1e705316de6e84da7c7aac9340a
2018-08-22 21:53:54 +02:00
Jan Henning
93115a878a Bug 1485439 - Upgrade to Java 8. r=nalexander,jchen
Doing so allow to use try-with-resources on all API levels supported by us, not
just starting from API19.

Unfortunately this step also introduces some additional ambiguities in overload
resolution, which means that one of GeckoResult's "then" overloads needs to be
renamed.

Differential Revision: https://phabricator.services.mozilla.com/D4887

--HG--
extra : rebase_source : 7173395484a9616ce739e9d2ba3aa0b8410be386
extra : source : 66955d05bb86c25b1fcb81d60b38be95018d09ca
2018-08-22 21:15:42 +02:00
Jan Henning
3e5cdb5011 Bug 1485151 - Part 1 - Import StrictModeContext from Chromium. r=jchen,mhoye
Differential Revision: https://phabricator.services.mozilla.com/D4888

--HG--
extra : source : 424fcd7c1bef5f9591d749555c042c184cfbf313
extra : histedit_source : 614bd7bac33d7312079337aed2184b1e47d04418
2018-08-22 20:16:34 +02:00
Jim Chen
9ffc2ddc01 Bug 1485155 - 2. Treat javadoc warnings as errors; r=nalexander
Some common javadoc mistakes are logged as warnings and are being
overlooked. javadoc does not support warning-as-error natively, so this
patch scans the javadoc output in gradle and makes the task fail if any
warnings are detected.

Differential Revision: https://phabricator.services.mozilla.com/D3925
2018-09-04 13:58:27 -04:00
Jim Chen
d50cb5e5d8 Bug 1485155 - 1. Fix javadoc warnings; r=jchen
Differential Revision: https://phabricator.services.mozilla.com/D3924
2018-09-04 13:58:27 -04:00
Kris Maglione
22d4bb0074 Bug 1484413: Split ReaderMode.jsm into separate checking and loading components. r=Gijs
Most of the ReaderMode.jsm and Readability.js code is only needed when we
actually need to render a document in reader mode, but also winds up loaded
into any process where we ever check if a page is readerable. This winds up
wasting a huge amount of memory (and probably a huge amount of CPU time)
loading code which is almost never used.

This patch splits ReaderMode.jsm into two modules, one for checking
readability, one for actually entering reader mode. It also separates out the
isProbablyReaderable checks from Readability.js, since the overhead of loading
that script before it's needed is unsupportable.

This means we're probably going to need some effort to keep Readerable.jsm and
Readability.js in sync, but the code in question is pretty trivial, so it
shouldn't be too difficult.

Differential Revision: https://phabricator.services.mozilla.com/D3687

--HG--
rename : toolkit/components/reader/Readability.js => toolkit/components/reader/Readability-readerable.js
rename : toolkit/components/reader/ReaderMode.jsm => toolkit/components/reader/Readerable.js
extra : rebase_source : 66712057591ae20dd66234e3dc78fbba90a6914e
extra : amend_source : f908f62f49ea54b9099ddb87d9f2fc11f12d4dee
2018-08-17 23:10:59 -07:00
Hiroyuki Ikezoe
b2160ed2cf Bug 1035774 - Support dynamic input device changes for Android. r=jchen
Though we can't write automation tests for this, I have confirmed that the input
device added/removed are properly notified to 'browser.xul'. Unfortunately the
notifications don't reach to conent documents because of bug 1478212, but I've
also confirmed they did reach to content documents with replacing
MediaFeatureValuesChanged with MediaFeatureValuesChangedAllDocuments in
nsPresContext::RefreshSystemMetrics().

Differential Revision: https://phabricator.services.mozilla.com/D3303
2018-08-14 16:38:03 +09:00
Hiroyuki Ikezoe
2b678040eb Bug 1035774 - Introduce functions to get the capabilities for the primary pointer and for all available pointers on Android. r=jchen
There is no API that we can tell which input device is the primary pointer
device on Android, so we assume that the first pointer-type input device
in the list of InputDevice.getDevice is the primary one.

Test results on L-01F (a variant of LG-G2):
 - Normal boot
   The touchscreen is the primary device
   - Plugged a mouse
      The touchscreen is the primary device

 - Boot with a plugged mouse
   The mouse is the primary device
   - Plugged off the mouse
      The touchscreen is now the primary device
   - Plugged the mouse again
      The touchscreen is the primary device

Classification in getPointerCapablities refered to chrome impelementation [1].
In addition to the classification, we add SOURCE_JOYSTICK as a 'COARSE' and
'HOVER_CAPABLE' device.

[1] d4c8983688/ui/android/java/src/org/chromium/ui/base/TouchDevice.java (72)

Differential Revision: https://phabricator.services.mozilla.com/D3302
2018-08-14 16:38:03 +09:00
Bogdan Tara
ba6cae21b7 Merge mozilla-central to inbound. a=merge CLOSED TREE 2018-09-05 02:45:18 +03:00
Mike Hommey
58cc756fed Bug 1480006 - Enable LTO on Android CI builds. r=froydnj 2018-09-05 07:21:25 +09:00
Gurzau Raul
f9a81a3e5a Merge mozilla-central to autoland. a=merge CLOSED TREE 2018-08-31 00:51:52 +03:00
Gurzau Raul
09fe34b331 Merge inbound to mozilla-central. a=merge 2018-08-31 00:49:36 +03:00
Jan Henning
73670afee3 Bug 1482105 - Use dedicated notification channel for the built-in updater. r=jchen
To avoid cluttering our notification settings on builds not using the built-in
updater, we only add that channel when required.
Passing a null channelId to the system NotificationManager, which can then
happen if someone attempts to use the UPDATER channel anyway, even though
MOZ_UPDATER is false, is safe. It just means that the NotificationManager will
return the system's default channel, which will silently swallow any
notifications posted to it from apps targeting Android O or above.

Differential Revision: https://phabricator.services.mozilla.com/D4584

--HG--
extra : moz-landing-system : lando
2018-08-30 18:59:52 +00:00
Dennis Schubert
65a27816a3 Bug 1486885 - Remove error logging inside getBaseDomainFromURI(). r=Gijs
Differential Revision: https://phabricator.services.mozilla.com/D4684

--HG--
extra : moz-landing-system : lando
2018-08-30 15:50:20 +00:00
arthur.iakab
a82f668e23 Merge mozilla-central to autoland 2018-08-30 01:12:47 +03:00
arthur.iakab
32fbca3814 Merge inbound to mozilla-central a=merge 2018-08-30 00:56:06 +03:00
Petru Lingurar
7f35fc24a2 Bug 1486200 - Apply Photon theme for Date/Time pickers only on API >=23; r=jchen
Fix Lollipop crashes because of android.content.res.ColorStateList.addFirstIfMissing()
The default app theme will be applied for the material Date/Time pickers on
API 21 and API 22. After this, on API >=23 they will be Photon themed.

Differential Revision: https://phabricator.services.mozilla.com/D4464

--HG--
extra : moz-landing-system : lando
2018-08-29 20:00:53 +00:00
Gabriele Svelto
6bddc0a55e Bug 1486772 - Refactor the screen-orientation types and headers r=smaug
This patch removes the 'ScreenOrientationInternal' type from
dom/base/ScreenOrientation.h and moves it into the
HalScreenConfiguration.h header, renaming it simply to 'ScreenOrientation'
in the process. This has several knock-off effects:

- It allows files that needed ScreenOrientationInternal to include a much
  smaller header than before

- It greatly reduces the number of headers pulled in when including Hal.h

- It clarifies the role of the type. The 'Internal' part in the name had
  nothing to do with it being part of the implementation. The type was public
  and called that way only to avoid clashing with the 'ScreenOrientation'
  class. Since we moved it into a different namespace it can be renamed
  safely.

- It allows a file that was manually re-declaring 'ScreenConfigurationInternal'
  type to use the original one

- Finally this fixes a few files which were missing headers they actually
  required but that would still build because unified compilation put them into
  units that already had those headers thanks to ScreenConfiguration.h

Differential Revision: https://phabricator.services.mozilla.com/D4458

--HG--
extra : moz-landing-system : lando
2018-08-29 20:54:56 +00:00
Cosmin Sabou
27822f2d77 Merge mozilla-central to autoland. a=merge 2018-08-29 21:04:28 +03:00
Cosmin Sabou
55bf096f3d Merge mozilla-inbound to mozilla-central. a=merge 2018-08-29 20:34:13 +03:00
Johan Lorenzo
04619e947c Bug 1484932 - Update GeckoView maven group id: org.mozilla.geckoview r=sebastian,jchen
Update GeckoView maven group id: org.mozilla.geckoview

Differential Revision: https://phabricator.services.mozilla.com/D4344

--HG--
extra : moz-landing-system : lando
2018-08-28 13:04:09 +00:00
Francesco Lodolo (:flod)
cb706ec643 Bug 1486211 - Remove unused key browser.search.defaultenginename from region.properties r=mkaply
Differential Revision: https://phabricator.services.mozilla.com/D4419

--HG--
extra : moz-landing-system : lando
2018-08-28 13:14:27 +00:00
alwu
bd196cc59f Bug 1485189 - part2 : add test. r=timdream
Differential Revision: https://phabricator.services.mozilla.com/D4268

--HG--
extra : moz-landing-system : lando
2018-08-29 16:49:06 +00:00
Jan Henning
a74fb3ad2b Bug 1479532 - Part 0 - Cleanups. r=jchen
Differential Revision: https://phabricator.services.mozilla.com/D4367

--HG--
extra : moz-landing-system : lando
2018-08-28 18:53:20 +00:00
Petru Lingurar
f90d90e3b2 Bug 1477059 - Remove terraclicks.com from topdomains; r=sdaswani
Differential Revision: https://phabricator.services.mozilla.com/D4523

--HG--
extra : moz-landing-system : lando
2018-08-29 16:29:50 +00:00
Gijs Kruitbosch
3a7be00e1a Bug 1487044 - sync reader mode to github tip ( 3be1aaa01c078c25b67ed8dfd1c9aa8f9963490b ), r=johannh,gijs
--HG--
extra : rebase_source : d0ff2ac4ae07d419214a045a4b6c6266e62f77e4
2018-08-29 12:51:09 +01:00
Arshad Kazmi
43fb2c87eb Bug 1396684 - Allow extensions to access tab's "attention" flag r=mixedpuppy,robwu
Differential Revision: https://phabricator.services.mozilla.com/D3984

--HG--
extra : moz-landing-system : lando
2018-08-28 14:41:31 +00:00
Imanol Fernandez
fab5f04e0f Bug 1483397 - Add media control API so apps can control when media is paused r=snorp,rbarker,jchen
Add a GeckoSession property too specify if media should be suspended when the session is inactive.

Differential Revision: https://phabricator.services.mozilla.com/D4472

--HG--
extra : moz-landing-system : lando
2018-08-28 21:55:03 +00:00
Ciure Andrei
c7bd3f7ba5 Merge mozilla-central to autoland. a=merge CLOSED TREE 2018-08-29 01:06:58 +03:00
Ciure Andrei
d716a04e20 Merge inbound to mozilla-central. a=merge 2018-08-29 00:58:21 +03:00
Raynald Mirville
27f61415a8 Bug 1476552 - GeckoSession::WebResponseInfo Kotlin annotations and static r=sebastian
MozReview-Commit-ID: 1HWEStKaGVl

Bug 1476552 part 1 - Add @NonNull/@Nullable annotations to GeckoSession::WebResponseInfo for Kotlin interoperability

Bug 1476552 part 2 - Make GeckoSession::WebResponseInfo static

MozReview-Commit-ID: 4ce92G7i2nz

Differential Revision: https://phabricator.services.mozilla.com/D2885

--HG--
extra : moz-landing-system : lando
2018-08-28 13:02:23 +00:00
Cosmin Sabou
1f05c39e5d Merge mozilla-central to autoland. a=merge 2018-08-27 18:59:16 +03:00
Imanol Fernandez
ccf5df3d8e Bug 1474847 - Fix GeckoSurfaceTexture not correctly removed from container when released: r=snorp,rbarker
When entering and exiting immersive mode multiple time (~30) the WebGL context can be lost. This is caused because GeckoSurfaceTexture things there are more than 200 textures created.

Differential Revision: https://phabricator.services.mozilla.com/D4236

--HG--
extra : moz-landing-system : lando
2018-08-27 15:15:21 +00:00
Dale Harvey
124dd7e583 Bug 1478549 - Follow up to add prefs helper. r=janh
MozReview-Commit-ID: LX44L2reVia
2018-08-27 09:20:01 +01:00
Andrei Lazar
a8f24789f7 Bug 1430122 Custom tab close button is too large compared to the other buttons. r=VladBaicu
Resized the close button manually.

Differential Revision: https://phabricator.services.mozilla.com/D4342

--HG--
extra : moz-landing-system : lando
2018-08-27 15:24:57 +00:00
Arshad Kazmi
01d3f08437 Bug 1462678 - Removed unused code from Gecko r=jchen
Differential Revision: https://phabricator.services.mozilla.com/D4295

--HG--
extra : moz-landing-system : lando
2018-08-27 16:44:47 +00:00
Andreea Pavel
3176bf1dc4 Merge mozilla-central to mozilla-inbound. a=merge on a CLOSED TREE 2018-08-27 00:51:46 +03:00
Robert Bartlensky
9712f4f4c6 Bug 1477707: Fix all infer errors in GeckoView. r=jchen
This fixes some errors reported by infer on GeckoView that are not related to threading.

Differential Revision: https://phabricator.services.mozilla.com/D3787

--HG--
extra : moz-landing-system : lando
2018-08-24 15:32:18 +00:00
arthur.iakab
7df3c5baab Merge inbound to mozilla-central a=merge 2018-08-25 06:35:21 +03:00
Kris Maglione
8ad0bfd9c0 Bug 1484496: Follow-up: Fix more busted JS enumerators. r=bustage CLOSED TREE
--HG--
extra : amend_source : b6753494cab68add325af09442239e72ea0c4501
2018-08-24 17:10:29 -07:00
alwu
b07c177c38 Bug 1479270 - part2 : remove HLS video player. r=snorp
Since we have native HLS support in 59 [1], we can remove those codes which is used to play HLS.

[1] https://bugzilla.mozilla.org/show_bug.cgi?id=1345752

Differential Revision: https://phabricator.services.mozilla.com/D4166

--HG--
extra : moz-landing-system : lando
2018-08-24 22:36:18 +00:00
arthur.iakab
83d1441dfa Merge mozilla-central to autoland 2018-08-25 01:09:11 +03:00
arthur.iakab
5527acb8d8 Merge inbound to mozilla-central a=merge 2018-08-25 01:08:22 +03:00
James Willcox
c9437b2c8e Bug 1485980 - Downgrade test runner packages to match support library r=jchen
Differential Revision: https://phabricator.services.mozilla.com/D4221

--HG--
extra : moz-landing-system : lando
2018-08-24 15:30:30 +00:00
Andreea Pavel
e7678f51b5 Backed out 2 changesets (bug 1479270) for android lint on a CLOSED TREE
Backed out changeset 1676f895a710 (bug 1479270)
Backed out changeset 643ef11ea720 (bug 1479270)
2018-08-24 20:16:14 +03:00
alwu
a9a7cfd9fa Bug 1479270 - part2 : remove HLS video player. r=snorp
Since we have native HLS support in 59 [1], we can remove those codes which is used to play HLS.

[1] https://bugzilla.mozilla.org/show_bug.cgi?id=1345752

Differential Revision: https://phabricator.services.mozilla.com/D4166

--HG--
extra : moz-landing-system : lando
2018-08-24 14:52:00 +00:00
Noemi Erli
d9cb8a1d4a Backed out changeset b24238e8e714 (bug 1481199) for failures in mobile/android/tests/browser/chrome/test_device_search_engine.html 2018-08-24 20:34:36 +03:00
Diego Pino Garcia
1f9d6d9b78 Bug 1481199 - Drop the obsolete dataType parameter for nsIBrowserSearchService.addEngine. r=mkaply 2018-08-23 17:25:12 -05:00
Jim Chen
0b2817dd4e Bug 1485384 - Fix typo in open_allowCallsWhileClosed; r=me 2018-08-24 10:19:15 -04:00
Vlad Baicu
44843cf2d7 Bug 1474633 - Check if pager navigation is null before calling it. r=jchen
Check if pager navigation is null before calling it.

Differential Revision: https://phabricator.services.mozilla.com/D4092

--HG--
extra : moz-landing-system : lando
2018-08-23 20:56:01 +00:00
Cosmin Sabou
c6790f084b Merge mozilla-central to mozilla-inbound. a=merge
--HG--
extra : rebase_source : 742ef5d5df898ae0ed4c7c400d230bf6fa94645c
2018-08-29 21:05:53 +03:00
Kris Maglione
87d079325d Bug 1484496: Follow-up: Fix busted JS enumerator in Android directory service. r=bustage 2018-08-23 18:13:58 -07:00
Kris Maglione
4d7a8aa50d Bug 1484496: Part 5c - Convert mobile/ nsISimpleEnumerator users to use JS iteration. r=snorp
Differential Revision: https://phabricator.services.mozilla.com/D3731

--HG--
extra : rebase_source : 6ba05bd9240694fa7c37481b138c67671da39a9e
extra : histedit_source : 51439d03c5cb87f041a995d7ba6978f01035eb99
2018-08-18 19:28:06 -07:00
Andrei Lazar
a7c829ed6c Bug 1482836 Remove deprecated Snippets code r=jchen
Removed unused Snippets code since now we're using Leanplum.

Differential Revision: https://phabricator.services.mozilla.com/D3521

--HG--
extra : moz-landing-system : lando
2018-08-16 19:59:15 +00:00
Cosmin Sabou
b69e48dda2 Merge mozilla-central to mozilla-inbound. a=merge 2018-08-24 00:46:31 +03:00
Jim Chen
28a1a1d5dd Bug 1330257 - 8. Add tests for Oreo auto-fill frontend; r=snorp
Add some tests for the Oreo auto-fill frontend, similar to the tests for
the a11y auto-fill frontend. However, because these tests depend on the
ViewStructure class, they require SDK 23+ to run.

Differential Revision: https://phabricator.services.mozilla.com/D3810
2018-08-23 17:03:35 -04:00
Dorel Luca
8e7a61886b Backed out changeset d47a2f5db828 (bug 1481199) browser/base/content/test/urlbar/browser_autocomplete_a11y_label.js. CLOSED TREE 2018-08-23 23:45:02 +03:00
Diego Pino Garcia
6900fb42ab Bug 1481199 - Drop the obsolete dataType parameter for nsIBrowserSearchService.addEngine. r=mkaply 2018-08-23 09:00:00 -04:00
Dylan Roeh
542742751e Bug 1481296 - Add a popup blocking API to PromptDelegate. r=jchen,snorp 2018-09-07 13:39:57 -05:00
Paul Rouget
430679ad1e Bug 1492771 - Make GeckoSession non-final r=snorp 2018-09-26 08:08:27 -05:00
Tiberius Oros
70e8d3a299 Backed out 11 changesets (bug 1493563) for failures on dom/workers/test/test_sharedworker_event_listener_leaks.html on a CLOSED TREE
Backed out changeset 0bb55b604bfd (bug 1493563)
Backed out changeset 8e25c301675a (bug 1493563)
Backed out changeset 4f608b8801d4 (bug 1493563)
Backed out changeset f58d0b1ca088 (bug 1493563)
Backed out changeset eae105f2bf6d (bug 1493563)
Backed out changeset 7a8a0d1cfd69 (bug 1493563)
Backed out changeset dbba8451aab1 (bug 1493563)
Backed out changeset a6141dbd0328 (bug 1493563)
Backed out changeset f4ca3d8fa90e (bug 1493563)
Backed out changeset 56bab7fae64d (bug 1493563)
Backed out changeset 66787e603401 (bug 1493563)
2018-09-26 06:16:22 +03:00
Ehsan Akhgari
4ced8fedcb Bug 1493563 - Part 5: Present the old state and the content blocking log to the web progress listeners; r=baku
Differential Revision: https://phabricator.services.mozilla.com/D6595
2018-09-25 21:02:51 -04:00
Tiberius Oros
8acb878ef1 Backed out 11 changesets (bug 1493563) for failures on browser_blockingCookies.js on a CLOSED TREE
Backed out changeset d755b96837ac (bug 1493563)
Backed out changeset 651f87dca51f (bug 1493563)
Backed out changeset 68de8f0866d0 (bug 1493563)
Backed out changeset 205d69890f50 (bug 1493563)
Backed out changeset 5f922cd6c21e (bug 1493563)
Backed out changeset 84dc54c1a9c1 (bug 1493563)
Backed out changeset 287666ecdd17 (bug 1493563)
Backed out changeset c64a2ea15b7b (bug 1493563)
Backed out changeset 9085269938cd (bug 1493563)
Backed out changeset de06604fefcb (bug 1493563)
Backed out changeset f9bac5e73bd4 (bug 1493563)
2018-09-25 23:12:03 +03:00
Mike Hommey
8e122c456c Backout changeset 681777ca2f49 (bug 1480006) and 0fc57261a269 (bug 1483190) to see if that fixes bug 1485759 on a CLOSED TREE. a=ebalazs
Another reason to backout is that there may be other subtle breakage
like bug 1478623 and bug 1478269 and we don't have a lot of test
coverage on Android.
2018-08-28 21:08:30 +09:00
Geoff Brown
b534143507 Bug 1484220 - Enable marionette in all fennec builds; r=snorp 2018-08-27 07:19:02 -06:00
Johann Hofmann
7fd1427a9d Bug 1484246 - Part 2 - Add more explanation to certificate errors caused by Symantec distrust to Fennec. r=snorp
Differential Revision: https://phabricator.services.mozilla.com/D4297

--HG--
extra : rebase_source : e3949c9520bec01270751898cee7bc21e6c015de
2018-08-26 14:32:01 +02:00
James Willcox
e641866f27 Bug 1480920 - Bump versions for Android test runner packages r=jchen
This also removes the trivial tests for geckoview_example that were
causing problems.

Differential Revision: https://phabricator.services.mozilla.com/D3991

--HG--
extra : moz-landing-system : lando
2018-08-23 13:12:20 +00:00
Brindusan Cristian
d21b936680 Merge inbound to mozilla-central. a=merge 2018-08-23 01:00:10 +03:00
Jan Henning
36ca86c711 Bug 1484472 - Avoid FileUriExposedException in ExternalIntentDuringPrivateBrowsingPromptFragment. r=jchen
The fragment is also used to handle intents launched through GeckoAppShell.
openUriExternal(), such as e.g. when launching downloaded files from
about:downloads.

The synchronous code path when not in private browsing is already covered by the
code added in bug 1450449, but the async path through the fragment when in
private browsing needs to be handled separately.

Differential Revision: https://phabricator.services.mozilla.com/D3916

--HG--
extra : moz-landing-system : lando
2018-08-22 16:50:04 +00:00
James Willcox
cd232d5aac Bug 1480095 - Add example custom error page to GeckoView Example r=esawin
MozReview-Commit-ID: HeYOkwNHYXq
2018-08-22 08:48:26 -05:00
James Willcox
e07c741622 Bug 1480095 - Allow NavigationDelegate.onLoadError() to return URL for error page r=esawin,jchen
MozReview-Commit-ID: 4pgHD6oh4GY
2018-08-22 08:48:20 -05:00
Cosmin Sabou
ed624fa8d0 Backed out 6 changesets (bug 1484876) for eslint failure on PrivateBrowsingUtils. CLOSED TREE
Backed out changeset e80737d6af55 (bug 1484876)
Backed out changeset b1cb63d8c8bb (bug 1484876)
Backed out changeset cd2ced689895 (bug 1484876)
Backed out changeset d31e39a47704 (bug 1484876)
Backed out changeset babf6abc7f4c (bug 1484876)
Backed out changeset 1c9895ab06c6 (bug 1484876)
2018-08-22 16:26:33 +03:00
Ehsan Akhgari
e5937f080b Bug 1484876 - Part 5: Merge the PrivateBrowsingTrackingProtectionWhitelist service with PrivateBrowsingUtils.jsm; r=johannh 2018-08-22 09:08:10 -04:00
Tiberius Oros
05b46cf200 Merge mozilla-central to autoland. a=merge CLOSED TREE 2018-08-22 00:59:19 +03:00
Tudor-Gabriel Vîjială
7dcb482bb3 Bug 1481834 - Fix running robocop tests on debug builds. r=gbrown
Fix running robocop tests on debug builds.

This patch fixes multidex issues when running robocop on debug builds.

Differential Revision: https://phabricator.services.mozilla.com/D3422

--HG--
extra : moz-landing-system : lando
2018-08-21 20:02:13 +00:00
Randall Barker
869419ee56 Bug 1484960 - Remove IllegalStateException throw on multiple calls to overrides in GeckoAppShell r=jchen
Differential Revision: https://phabricator.services.mozilla.com/D3911

--HG--
extra : moz-landing-system : lando
2018-08-21 19:17:30 +00:00
Dennis Schubert
1ff837285f Bug 1484796 - Add console logging statements to site patches. r=kmag,rhelmer
Differential Revision: https://phabricator.services.mozilla.com/D3818

--HG--
extra : moz-landing-system : lando
2018-08-21 16:10:23 +00:00
Franziskus Kiefer
3d5b81aef3 Bug 1484534 - fix Android error page technical details r=johannh
Differential Revision: https://phabricator.services.mozilla.com/D3858

--HG--
extra : moz-landing-system : lando
2018-08-21 12:04:57 +00:00
Jim Chen
10077d9ffe Bug 1330257 - 7. Add Oreo auto-fill frontend; r=esawin r=snorp
Add a frontend for the Oreo auto-fill API in SessionTextInput, which
processes events from Gecko and provides consumer APIs that match the
Oreo auto-fill APIs. GeckoView then forwards the necessary calls to
SessionTextInput.

Differential Revision: https://phabricator.services.mozilla.com/D3538
2018-08-21 15:23:29 -04:00
Jim Chen
e91970bb1d Bug 1330257 - 6. Add tests for auto-fill accessibility frontend; r=eeejay
Add some tests to AccessibilityTest to make sure we can perform
auto-fill through the accessibility API.

Differential Revision: https://phabricator.services.mozilla.com/D3255
2018-08-21 15:23:29 -04:00
Jim Chen
0840beff3f Bug 1330257 - 5. Add auto-fill accessibility frontend; r=eeejay
Add an auto-fill frontend that listens to events from Gecko. It
populates accessibility nodes for input fields and sends accessibility
events, in order to support auto-fill clients that use accessibility
services to perform auto-fill.

Differential Revision: https://phabricator.services.mozilla.com/D3254
2018-08-21 15:23:28 -04:00
Jim Chen
c142db1d58 Bug 1330257 - 4. Add auto-fill backend; r=esawin
Add an auto-fill backend in GeckoViewContent.js that detects fields on
the page and sends information about the fields to Java through events.

Differential Revision: https://phabricator.services.mozilla.com/D3253
2018-08-21 15:23:28 -04:00
Jim Chen
35fca43b60 Bug 1330257 - 3. Inline session store event listeners; r=droeh
Make the session store event listeners inline, because it makes the code
more readable, and also because auto-fill requires a pageshow listener
that is always registered, so the existing pageshow listener needs to be
moved elsewhere.

Differential Revision: https://phabricator.services.mozilla.com/D3252
2018-08-21 15:23:28 -04:00
Jim Chen
042d95a78e Bug 1330257 - 2. Separate out session focused state from active state; r=droeh
Make a distinction between a session being active (i.e. being visible)
and it being focused. More than one session may be active at a time, but
only one session is focused at a time. This means the focused session is
always active, but an active session may not be focused.

Also, manage setting of active/focused states in GeckoView itself, so
consumers don't generally have to worry about these states.

Differential Revision: https://phabricator.services.mozilla.com/D3251
2018-08-21 15:23:28 -04:00
Jim Chen
99ba526941 Bug 1330257 - 1. Refactor SessionAccessibility; r=eeejay
Move the AccessibilityNodeProvider implementation under
SessionAccessibility, to reduce the indent of the code.

Also make all methods in SessionAccessibility.Settings static to make
the code easier to follow.

Differential Revision: https://phabricator.services.mozilla.com/D3250
2018-08-21 15:23:27 -04:00
Gurzau Raul
fce80a532e Backed out 8 changesets (bug 1330257) for Geckoview failures at GeckoSessionTestRuleTest.waitForPageStop_throwOnChangedCallback on a CLOSED TREE
Backed out changeset c26970c767e1 (bug 1330257)
Backed out changeset 53ef69afca69 (bug 1330257)
Backed out changeset 62e53fa35d5b (bug 1330257)
Backed out changeset 7c589fc8621b (bug 1330257)
Backed out changeset 593f9a799d11 (bug 1330257)
Backed out changeset 9085b9fd557c (bug 1330257)
Backed out changeset aa0ef9b0e96a (bug 1330257)
Backed out changeset 7186e64192f7 (bug 1330257)
2018-08-21 06:51:29 +03:00
Jim Chen
2a5876a5b2 Bug 1330257 - 5a. Fix checkstyle error; r=jchen 2018-08-20 23:02:09 -04:00
Jim Chen
0f3c92c7f0 Bug 1330257 - 7. Add Oreo auto-fill frontend; r=esawin r=snorp
Add a frontend for the Oreo auto-fill API in SessionTextInput, which
processes events from Gecko and provides consumer APIs that match the
Oreo auto-fill APIs. GeckoView then forwards the necessary calls to
SessionTextInput.

Differential Revision: https://phabricator.services.mozilla.com/D3538
2018-08-20 22:28:21 -04:00
Jim Chen
da23d1931b Bug 1330257 - 6. Add tests for auto-fill accessibility frontend; r=eeejay
Add some tests to AccessibilityTest to make sure we can perform
auto-fill through the accessibility API.

Differential Revision: https://phabricator.services.mozilla.com/D3255
2018-08-20 22:28:21 -04:00
Jim Chen
7ead74b685 Bug 1330257 - 5. Add auto-fill accessibility frontend; r=eeejay
Add an auto-fill frontend that listens to events from Gecko. It
populates accessibility nodes for input fields and sends accessibility
events, in order to support auto-fill clients that use accessibility
services to perform auto-fill.

Differential Revision: https://phabricator.services.mozilla.com/D3254
2018-08-20 22:28:20 -04:00
Jim Chen
3d6c8ca540 Bug 1330257 - 4. Add auto-fill backend; r=esawin
Add an auto-fill backend in GeckoViewContent.js that detects fields on
the page and sends information about the fields to Java through events.

Differential Revision: https://phabricator.services.mozilla.com/D3253
2018-08-20 22:28:20 -04:00
Jim Chen
8a8e82e9bd Bug 1330257 - 3. Inline session store event listeners; r=droeh
Make the session store event listeners inline, because it makes the code
more readable, and also because auto-fill requires a pageshow listener
that is always registered, so the existing pageshow listener needs to be
moved elsewhere.

Differential Revision: https://phabricator.services.mozilla.com/D3252
2018-08-20 22:28:20 -04:00
Jim Chen
fa4ec16cc2 Bug 1330257 - 2. Separate out session focused state from active state; r=droeh
Make a distinction between a session being active (i.e. being visible)
and it being focused. More than one session may be active at a time, but
only one session is focused at a time. This means the focused session is
always active, but an active session may not be focused.

Also, manage setting of active/focused states in GeckoView itself, so
consumers don't generally have to worry about these states.

Differential Revision: https://phabricator.services.mozilla.com/D3251
2018-08-20 22:28:20 -04:00
Jim Chen
6b8899beef Bug 1330257 - 1. Refactor SessionAccessibility; r=eeejay
Move the AccessibilityNodeProvider implementation under
SessionAccessibility, to reduce the indent of the code.

Also make all methods in SessionAccessibility.Settings static to make
the code easier to follow.

Differential Revision: https://phabricator.services.mozilla.com/D3250
2018-08-20 22:28:19 -04:00
Kris Maglione
356dd0de4a Bug 1484466: Part 3a - Update remaining XPCOMUtils.generateQI callers to use ChromeUtils. r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D3709

--HG--
extra : rebase_source : 650545d3e58ab92821a9ea2097793cca5996d5b3
2018-08-18 12:44:57 -07:00
Csoregi Natalia
6a5d41b053 Merge inbound to mozilla-central. a=merge
--HG--
rename : devtools/server/actors/webconsole/moz.build => devtools/server/actors/webconsole/listeners/moz.build
2018-08-21 01:00:01 +03:00
Randall Barker
91e6e6d242 Bug 1484463 - Remove GeckoAppShell.setScreenDepthOverride(). r=jchen
Differential Revision: https://phabricator.services.mozilla.com/D3813

--HG--
extra : moz-landing-system : lando
2018-08-20 19:11:09 +00:00
Jean-Yves Avenard
2cdf517489 Bug 1484648 - Implement CodecProxy::IsHardwareAccelerated. r=jolin
Differential Revision: https://phabricator.services.mozilla.com/D3789

--HG--
extra : moz-landing-system : lando
2018-08-20 15:42:33 +00:00
vinoth
25d8536817 Bug 1480934 - Saving Reader View page yields blank page fixed by removing inline style r=jaws,ckerschb
Differential Revision: https://phabricator.services.mozilla.com/D2947

--HG--
extra : rebase_source : ffd74af5b0d9360d50245dd2c9ac3371dbafa096
extra : source : b7531c106b5947faf3edd8a951003d406c6a54dd
2018-08-14 03:26:24 +00:00
Randall Barker
4fcb607ef3 Bug 1484374 - Update GeckoView to handle the autoplay-media permission request. r=snorp
Differential Revision: https://phabricator.services.mozilla.com/D3680

--HG--
extra : moz-landing-system : lando
2018-08-18 17:19:32 +00:00
Csoregi Natalia
3e61ab4489 Merge inbound to mozilla-central. a=merge 2018-08-18 12:46:20 +03:00
Daniel Varga
3ee92b7a2f Merge mozilla-central to autoland 2018-08-18 01:04:09 +03:00
Daniel Varga
707a0b3f74 Merge mozilla-inbound to mozilla-central. a=merge 2018-08-18 00:53:04 +03:00
Randall Barker
832c1cbf6b Bug 1483596 - Add GeckoView API to set VR UA string r=esawin,jchen
Differential Revision: https://phabricator.services.mozilla.com/D3545

--HG--
extra : moz-landing-system : lando
2018-08-17 20:34:04 +00:00
Randall Barker
a1c5b33558 Bug 1483420 - Add GeckoView APIs for overriding screen size and display DPI r=esawin,jchen
Differential Revision: https://phabricator.services.mozilla.com/D3379

--HG--
extra : moz-landing-system : lando
2018-08-17 20:17:44 +00:00
Edouard Oger
e3e242dce3 Bug 1484090 - Flag the device for re-registration on push subscription not found r=lina
Differential Revision: https://phabricator.services.mozilla.com/D3567

--HG--
extra : moz-landing-system : lando
2018-08-17 15:09:48 +00:00
John Lin
a47eb60caa Bug 1481139 - fix GMP process IPC channel error on Android. r=jld,njn
Bug 1481139 - p1: handle invalid file descriptors.
Bug 1481139 - p2: add dummy fds for GMP process.

Two file descriptors were added in bug 1438678 and 1471025 for content/child
process but not GMP process, and it breaks the IPC channel on Android.

Add dummy values to make it work for now before bug 1440207 clean up the mess.

Differential Revision: https://phabricator.services.mozilla.com/D3541

--HG--
extra : moz-landing-system : lando
2018-08-17 00:06:20 +00:00
Margareta Eliza Balazs
6c198262de Merge inbound to mozilla-central. a=merge 2018-08-17 12:46:14 +03:00
Michael Comella
efc0d9d92c Bug 1373964 - On profile migrate, delete <dir>/res/fonts. r=vladbaicu
The previous implementation attempted to delete files from /res/fonts (i.e.
root). I don't believe this was intended either:
https://bugzilla.mozilla.org/show_bug.cgi?id=878674#c0 indicates the fonts
directory should be inside the data dir of the application. The crash occurs
when the /res/fonts directory exists (only some devices) but the user doesn't
have read access. If the user has write access, our code may actually delete
these system files: uh oh!

My fix is to change the deletion from /res/fonts to <dir>/res/fonts. I verified
this fix worked by creating a clean profile, adding dummy files to the
res/fonts dir, and making sure only the correct ones were deleted (in zsh):

export DIR=/data/data/org.mozilla.fennec_mcomella; \
    adb shell pm clear org.mozilla.fennec_mcomella && \
    adb shell mkdir -p $DIR/res/fonts && \
    for i in touch.ttf lol.rdf; do adb shell touch $DIR/res/fonts/$i; done && \
    adb shell ls $DIR/res/fonts

MozReview-Commit-ID: 8atpcjYjGu0
2018-08-14 18:43:42 -07:00
Jan Henning
c1f1141676 Bug 1483893 - Avoid crashing if we somehow don't have a GeckoRuntime. r=snorp
MozReview-Commit-ID: AGJMrZP0fWu
2018-08-16 16:49:48 -05:00
Tiberius Oros
246f2b4fab Merge inbound to mozilla-central. a=merge 2018-08-17 00:32:50 +03:00
Eugen Sawin
19c0050828 Bug 1483342 - [2.1] Initialize SafeBrowsing module by default to enable safe browsing. r=jchen 2018-08-16 17:56:34 +02:00
Eugen Sawin
b45aa313f1 Bug 1483342 - [1.1] Add GeckoRuntime Safe Browsing API. r=snorp,jchen,francois 2018-08-16 17:56:34 +02:00
Dennis Schubert
d3163f6d9a Bug 1338586 - Ship the WebCompat GoFaster extension to Fennec. r=rhelmer
Differential Revision: https://phabricator.services.mozilla.com/D3012

--HG--
extra : moz-landing-system : lando
2018-08-16 14:26:40 +00:00
Tiberius Oros
127e89f5dd Merge mozilla-central to autoland. a=merge CLOSED TREE 2018-08-17 00:37:19 +03:00
Matt Brubeck
04cbf7f887 Bug 1483600 - Notify "tab-content-frameloader-created" in GeckoView content script. r=jchen
Differential Revision: https://phabricator.services.mozilla.com/D3546

--HG--
extra : moz-landing-system : lando
2018-08-16 20:50:36 +00:00
dvarga
87db76ae1a Merge mozilla-central to mozilla-inbound on a CLOSED TREE
--HG--
extra : rebase_source : c9e6b9edae9ecf064d1318fa15d5d57ea42c102a
2018-08-16 01:22:36 +03:00
Jan Henning
e93ad5ad8e Bug 1476106 - Part 5 - Subscribe PromptService to OrientationChangeListener, too. r=snorp
Now that GeckoScreenOrientation generally offers notifications of screen
orientation changes, the PromptService no longer needs to do its own orientation
tracking and require to be fed orientation changes from each activity using it.

MozReview-Commit-ID: K7KbDsQip7b

--HG--
extra : rebase_source : 8b447d9db079794c9ad231a31a52f2787ab742ce
2018-08-02 21:17:07 +02:00
Jan Henning
619de3dc05 Bug 1476106 - Part 4 - Refresh ScreenManager data when detecting orientation changes. r=snorp
As of bug 1475875, cached screen data is now held by Gecko, so
- we no longer need to cache the screen size (retrieval of which can be
  expensive when called en masse, as required e.g. by font inflation) within
  GeckoAppShell, and
- we need to trigger a refresh of that data instead when the activity
  orientation changes.

MozReview-Commit-ID: JsY6sBCcOih

--HG--
extra : rebase_source : f286f3b01732bd724da3988c4713adb7329a5fae
2018-08-02 22:03:59 +02:00
Jan Henning
332e51ec37 Bug 1476106 - Part 3 - Move GeckoScreenOrientation updates into GeckoView. r=snorp
By moving the calls to GeckoScreenOrientation.update() into GeckoView, any app
using a GeckoView will automatically update the screen orientation in Gecko,
too, without any further action being required by the embedding app.

The synchronisation around GeckoScreenOrientation.update()/(un)lock() is
required for the following scenario:
If (un)locking of the screen orientation as requested by Gecko caused the
actual screen orientation of the app to change, there are two ways in which this
will cause our internal screen orientation to be updated:
1. Either the call to delegate.setRequestedOrientationForCurrentActivity
   (happening on the Gecko thread if the original request to (un)lock came from
   Gecko) returns first and update() is subsequently first called from the Gecko
   thread, too, meaning the onOrientationChange notification to Gecko can occur
   synchronously as well. In that case, as soon as (un)lock returns to Gecko,
   querying our internal screen orientation will return the correct value.
2. Or else the GeckoView.onConfigurationChanged() call resulting from the screen
   rotation manages to call GeckoScreenOrientation.update() first and does so
   from the Android UI thread. This means that the onOrientationChange
   notification will be redispatched asynchronously to the Gecko thread, while
   the Gecko thread's call to GeckoScreenOrientation.update() will return early
   without doing any work, as the screen orientation had already been previously
   updated by the UI thread.
   As a result,there will be a period of time between the Gecko thread returning
   from GeckoScreenOrientation.(un)lock() and the onOrientationChange
   notification finally executing where querying the internal screen
   orientation will not yet return the new orientation. This can cause problems
   for Gecko (test) code that expects to (un)lock the orientation and then be
   able to immediately query the new, changed orientation after the call to
   (un)lock returns.

Without additional measures in place, there are no guarantees at what point
the GeckoView will receive the onConfigurationChanged() call in relation to the
request to change the activity's orientation making its way back to (un)lock().
Therefore, we add synchronisation such that no other thread will be able to up-
date the screen orientation in GeckoScreenOrientation while another thread is
still busy (un)locking the screen orientation.

MozReview-Commit-ID: 5s5NEJcuS0p

--HG--
extra : rebase_source : cbfbc6da99aa23af4eee8c4bf6018359f9e71304
2018-08-12 13:31:59 +02:00
Jan Henning
85eac0f5c4 Bug 1476106 - Part 2 - Fix setting of mRuntime when restoring GeckoView from savedInstanceState. r=snorp
The call to mSession.transferFrom(ss.session) in the line above also transfers
the window from ss.session into mSession, which means we subsequently won't be
able to retrieve a runtime from ss.session any more, thereby defeating the goal
of calling mRuntime = ss.session.getRuntime().

This case is encountered e.g. when the containing activity is destroyed and sub-
sequently recreated after a configuration change that isn't handled by the app,
e.g. screen rotation in the GeckoView example app.

MozReview-Commit-ID: 5YGskdLZWqw

--HG--
extra : rebase_source : 3293fcaaf645706133531cb0180b6514a289b612
2018-08-04 15:21:40 +02:00
Jan Henning
50803fba6b Bug 1476106 - Part 1 - Make it possible to notify Java listeners from GeckoScreenOrientation, too. r=snorp
Once responsibility for notifying GeckoScreenOrientation of potentially changed
screen orientations moves from GeckoApp into GeckoView, the former will no
longer be able to benefit from the return value of calling GeckoScreen-
Orientation.update(), indicating whether the orientation actually changed or in
fact remained the same.

GeckoApp however requires that information in order to reset/refresh parts of
the UI when the orientation changes, and since GeckoScreenOrientation is already
doing all the work of tracking screen orientation changes, we don't want to have
to partially duplicate those efforts again in GeckoApp.

Instead, we introduce a mechanism for GeckoScreenOrientation to notify
interested parties on the Android app side as well.

The GeckoScreenOrientation.update() call in GeckoApp.onResume() is removed
completely (as opposed to merely removing the refreshChrome() bit) at this stage
already because it is unnecessary. If any screen rotation happened while the
activity was in background, it will receive an onConfigurationChanged() call
anyway before being resumed again.

MozReview-Commit-ID: Ila1evcj8Ud

--HG--
extra : rebase_source : f342800628f930d717fe346779894793a1bac0e9
2018-08-02 21:10:33 +02:00
Jan Henning
6cb9ac4f6b Bug 1476106 - Part 0 - Cleanup imports. r=JanH
MozReview-Commit-ID: UHUdrWSIks

--HG--
extra : rebase_source : e0e64d55db9898d3c19ed4342e200d51326b3a30
2018-08-02 20:51:17 +02:00
Geoff Brown
2b831a4422 Bug 1483563 - Remove 'mach autophone'; r=bc
Autophone has been retired.
2018-08-15 12:54:08 -06:00
Narcis Beleuzu
23387914d5 Merge inbound to mozilla-central. a=merge 2018-08-15 12:48:57 +03:00