Add Google Analytics support

PS2: add custom dimensions and override app-name & app-version
PS3: report unified version name (branch + milestone-X|nightly|unofficial)
PS4-6: further reporting changes
PS7: add back own stats reporting

Change-Id: Ieb69944ba0e67cbaddb0e94c1b87fc99510bdd36
Squashed Stats commits from CM

Remove the notification on boot. Users are thinking they need to opt out to get rid of the notification.
The setting to opt-out still exists in the Settings app.
If the user does not opt out within 'tFrame' time (1 day), the checkin service will now run; prior
to this, the checkin service would not run until the next reboot. That next reboot could occur within a
few minutes (startup crash, which then automatically checks in before the user has a chance to opt out)
or even the possibility of never. This is unpredictable and buggy.
Change the checkin frequency from 7 days to 1 day.

CMStats: fix up the logic and potential sync failures

Clean up CMStats code.

Besides the cleanup, make sure to wait a bit between retries if upload fails for whatever reason.

Change-Id: Ib83e35bab2dc3d643751f032f810569dc71cafcc
Switch to RB Stats
Settings: Fix FC caused by anonymous stats.
ProfilesSettings : Allow nfc override (2/2)

Allow user to override nfc state via profiles

Change-Id: I2a401f17ce42b1711588242e0604997e1f5d8399
Fix build and feature

sorry my bad on NFC profile feature pushed the wrong commit.
Fixes build and removes unsupported features on profile
settings

Change-Id: I2c1c27dbf080898286b5ed034926ccde5905bdf7
Statistics: update for client id and current view

use hashed Mac address as client id and store device name
as current view

Change-Id: Ia2b26cd674035fc97ca415ba0ca1f78e1628745f
Signed-off-by: Dirk Rettschlag <dirk.rettschlag@gmail.com>
HALO (2/2)

HALO is Androids one and only multitasking solution.

We explicitly do not go the Samsung/Cornerstone route. This solution is basically an extension of
the regular notificationshade, which is an aggregator for notifications that can be checked out when
time permits. HALO completes it by allowing you to respond to tasks on the spot, trying to be as
unintrusive as possible and flexible in regards to policies (white/black lists).

Features:

- Apps open up in floating state, apps underneath do not pause
- complete SystemUI & Core integration, making HALO feel like a native feature, source/SDK and UI/UX
- HALO has white and blacklists, which for now allow fine control for apps pinging through HALO
- multiple gestures to navigate HALO:
  - double-tap-move: move
  - tap-drag-left/right: task through notifications, finger up launches
  - tap-drag-up: dismiss notification
  - tap-drag-down: put HALO into semi-hidden state
  - swipe while HALO is hidden wakes it up
  - drag-to-X to remove HALO altogether
- comes with as few settings as possible, everything should be self explanatory and intutive,
  users must be informed about the double-tap gestures which is the only catch.

Known issues:

- Integration has been finished for PhoneUI. TabletUI and PIE must be integrated still.
- Packageinstaller must allow HALO through its overlay check or it will disable the install-app button.
- The low level has a few remaining issues:
  - Some apps still go up fullscale (they trick us with services, circumventing the intent flagging)
  - Some 3D games still pause
  - There is one known app that refuses to end on back or touch-outside, that is WeChat
  - The activitystack pause implementation works but is makeshift

To-Do:

- On-screen tutorial at first start up to teach users the gestures
- Fixing all known issues, full integration in the remaining UI's
- Perhaps hybrid engine integration for running floating apps in a decreased size

Merge branch 'multiwindow' into jellybean

Conflicts:
	res/values/arrays.xml
	src/com/android/settings/paranoid/Toolbar.java

Change-Id: I87ad32f302592fff2c77e7cb37c5695d40ee90cd

Conflicts:
	res/values/arrays.xml
	res/values/strings.xml
	res/xml/pie_settings.xml
	src/com/android/settings/paranoid/Pie.java
Settings - add an AlertDialog before to delete APN to avoid fails

patch 1: fix blank space
patch 2: remove FR translation and change NegativeButton string
patch 3: improve the NegativeButton (thank you, David)
patch 4: remove create()

Change-Id: I3361d4160a7e1c4eaee094f08c7d212f71e9e0e7
Move HALO to a separate preference

In prevision of future development by PA, moving HALO to a separate preference screen seems to be a better option.

Icons: @Kroz
Derp
[1/2] Permit home button wake to be configurable

To activate, enable bool config_show_homeWake in
device overlay/packages/apps/Settings/res/values

Change-Id: I00afe89ba5bf36d74b93a40b9d15eef2e805611f

Conflicts:
	res/values/cm_strings.xml
	res/values/config.xml
	res/xml/display_settings.xml
	src/com/android/settings/DisplaySettings.java
HALO: Option to pause the underlying app (2/2)

- adds an option to pause the active app when using HALO
- this is enabled by default for devices with low memory
- (currently: <640MB RAM available to the kernel)
Update strings.xml

Fix some redundant/confusing strings
Update strings.xml

User doesn't needs to know this. I think
String updates
RB Settings: Add icons
Halo: Add master switch to disable Halo (2/2)
Also did some cleanup.
Settings: Improve Recents (1/2)

- Moved Kill-All option to RB Settings
- Create list preference for different options
- Remove ugly Kill-All button and replace it with image
- Give the user the option to specify location of image (Bottom/Top/Left/Right)
- Add RB Icon for No recents apps
- Move recent items to the middle
- Add header to recent items
- Switch app icons to the right of recent items
Show application's package name in the "App info" screen.

Change-Id: I7dac8ffa0b10abb5ff235750e90a96d801b2f919