Currently, we expect editing operations in
GeckoEditableSupport::OnImeReplaceText to cause synchronous text change
notifications. However, under e10s, text change notifications can be
asynchornous. The new code keeps track of active OnImeReplaceText calls,
and look for async text changes before replying to the calls.
MozReview-Commit-ID: INM3JLmQebK
--HG--
extra : rebase_source : ff5b728ef437fcd78e4e7eced9c9a537d4698dce
Moved the logic ouf of MediaControlService to a new singleton GeckoMediaControlAgent,
which delegates all media-related actions.Currently, MediaControlService is used
for the foreground notification and to retrieve actions from the notification
pending intents. Removed redundant test cases.
MozReview-Commit-ID: KukAmpnn33S
--HG--
rename : mobile/android/app/src/test/java/org/mozilla/gecko/media/TestMediaControlService.java => mobile/android/app/src/test/java/org/mozilla/gecko/media/TestGeckoMediaControlAgent.java
extra : amend_source : 251b7821f4ddefcf852480de72ca1004cbd261bf
This patch also:
Resolves missing resources and api changes
- LeanplumActionBarActivity was removed because Support Library 26 deprecated
ActionBarActivity. Class was already not in use.
- CustomTabsService added two new methods which we need to override.
Tested to make sure that previous functionality was maintained but with the
addition of the two new methods maybe that feature could be improved.
- For checking layout direction we'll use our own new method from ViewUtil
which mimics what the now restricted method from the support library would do.
- Upgraded to use AppCompatResources#getDrawable(..) in place
of the now restricted AppCompatDrawableManager.get().getDrawable(..).
Resolves obscure leaks and crashes after the upgrade
- LoaderManager.destroyLoader(..) was added before the existing call to
LoaderManager.restartLoader(..) to prevent potential Cursor leaks
- Disable website suggestions depending on the address bar inputs when running
in automation to avoid Robocop tests failing (they were entering serially maybe
100 characters in <5 ms which created around that many new Threads,
operation that could cause the Executor to throw a RejectedExecutionException)
At the moment this functionality is not covered by tests anyway and it was the
only fix I could find that would not involve changing the whole implemenation
for address bar suggestions, implementation which in the real world works ok.
MozReview-Commit-ID: 2fX1SBHiSh0
--HG--
extra : amend_source : edb6c5853cdcea5ad50a7cf680f2214fdc176cb2
Created LeanPlumVariables to allow LeanPlum overwriting the values used for
populating the OnBoarding screens. By simply adding the @Variable annotation
to it's fields, on the first run of the app, they will appear in "LeanPlum
dashboard - Variables" and will allow overwriting for future runs.
The OnBoarding process will now try to use LeanPlum values if possible.
Because connecting to LeanPlum and downloading the Variables might take
a few seconds we use a delay of up to 3 seconds until starting to show
the Onboarding screens.
The default values will still be used if:
- if the LP experiment is not available
- if no internet connection
- if more than 3 seconds have passed and LP didn't finish it's download
Added two new events that could be tracked to Leanplum
MmaDelegate.ONBOARDING_DEFAULT_VALUES and MmaDelegate.ONBOARDING_REMOTE_VALUES
to inform if showing the Onboarding with server values was possible or not.
Because of the 3 seconds delay until showing the Onboarding panels leaking the
could be possible. Used WeakReferences for both the Activity in
OnboardingHelper and the OnboardingHelper in MmaLeanplumImp to avoid it.
MozReview-Commit-ID: H30e9Ng7jrM
--HG--
extra : rebase_source : e403b8010005aa82f8b6440586c533ce99952f9f
Waiting for delayed startup and then attempting to force any possibly still
pending session store write to disk by flushing the session store data didn't
turn out to be a good idea, because if the session store had already started its
own automatic write at that moment in time, we'd get back an additional
"PrivateBrowsing:Data" event that we didn't expect, thereby confusing the test.
Instead, we now wait for the first session store write after startup to occur
naturally before proceeding with the test.
MozReview-Commit-ID: Hui9YYec1Ow
--HG--
extra : rebase_source : 7c063871fbe47e5f568f19151292c24232939790
Uses of StringHelper.get are replaced with the StringHelper instance in BaseRobocopTest.java and UITestContext.
MozReview-Commit-ID: FfMhdNCX1vC
--HG--
extra : rebase_source : c83977f5b9d2d70953c6a89aa30cd28501b5c994
We expose the relevant APIs on textarea and input elements anyway
(chromeonly). The QIs will throw on a non-input or non-textarea element, but
none of these consumers expect that to happen.
Also fixes existing code which fails the rule.
MozReview-Commit-ID: CkLFgsspGMU
--HG--
extra : rebase_source : 86a43837659aa2ad83a87eab53b7aa8d39ccf55b
Experimentally try using a String literal in case the NullPointerException at
that line is caused by some weird class initialisation issue.
MozReview-Commit-ID: 1BexpntTBEJ
--HG--
extra : rebase_source : ea71f390ce0d683cd635aae52825871562b78feb
This brings us in line with Desktop's session store, in that we can now collect
data for arbitrarily nested frame structures.
At the same time, this also means that we no longer collect data for dynamically
added frames, so the corresponding mochitest needs to be adapted accordingly.
MozReview-Commit-ID: DfJ3C2ccUne
--HG--
extra : rebase_source : bbb2181d5596d21254d2f7394c1383a3979dcef4
Fix all Java warnings in the Android codebase except deprecation and
serial warnings, and warnings in third-party code.
There is one required change to exoplayer2 code under thirdparty,
because that code is included directly in the geckoview project, instead
of the thirdparty project. I think I'll just make a pull-request to
upstream the change, instead of separating exoplayer2 into a
gv-thirdparty project.
--HG--
extra : amend_source : 29419a24db9b956a7f3ee573a63f7a055ed90636
Fix all Java warnings in the Android codebase except deprecation and
serial warnings, and warnings in third-party code.
There is one required change to exoplayer2 code under thirdparty,
because that code is included directly in the geckoview project, instead
of the thirdparty project. I think I'll just make a pull-request to
upstream the change, instead of separating exoplayer2 into a
gv-thirdparty project.
Currently Fennec remote debugging has a bug where custom tabs / PWA can
permanently override debugging of Fennec tabs. Fix that bug by switching
between the browser/geckoview window types depending on if the Fennec
window is gaining or losing focus.
MozReview-Commit-ID: 2BhAOPFz3c0
--HG--
extra : rebase_source : b9b6059241549bdb6badcc5702c9e47e7228edb3
Currently Fennec remote debugging has a bug where custom tabs / PWA can
permanently override debugging of Fennec tabs. Fix that bug by switching
between the browser/geckoview window types depending on if the Fennec
window is gaining or losing focus.
MozReview-Commit-ID: 2BhAOPFz3c0
--HG--
extra : rebase_source : b9b6059241549bdb6badcc5702c9e47e7228edb3
The old name no longer makes sense, since it no longer exports an spawn_task
symbol, and add_task is what we really care about.
MozReview-Commit-ID: IE7B8Czv8DH
--HG--
rename : testing/mochitest/tests/SimpleTest/SpawnTask.js => testing/mochitest/tests/SimpleTest/AddTask.js
extra : rebase_source : 03bca5aa69a7625a49b4455a6c96ce4c59de3a5a
This was done using the script at:
bc5629735d/processors/add-task-async.jsm
MozReview-Commit-ID: KxuS9Cen87
--HG--
extra : rebase_source : c0028e0cd55ba1643610cd30c55c6f4bca7d6e58
extra : histedit_source : ebc84fdec9c2db6176632d62de4e7bdad2a7829d
In practice, Android never enforced restrictions on the tag length, and
in newer versions, the restriction is removed, so we shouldn't limit the
tag length at all.
MozReview-Commit-ID: JQF9FBdB5Fj
--HG--
extra : rebase_source : 71aa09210d694b68a72043f7588fbd799f385c23
Moving GeckoEditable and GeckoInputConnection to o.m.geckoview lets us
make the interfaces inside SessionTextInput package-private, so they
don't show up in the docs.
MozReview-Commit-ID: 1C8olyqj4sX
--HG--
rename : mobile/android/geckoview/src/main/java/org/mozilla/gecko/GeckoEditable.java => mobile/android/geckoview/src/main/java/org/mozilla/geckoview/GeckoEditable.java
rename : mobile/android/geckoview/src/main/java/org/mozilla/gecko/GeckoInputConnection.java => mobile/android/geckoview/src/main/java/org/mozilla/geckoview/GeckoInputConnection.java
extra : rebase_source : d1538761e494f5e44a111e65febfbbf6e90dc1f3
On Android, GeckoEditableSupport has already dispatched eKeyDown event and
eKeyUp event even during composition. I.e., the pref which will be enabled
by bug 354358 has already been set to true only on Android.
On the other hand, GeckoEditableSupport does not dispatch them if content
listens to "input", "compositionstart", "compositionupdate" or
"compositionend". So, different from the other platforms, we need additional
pref to make the new behavior behind pref.
Therefore, this patch adds a new pref,
"intl.ime.hack.on_any_apps.fire_key_events_for_composition", to override
existing "intl.ime.hack.on_ime_unaware_apps.fire_key_events_for_composition"
pref. And sets mKeyCode and mKeyNameIndex of the dummy KeyboardEvents to
NS_VK_PROCESSKEY and KEY_NAME_INDEX_Process.
MozReview-Commit-ID: Fuy0Ir2xiO5
--HG--
extra : rebase_source : c76b613ea186458ebdf0d67f4bc984e8ac5f1041
Instead of adding and immediately closing a tab, which carries the risk that we
catch a session store file that was written just in-between those two
operations (although part 1 means that we should be able to handle this safely
now), we just reload the current tab.
MozReview-Commit-ID: JbiH8rmbbwJ
--HG--
extra : rebase_source : 540ad903c3b1424b4603233044f5908cc7a09fea
Adding static reduces memory overhead from per-instance to per-class and allows
initialization at compile-time instead of run-time. Found via a proposed
error-prone pull request:
https://github.com/google/error-prone/pull/930
MozReview-Commit-ID: CMj6vqFeCdI
--HG--
extra : rebase_source : 43e91b3d8ff4bd8171ac25bd0b333d09645687a6
We attempt to get the session store into a known state as far as is possible
from Java and then test various situations to check that the expected
"PrivateBrowsing:Data" message is received in each case.
MozReview-Commit-ID: 8RkCQjAPXTT
--HG--
extra : rebase_source : 5c6b1ae911aed0e6ac5d121e78ce06090f14a795
I had forgotten that m/a/base/Makefile.in can't be killed before m/a/tests/browser/robocop/Makefile.in.
MozReview-Commit-ID: KbtRN5ZCTSJ
--HG--
extra : rebase_source : ea16c04cf018d7b5c53db6d0c4e8218703bdd7e0
Add a unit test for GeckoBundle, which tests GeckoBundle more thoroughly
than testEventDispatcher. This also lets us remove the Parcelable test
from testEventDispatcher.
MozReview-Commit-ID: Gn48Zw4Rvx5
Removed FHR client id migration code on the Android side.
MozReview-Commit-ID: X9QKtbh6r3
--HG--
extra : rebase_source : f5587789f6980aecc4309dc329eb051650ad4c6f
This patch was autogenerated by my decomponents.py
It covers almost every file with the extension js, jsm, html, py,
xhtml, or xul.
It removes blank lines after removed lines, when the removed lines are
preceded by either blank lines or the start of a new block. The "start
of a new block" is defined fairly hackily: either the line starts with
//, ends with */, ends with {, <![CDATA[, """ or '''. The first two
cover comments, the third one covers JS, the fourth covers JS embedded
in XUL, and the final two cover JS embedded in Python. This also
applies if the removed line was the first line of the file.
It covers the pattern matching cases like "var {classes: Cc,
interfaces: Ci, utils: Cu, results: Cr} = Components;". It'll remove
the entire thing if they are all either Ci, Cr, Cc or Cu, or it will
remove the appropriate ones and leave the residue behind. If there's
only one behind, then it will turn it into a normal, non-pattern
matching variable definition. (For instance, "const { classes: Cc,
Constructor: CC, interfaces: Ci, utils: Cu } = Components" becomes
"const CC = Components.Constructor".)
MozReview-Commit-ID: DeSHcClQ7cG
--HG--
extra : rebase_source : d9c41878036c1ef7766ef5e91a7005025bc1d72b