[Android] Fix that make_apk_test fails when out/ has both ARM and x86 builds

Both testCustomizeFile and testEmptyMode fail when out happens to have
both an ARM and an x86 build: in this case, the ARM native libraries will be around
and make_apk.py will generate both ARM and x86 APKs,
making the self.assertFalse(os.path.isfile('Example_1.0.0_arm.apk')) call fail.

BUG=https://crosswalk-project.org/jira/browse/XWALK-1466
[application] application installation should not cause termination of all the running apps

Before the change installation of any application, having the main document,
caused xwalk process termination (and hence termination of all the running
applications).
This patch fixes it so that only the installation-related application is
terminated and the rest applications remain being active.
[Linux] Add NaCl support

Based on NaCl component work (http://crbug.com/244791) from upstream,
this commit is to add Native Client(aka NaCl) support.
It now can run examples from nacl sdk.
  $ cd <nacl_sdk_dir>/pepper_canary/example
  $ TOOLCHAIN=newlib make serve
  $ xwalk http://localhost:5103

BUG=XWALK-1338
[Tizen][Runtime] Add support for Tizen Metadata.

'metadata' element supports metadata information shared with other web
applications. The defined metadata can be accessed (read-only) through
the Tizen Application API.

BUG=XWALK-1495
Merge pull request #1852 from pozdnyakov/Install_with_main_doc

[application] application installation causes termination of all the running apps
Merge pull request #1843 from shaochangbin/metadata

[Tizen][Runtime] Add support for Tizen Metadata.
[application] Do not interrupt XWalk service

Do not quit XWalk process after the last application
terminated, if XWalk was launched in service mode.
Merge pull request #1858 from pozdnyakov/do_not_interrupt_xwalk_service

[application] Do not interrupt XWalk service
Merge pull request #1859 from darktears/win-build-fix

Fix Windows build.
Bump version to 6.35.127.0
[Android] Try to match cpu arch after loading xwalk core

It's extremely slow to load ARM binaries on ia devices.
And it hurts user experience. Add a method in libxwalkcore.so
to tell XWalkViewDelegate whether the binary is built for IA.

The exception of CPU architecture mismatch will be handled
by XWalkView instead of dispatch to runtime level or embedders.

A AlertDialog will be shown to notify user what's wrong and
suggest them report feedback to application developers or
rate and comment the application on PlayStore.

BUG=https://crosswalk-project.org/jira/browse/XWALK-1283
[Android] Allow XWalkUIClient to overwrite openFileChooser

Previous, select file is handled within xwalk_web_contents_delegate
and the openFileChooser API in XWalkUIClient is not working.
"openFileChooser" is used in android.webkit.WebChromeClient, which
is adopted by many current webview users (e.g. Cordova).

In this commit, it dispatches the request to XWalkUIClient which is
empty implementation. If the derives override the implementation,
it can invoke the callback somewhere to provide the chosen file.
Otherwise, it will fallback to internal solution using
RuntimeFileSelectHelper::RunFileChooser.

BUG=https://crosswalk-project.org/jira/browse/XWALK-1561
[Tizen] Add application hide support

Tizen Application.hide() API need this support to hide current application.

When Hide method is called on the runnning application object, all windows
owned by this application will be hide.
[Android] Launch Screen full spec implementation

As the spec defined, the launch screen contains 3 layers:
1. background color
2. background image
3. foreground image
It's impossible to show all these layers together when an icon is tapped, because
of the limitation of 'Android drawable' mechanism.
The actual working flow is as below:
 - Display the first 2 background layers.
 - Display the 3rd foreground image layer with a Dialog.

Below is the description for the implementation in general:
Build script:
1. Parse manifest.json and customize launch screen.
2. Generate drawable:launchscreen_bg.xml depends on the configuration defined.
3. Copy background and foreground images to res folders.
Runtime:
1. Create a new layout to display 9-piece format foreground image.
2. Parse image-border from manifest.json, and customize the layout.
3. Display the 3 layers in a Dialog.

TODO:
One feature missed in this patch:
'ready_when' = 'user-interactive'

Spec=https://docs.google.com/a/intel.com/document/d/17PuNuHRTQuREUpaCvj-eEx7uYi2avd-VW-oaMXMpvwo/edit?pli=1#
BUG=XWALK-1198
Merge pull request #1831 from seanlong/app_hide

[Application] Add application hide support
[Tizen][Runtime] Enable to open navigation link in system web browser
when it's blocked by CSP mode.

On Tizen platform, the allow-navigation policy will control the behavior
for opening a navigation link in web app, if the navigation link domain
is not list in it, the action will be blocked and the link should be
opened in system web browser.

The patch does some reworks, since there are some issues when using the method
ContentBrowserClient::CanCommitURL, if it returns false, the render process
will be killed, and web application will crash, and it will be fixed in
this patch.
[Runtime] Support to load application resources by the locale setting.

For WGT package, the W3C widget specification defines the concept of
folder-based localization, which is the process whereby an author places
files inside folders that are named in a manner that conforms to a
language-range ABNF rule. That is, by naming folders in lower-case using
values derived from the IANA Language Subtag Registry such as "en-us",
"en-gb", and so on. These locale folders are then placed inside the
container for localized content which is a reserved folder at the root
of the widget package whose folder-name case-sensitively matches the
string 'locales'.

For more details, please refer to
http://www.w3.org/TR/widgets/#folder-based-localization.

The related feature is XWALK-1030 and XWALK-1503
[Android] Remove all java source files in xwalk_core_library

In previous commit a3cd81484.
Some chromium generated source files including R.java and
NativeLibraries.java are still copied into xwalk_core_library.

With this commit, an empty apk target xwalk_core_library_empty
which only depends on xwalk_core_java with no extra code will
be used to get the classes for the chromium generated java codes.
And package them into a jar file.
Merge pull request #1764 from wang16/warn_arm_on_ia

[Android] Try to match cpu arch before loading xwalk core
Merge pull request #1835 from jinbang/fix_make_apk_test_fail

[Android] Fix that make_apk_test fails when out/ has both ARM and x86 bu...