Commit Graph

283072 Commits

Author SHA1 Message Date
Nick Alexander
2f4cc4cba4 Bug 1168175 - Follow-up: Guard against null contexts. r=bustage
On a CLOSED TREE.

So, apparently we race to have a non-null application context from the
target context.  No matter, we can use the target context directly.
2016-02-04 17:17:07 -08:00
Brian Grinstead
685025dfb0 Bug 1246010 - Force a default width for sidebars even if no pref is set;r=pbrosset 2016-02-04 16:59:35 -08:00
Nick Alexander
779ea83d1f Bug 1234629 - Follow-up: Add forgotten documentation file. r=me
Documentation only: DONTBUILD NPOTB
2016-02-04 15:54:12 -08:00
Nick Alexander
bf5ea4d671 Bug 1233882 - Fold base Gradle project into app Gradle project. r=sebastian,mcomella
DONTBUILD NPOTB

Using the real Android manifest tripped up Robolectric, so I've taken
the easy way out and added a dummy TestGeckoApplication; see comment
in the code.
2016-01-17 21:52:46 -08:00
Mark Finkle
0b7adf0a42 Bug 1227662 - Fix code and add tests for fetching video mimetypes r=margaret 2016-02-04 18:19:59 -05:00
Nick Alexander
7048631bca Bug 1242213 - Part 3: Use android:packageName="org.mozilla.gecko" and --rename-manifest-package. r=mfinkle
ON A CLOSED TREE

