[Android Extension] Fix Activity leaking caused by DeviceCapabilities extension

The static XWalkMediaCodec singleton instance indirectly holds a
reference to Activity via XWalkExtensionManager, it would prevent the
Activity object from GCed and then leak it and all its resources.

BUG=https://crosswalk-project.org/jira/browse/XWALK-2000
[Android] Add a tracing tool for XWalk

It's a wrapper of adb_profile_chrome.py from upstream to support tracing in XWalkRuntimeClientEmbeddedShell.

BUG=XWALK-1977
Merge pull request #2128 from hmin/activity-leak

[Android Extension] Fix Activity leaking caused by DeviceCapabilities ex...
Merge pull request #2126 from kurli/profile

[Android] Add a tracing tool for XWalk
[Android] Refine the key event dispatch for xwalkview

Including following changes:
1. Hook shouldOverrideKeyEvent and onUnhandledKeyEvent into
   content layer correctly.
2. Move the key event handling in xwalkview into dispatchKeyEvent.

After change the process of key dispatch in xwalkview will be:
  Activity.dispatchKeyEvent
  -> XWalkClient.shouldOverrideKeyevent
        <if shouldOverrideKeyevent returns true>
     -> XWalkView.dispatchKeyEvent (handles backkey here)
        <if shouldOverrideKeyevent returns false>
     -> dispatch keyevent to renderer
        <if renderer doesn't consume the keyevent>
        -> web_contents_delegate::HandleKeyboardEvent
           -> XWalkWebContentDelegate.handleKeyboardEvent
              -> XWalkClient.onUnhandledKeyevent

It's pre-adjust for Embedding API v2.

Related to bug: XWALK-2003