This patch lays the groundwork for two things. First, it paves the
way for splitting AppConstants.java into two parts, a GeckoView part
and a Fennec part. This is necessary because the Makefile.in
preprocessing is not flexible enough to write two separate GeckoView
and Fennec constants files into different directories.
Second, this allows us to more flexibly generate the file contents.
Gradle has a way to get compile-time constants into Java code, which
we want to migrate to. The details don't matter right here, but this
paves the way to move from preprocessing to generating the
Gradle-style BuildConfig files while we continue to support both build
systems.
MozReview-Commit-ID: 2o8X99uLoaM
This allows artifact builds to load the new compressed native libraries correctly,
without requiring build config changes.
MozReview-Commit-ID: 3xZzoV3wFda
This will be used to enable the activity stream panel in place of the HomePager. We are
likely to migrate this to a switchboard flag in future once the new panel becomes
shippable (we are still investigating other distribution mechanisms, so it is entirely
possible this will completely change in future).
MozReview-Commit-ID: I9VSliO0IXE
I initially tested my code with a branch around the multidex dependency:
if (mozconfig.substs.MOZ_BUILD_MOBILE_ANDROID_WITH_GRADLE) {
compile ...multidex...
}
I removed it because it seemed unnecessary - the code shouldn't be
included if it's not referenced.
I tested:
* Locally with a build that did not exceed the method limit, pre-Lollipop
* On try, with fx-team
* On try, with beta
MozReview-Commit-ID: APaOdlKd3QF
This patch introduces a background service for downloading content from a
catalog (bug 1200291). This catalog ships with the application and contains
only fonts in this first version (MOZ_ANDROID_EXCLUDE_FONTS).
For now this service is disabled by default (MOZ_ANDROID_DOWNLOAD_CONTENT_SERVICE).
These flags are not intended to be feature specific. On day one, we
intend to support a single GCM-backed feature -- Push Notifications --
but the set of GCM-consuming features is potentially large (e.g.,
possibly Firefox Sync tickles and Send Tab to Device alerts). Such
features can and will have their own build flags.
Note that GCM sender IDs are not sensitive -- see link in code
comment. Since this is something custom branding will almost always
want to set, I don't want to bury the default value in confvars.sh.
Currently, all versions of Firefox run with the existing native
Firefox Account UI. This flag will opt-in to maintaining that
experience while we transition to a web account UI. Once we're stable
on the web, we'll remove this flag entirely.
This patch assumes that Android M is going to be API level 23 (very likely) and additionally
checks for Android M Preview builds (Build.VERSION.RELEASE set to "M").
Rather than hardcoding the following classes in AppConstants.java.in and AndroidManifest.xml, they are set in
confvars.sh:
org.mozilla.gecko.GeckoApplication (Specified using MOZ_ANDROID_APPLICATION_CLASS)
org.mozilla.gecko.BrowserApp (Specified using MOZ_ANDROID_BROWSER_INTENT_CLASS)
org.mozilla.search.SearchActivity (Specified using MOZ_ANDROID_SEARCH_INTENT_CLASS)
I replaced the compile-time ANDROID_PACKAGE_NAME with the run-time
context.getPackageName() for two reasons:
1) I claim this is more correct. It's hard to imagine Fennec working
with ANDROID_PACKAGE_NAME != context.getPackageName(), but right here
we should use the run-time, not the build-time state.
2) GeckoLoader is part of GeckoView, and as such it shouldn't assume
anything about the package it's running as.
GeckoView consumers may ship for multiple architectures, so we
shouldn't assume anything about the build-time architecture, but the
reference to MOZ_CPU_ABI is purely diagnostic. There are substantive
changes to make here; we'll cross that bridge some other time.