I have manually verified that this results in a byte-identical
gecko.ap_.  This is because after the earlier patches there are no
definitions (or aliases) that are package-local (like .App or
.Webapp), which are the only things (other than the Android package
name) that get rewritten by --rename-manifest-package.
2016-01-24 22:00:30 -08:00
Nick Alexander
7c9eb55ac0 Bug 1242213 - Part 2: Fold App <activity-alias> into BrowserApp <activity>. r=mfinkle
Way back in Fennec 33 (Bug 929865, see
https://hg.mozilla.org/mozilla-central/rev/a4f39c9db1d9) we replaced
org.mozilla.gecko.App with org.mozilla.gecko.BrowserApp and introduced
the .App <activity-alias>.  Per the entry for android:name of
http://developer.android.com/guide/topics/manifest/activity-element.html,
.App translates to $ANDROID_PACKAGE_NAME.App.  We haven't referenced
an Activity qualified with a non-org.mozilla.gecko *class* name (for
example, from bookmark shortcuts) since well before Fennec 33, so this
probably never did what it was intended to do: we wanted to redirect
org.mozilla.gecko.App to org.mozilla.gecko.BrowserApp, but it instead
has been redirecting org.mozilla.fennec.App to
org.mozilla.gecko.BrowserApp.  I don't think we've been referring to
$ANDROID_PACKAGE_NAME.App since well before Fennec 29, if ever.

The <activity-alias> has been servicing essentially all
<intent-filter> invocations of Fennec by passing them directly to
org.mozilla.gecko.BrowserApp.

This pushes a long programme of simplification forward.  Fallout might
look like very old homescreen shortcuts failing to launch, but I'm
quite confident that won't actually happen.
2016-01-24 22:00:29 -08:00
Nick Alexander
2d1aa73a7f Bug 1242213 - Part 1: Remove old-style Webapp entry-point. r=mfinkle f=myk
This <activity> and <activity-alias> support old-style homescreen
shortcuts to old-style Webapps.  Such shortcuts must have been
produced at least 18 months ago, and pre-date the new-style synthetic
APK Webapps entirely.  New-style APK Webapps are slated to be removed
from the product entirely, and there's no reason to keep their even
less viable predecessor around.

Telemetry from http://mzl.la/23kXGV5 shows that there were no launches
of webapps (old-style or new-style) for Fennec 43 release.  Telemetry
from http://mzl.la/23kXFAs shows that there were 40.7k launches of
webapps (again, old-style or new-style) for Fennec 44 beta (of 39.0M
total -- for 0.1% total).  We cannot distinguish old-style from
new-style, but it is safe to assume it's a tiny proportion.

Users with such homescreen shortcuts will see a bogus "App isn't
installed" message and need to delete and re-create their shortcut in
some way.

The org.mozilla.gecko.Webapp class cannot be removed until new-style
APK Webapps are removed.
2016-01-24 22:00:29 -08:00
Nick Alexander
b61342e4a0 Bug 1242213 - Part 0: Use org.mozilla.gecko.BrowserApp instead of .App. r=me,gbrown,bc
This approach lets us get rid of the .App <activity-alias> definitions, at
least.

In Bug 1237755, I tried pretty hard to use real intent filters, rather
than a different hard-code path name, but ran into significant issues,
and finally into the hard reality that Android 2.3 doesn't support
bare package names.  (It only supports package/class component names.)
Android 2.3 can't die fast enough.

Sadly, this approach doesn't address the issues I see loading URLs
that prompted Bug 1237755.

This is the path of least resistance.  Onwards!

Tested via:

nalexander@chocho ~/M/gecko> ./mach run
Starting: Intent { act=android.activity.MAIN cmp=org.mozilla.fennec_nalexander/org.mozilla.gecko.BrowserApp }
Warning: Activity not started, its current task has been brought to the front
nalexander@chocho ~/M/gecko> ./mach run https://mozilla.org
Starting: Intent { act=android.activity.MAIN dat=https://mozilla.org cmp=org.mozilla.fennec_nalexander/org.mozilla.gecko.BrowserApp }
nalexander@chocho ~/M/gecko> ./mach run file:///mnt/sdcard/test.html
Starting: Intent { act=android.activity.MAIN dat=file:///mnt/sdcard/test.html cmp=org.mozilla.fennec_nalexander/org.mozilla.gecko.BrowserApp }
2016-01-27 12:15:19 -08:00
Andrzej Hunt
18ee77d9f8 Bug 1245516 - Don't shadow originHost, so we can process appOrigin correctly r=margaret 2016-02-03 15:27:35 -08:00
Nick Alexander
85450c9ba9 Bug 1234629 - Post: Add simple bouncer APK docs. r=me 2016-02-04 11:23:27 -08:00
Nick Alexander
c2377a3cbe Bug 1234629 - Post: Make bouncer APK Java package org.mozilla.gecko, like the main APK. r=me
This small change is a follow-up to Bug 1242213, which did the same
for the main package.  This is a nod to the future and Gradle, which
cleanly splits the internal Java package (org.mozilla.gecko) from the
external Android package (org.mozilla.fennec and friends).
2016-01-27 15:28:12 -08:00
Nick Alexander
5590b049e3 Bug 1234629 - Post: Add Gradle support for bouncer. r=me 2016-01-26 11:54:00 -08:00
Nick Alexander
2533b6a1c6 Bug 1234629 - Part 3: Make bouncer's <intent-filter> set a larger subset of Fennec's <intent-filter> set. r=margaret 2016-01-27 15:44:29 -08:00
Nick Alexander
bd7c9cf824 Bug 1234629 - Part 2: Fail packaging if bouncer APK and main APK have different permissions. r=gps
This isn't sensible for b2gdroid, but that project should never enable
the bouncer APK anyway.
2016-01-27 14:34:46 -08:00
Nick Alexander
a390c29b80 Bug 1234629 - Part 1: Create bouncer APK for OTA distribution installs. r=margaret,gps
This commit produces an "install bouncer" APK which is a "hollow
shell" that looks like the main Fennec APK.  In particular, both APKs have:

* the same Android package name (application id); and
* the same set of <permission>, <uses-permission>, and <uses-feature>
  blocks in their manifests.

The bouncer APK must always have an android:versionCode smaller than
the main Fennec APK; for now, we will just bump that manually
mobile/android/bouncer/moz.build.
2016-01-27 15:28:31 -08:00
Nick Alexander
ca190092a3 Bug 1234629 - Pre: Make Distribution look in /data/data/$PACKAGE/distribution last. r=rnewman
Call a distribution in /data/data/$PACKAGE/distribution a "data
distribution".  Right now we read data distributions only in response
to writing them via another code path (extracting from APK, or
downloading).  We don't recognize a data distribution in the same way
that we recognize a system distribution (in /system/.../distribution)
in the Java code, simply because we don't look for it; and I haven't
investigated, but I think that Gecko may in fact recognize a data
distribution in this case.

This patch simply recognizes data distributions after looking for
other distributions.  That way data distributions written by the
bouncer APK are recognized and initialized, but not given precedence
over other distribution channels.
2016-01-26 17:06:27 -08:00
Nick Alexander
e075d1ad5b Bug 1168175 - Turn on screen and disable keyboard before running each test. r=gbrown 2016-02-04 09:54:12 -08:00
Nick Alexander
d8104a59cd Bug 1163082 - Part 2: Extract Android distribution from packaged assets rather than APK root. r=rnewman
This reads from "assets/distribution/**" in the APK and writes to
"distribution/**" in the data directory.  That output is the same, but
the input used to read from "distribution/**", which is not really
supported by modern build tooling (Gradle), which doesn't allow to
write files directly into the APK root.

I manually tested this without issue.  I see no way to add meaningful
tests to our current Robocop test suite; the long term testing
approach is to develop a new test for this functionality and only run
it against the "distribution" build type that was added in Bug
1163080.  However, that's a larger project than I have time for now.
2016-01-26 10:36:09 -08:00
Nick Alexander
61ddcc0a51 Bug 1163082 - Part 1: Add --with-android-distribution-directory. r=gps
This simply packs the assets/ subdirectory of the distribution
directory into the assets/ directory of the Android APK using existing
mechanisms.  It also removes the older method of manually pushing
files into dist/bin/distribution, from where they would be packaged
into the APK under distribution/.
2016-01-27 12:25:04 -08:00
Julian Descottes
3c349c1000 Bug 1240044 - wait for MozAfterPaint in browser_profiler_tree_abstract tests on CLOSED TREE;r=bgrins
While waiting for a fix at test harness level, added a helper waiting for MozAfterPaint
when running in e10s mode for all the browser_profiler_tree-abstract tests.
2016-01-21 15:42:52 +01:00
Wes Kocher
be5e6f9b9e Backed out changeset 3d2eace770d1 (bug 1244120) for very frequent leaks on Win7 CLOSED TREE 2016-02-04 12:51:14 -08:00
Wes Kocher
c3799c8915 Backed out changeset 69ec780e039c (bug 1245225) for enabling a bunch of tests that frequently fail CLOSED TREE 2016-02-04 11:17:03 -08:00
Mark Banner
67683dea2f Bug 1245937 - Disable browser_chat_window.js for test failures frallout from bug 1154277. rs=orange-fix CLOSED TREE 2016-02-04 19:04:22 +00:00
Brian Grinstead
c8279f69f0 Backed out changeset 16a675e05315 for breaking the browser toolbox on CLOSED TREE (bug 1188405) 2016-02-04 10:38:29 -08:00
Victor Porof
3dcfba762d Bug 1241570 - Split browser_perf-telemetry into multiple tests ON A CLOSED TREE, r=jsantell 2016-02-04 20:33:53 +02:00
Michael Comella
043c63414a Bug 1245711 - Update Adjust proguard cfg to match docs. r=mfinkle 2016-02-03 16:49:30 -08:00
Brian Grinstead
abec3d536b Bug 1243992 - e10s fixes for browser_webconsole_bug_585991_autocomplete_keys.js;r=linclark 2016-02-04 09:08:30 -08:00
Brian Grinstead
7fa09413d9 Bug 1243970 - e10s fixes for browser_webconsole_bug_597103_deactivateHUDForContext_unfocused_window.js;r=linclark 2016-02-04 09:07:51 -08:00
Carsten "Tomcat" Book
773930bc0f Backed out changeset 3cd839e515b9 (bug 1245420) for timeouts in browser_responsiveruleview.js 2016-02-04 16:42:01 +01:00
Carsten "Tomcat" Book
e982149b67 Backed out changeset f09ea2712445 (bug 1229913) 2016-02-04 16:41:33 +01:00
Dave Townsend
c3aac1ce9e Bug 1245712: Fix the XBL processor's handling of columns and leading and trailing whitespace. 2016-02-03 16:50:01 -08:00
Edouard Oger
f2e0e63e7a Bug 1245505 - Localize correctly the last sync date. r=markh 2016-02-04 05:08:00 -05:00
David Rajchenbach-Teller
89b5971b7c Bug 1243549 - Make sure that startup sanitization doesn't throw because it can't find a tabbrowser. r=mak 2016-02-04 09:40:40 -05:00
David Rajchenbach-Teller
259ea7a423 Bug 1243549 - SessionFile.wipe() now waits until SessionFile has been properly initialized. r=mconley
While investigating bug 1243549, we encountered several instances of the following error message during each startup:

*************************
A coding exception was thrown and uncaught in a Task.

Full message: TypeError: this.Paths is null
Full stack: Agent.wipe@resource:///modules/sessionstore/SessionWorker.js:296:7
worker.dispatch@resource:///modules/sessionstore/SessionWorker.js:21:24
anonymous/AbstractWorker.prototype.handleMessage@resource://gre/modules/workers/PromiseWorker.js:122:16
@resource:///modules/sessionstore/SessionWorker.js:30:41

*************************

These messages can be explained as follows:

* If sanitization has failed during shutdown, it attempts again to
  sanitize during startup. This happens more often than it used to,
  because of 1/ startup bug fixes in bug 1089695; 2/ new shutdown bugs
  most likely also added by or around bug 1089695.

* Sanitization during startup doesn't wait until Session Restore has
  properly started to sanitize the session. So sanitization of Session
  Restore file fails. This has probably always been the case, except
  we never noticed.

* For some reason I do not understand, it attempts to sanitize several
  times.

* I suspect that this can cause problems during startup, as
  sanitization and Session Restore race to use/remove the files of
  Session Restore.

This patch makes sure that SessionFile.wipe() waits until
initialization of SessionFile is complete before proceeding.
2016-02-02 12:56:11 +01:00
Ryan VanderMeulen
b4dbb62bea Bug 1245832 - Update pdf.js to version 1.4.42. r=bdahl 2016-02-04 09:29:47 -05:00
Mike de Boer
a67e36967b Bug 1154277: follow-up - fix linting error by removing a leftover break statement. rs=me 2016-02-04 14:59:28 +01:00
Mike de Boer
17271d5649 Bug 1154277: Part 4 - Update the loop add-on and introduce a pref to switch e10s support for Loop/ Hello on or off. The default for now is off. r=Standard8 2016-02-04 14:02:04 +01:00
Mike de Boer
c01b4f7990 Bug 1154277: Part 3 - implement test changes to work in e10s mode as well. r=mixedpuppy,Standard8 2016-02-04 13:42:10 +01:00
Mike de Boer
f72d46f1cc Bug 1154277: Part 2 - support running Social API documents to run in a remote browser, i.e. the content process. f=mixedpuppy, r=Standard8 2016-02-04 12:50:06 +01:00
Mike de Boer
6c7fdd37b9 Bug 1154277: Part 1 - allow to swap docShells on remote browsers that are not a child of a BrowserDOMWindow. r=smaug 2016-02-04 12:50:03 +01:00
Carsten "Tomcat" Book
2a07da30de Merge mozilla-central to fx-team 2016-02-04 12:08:00 +01:00
Carsten "Tomcat" Book
f84c32592e merge mozilla-inbound to mozilla-central a=merge 2016-02-04 12:02:05 +01:00
Mark Banner
d7de75fdb7 Bug 1239828 - Now that Loop's system-addon L10n is hooked up, remove redundant strings. r=Mardak 2016-02-04 10:42:19 +00:00
Mark Banner
ccb2f3658b Bug 1239828 - Support Loop's localisation mechanisms for Loop as a system-addon. r=glandium 2016-02-04 10:42:19 +00:00
Mark Banner
6d6e584df4 Bug 1239828 - Update Loop to the latest version. r=Standard8 for import of already reviewed code. 2016-02-04 10:42:18 +00:00
Alexandre Poirot
0c63115a50 Bug 1188405 - Convert gDevTools/gDevToolsBrowser into modules. r=jryans
gDevTools.jsm isn't properly reloadable as JSM as meant to be long-lived singletons.
Also, it contains browser related code (gDevToolsBrowser) mixed with more generic one (gDevTools).
This move is going to help hot reloading devtools codebase while improve readability of
one of our core piece of code (devtools startup and browser hooks).
2016-02-04 02:20:56 -08:00
Alexandre Poirot
888f223469 Bug 1214352 - Add telemetry for Scratchpad as top level window. r=jryans,p=bsmedberg 2016-02-04 02:20:55 -08:00
Alexandre Poirot
8114cc3121 Bug 1214352 - Enable scratchpad in tab toolboxes. r=jryans 2016-02-04 02:20:55 -08:00
Nick Alexander
212a46e40e Backed out 2 changesets (bug 1163082) for Robocop rc1 failures.
Backed out changeset baf25be8d491 (bug 1163082)
Backed out changeset e228040a044b (bug 1163082)
2016-02-03 23:15:00 -08:00