[Runtime] Rename xwalk.app API to xwalk.app.runtime

In order to align with Chrome runtime API naming
(https://developer.chrome.com/apps/runtime.html), we changed xwalk.app.* APIs to
xwalk.app.runtime.*.
[Runtime] Move application runtime extension from extension thread to UI thread

After PR #1080(https://github.com/crosswalk-project/crosswalk/pull/1080) we can
run application extensions on UI thread now.

The internal application extension code used to run on extension thread while
most of the application service code runs on UI thread. This means now we don't
need to post task to UI thread and get its result back in extension thread back
and forth anymore. This will make the code more clean and straight forward.
[Application] Add a way to observe ApplicationService activity

Add an Observer interface for ApplicationService, so that other code can
be notified when applications were added or removed.

This will be useful when exposing D-Bus interface on Linux because we
keep an D-Bus object for each application installed.
[Application][Linux] Expose installed apps via D-Bus

This commit exposes the '/installed' object path, that allow D-Bus
clients to List, Install and Uninstall applications. The D-Bus
interfaces are described in the implementation files.

InstalledApplicationsRoot is the entry point, and hold a corresponding
D-Bus object. It also hold a vector of child objects, which themselves
have their own D-Bus objects.

The org.freedesktop.DBus.ObjectManager interface implementation is
partial but enough for our current functionality.
[Android] Improve the illegal character handler in packaging tool.

  When the application name includes the illegal character '.', the
packaging tool doesn't handle it and other illegal characters are
handled but no prompt. This fix is to improve the illegal character
handler in the packaging tool and the test case related to illegal
application name is added.

BUG=https://crosswalk-project.org/jira/browse/XWALK-139
[Android] [REG] Re-enable remote debugging works

It is a regression introduced by 32 rebasing. The fix contains 2 major changes:
o Override the new method EnumTargets to list the inspectable targets
  for all valid web contents.
o Update the frontend url by using webkit revision instead of chrome
  version, like Android WebView does.

BUG=https://crosswalk-project.org/jira/browse/XWALK-456
[Application] Renaming XPKExtractor to Extractor

Extractor class will be used by all the package formats to
Extract / unzip the package to a temporary directory
Extractor unit test right now are checking only the xpk packages
Unit tests for .wgt packaged files will follow later
Extractor unit test should use with scoped_ptr
Rename SetupXPKExtractor to SetupExtractor
[Application] Add a base class Package.h|cc

The specific formats like xpk/wgt should inherit from
this base class. Package::Create() should create the specific
class depending on the file extension.
Generalize the Extractor, meaning Extractor class now has a
base class(Package) pointer.
change is_ok to is_valid
.get() is not needed
[Application] Inherit XPKPackage from Package

Refactoring Package related classes to a more generic approach.
VerifySignature() seems to be a better name than Validate() as the only
thing done in that function is verify the signature
[Application] Add a WGTPackage class inheriting from Package

Add a basic implementation of WGTPackage class
AFAIK there is no need for pre processing in the wgt package
like checking signature or header.
So we can directly proceed to parsing the xml
[Application] RefCounting Extractor is not necessary.

Since extractor is only called in application_service, we dont need
to use RefCountedThreadSafe. A simpler scoped_ptr suffices.
[Application] Check for both .xpk and .wgt files

Extractor::Create() and Pacakge::Create() are the callers where
we check for the file extension
[Application] Use only 1 factory method for Create()

Only Package::Create() method should be static. It should create the
appropriate derived class object. The derived class should not have any
factory method / static Create()
The base class constructor in (Package class) should be protected.
Remove unnecessary kXpkExtension
[Application] Move Extraction logic inside Package class

Simplify the code by putting the Package extraction logic inside the
Package Class.
Remove Extractor.h|cc
Rename extractor_unittest.cc to package_unittest.cc
[Application] Remove unnecessary constructors

Remove unnecesary constructors. We are always creating new objects
passing the path. So constructor that takes ScopedStdioHandle is not needed.
Remove default constructors
[Application] Fix unit tests

Fix for the package unit tests
[Application] Add Application Management tool

This tool provides a way to list, install and uninstall Applications
using the D-Bus API that will be provided by Crosswalk when it is run
using the run-as-service switch.

Fow now, only listing installed applications is tested. When Crosswalk
implements the install/uninstall functionality, there should be little
to no changes to this tool. But the code is included so the aim of
this tool is made clear.
Merge pull request #1180 from ShDavidliu/manifest

[Android] Improve the illegal character handler in packaging tool.
Merge pull request #1195 from hmin/remote-debugging

[Android] [REG] Re-enable remote debugging works
Merge pull request #1178 from seanlong/xiang_api

[Runtime] Move application runtime extension frome extension thread to UI thread