Catch up on legacy support commits (Credit CM)

Fix unresponsive home key after waking device with a long press

With the lockscreen disabled mHomeConsumed would not be properly set back to
false upon releasing the key, causing a subsequent press to perform no action.

Change-Id: I38eeba5850c2f0474cc4cca82a9dcbf17afa4665

Camera: Add support for QC camera features.

Added APIs and keys for all QC features. This
will enable application to get/set paramters.

Change-Id: I58a53c7b9133a3acddc34b268dac086c9562d533

Camera: Video HDR Feature Integration.

Added framework support for camera applications to query supported
video HDR modes and set the required mode.

Change-Id: Ie318e586838a2f035e59e30fa51af35b52f7c886

Camera: Adds support for meta data callbacks

- This change adds a new type of callback
  that will be called when there are pending
  meta data notifications.

Change-Id: I84f5cbafe4f023c7b0efa9ec8620756b0eaa428d

Frameworks: QCFace framework added

Add framework support for extended face detect

Change-Id: I2a1c477ee6d11f2b9764966abbb85ede9100fe91

Camera: Adds support for longshot configuration

- The Camera API is extended with one additional
  call for longshot mode configuration.

Change-Id: If3bcad003facae22ec2bd690480dc3db63f0b28a

Frameworks: Enhance face detection

Add support for facial processing features:
smile detection, gaze detection and blink detection

Change-Id: Ic186ff0658e755a8b5287cffa1dd58d9eafebc9a

Fix compilation for non QCOM hardware after 'Enhance face detection' commit

Change-Id: I337a7a2e8b124aac76f52abcc0edd8af9b0b0e29

MediaRecorder: add pause interface

--add pause in java level
--add pause in jni level

Change-Id: I7f2d5d5ebb97716458b55a5780fd6cc3d09e9f11

Frameworks : Fix face detection

I337a7a2e8b124aac76f52abcc0edd8af9b0b0e29 introduced
the ifdef's at the wrong location. This patchset addresses it.

Change-Id: I6b19fb96076bdc62b2ca57d1ccaf97f0cb901d67

DeviceKeyHandler : Allow handling keyevents while screen off

Some devices require the keyevents to be processed while the screen
is off, this patchset addresses that by moving the filter up in the call
hierarchy.

Change-Id: If71beecc81aa5e453dcd08aba72b7bea5c210590

Squashed commit of audio changes from CodeAurora

MediaFile: Add DIVX and MPEG2TS file format

Change-Id: I9f8cfbe8138c6d3d0d824bff2542b91d72a06b82

audio: Define ANC headset and proxy device

Change-Id: I681d73433d874ec66ec0b1f1f39869008d7d7d0d
(cherry picked from commit 1e6c410eadfc510a9f116bb3da142214fe761225)

audio: add support for QCOM WiFi display

- Define QCOM WFD intents
- Register and handle WFD intends in AudioSystem

Change-Id: I1e5a73d4aa5595bed44d24652647c12b7ef4ae1f

audio: add support for QCOM audio formats

- Add support for EVRC, QCELP, and WMA formats

Change-Id: If3676b88fa287b484ef8616c0a6b67177b61a720

PhoneWindowManager: Changes for WFD.

- WFD now sends WIFI_DISPLAY_VIDEO intent to set UI orientation.
- PhoneWindowManager to listen for WFD intents.
- Display on WFD should be same as seen on the HDMI, so set the
  orientation to HDMI orientation

Change-Id: I638adaa906e2151b1c6ae496343714fe828f5dbd

audio: add support for QCOM vocoders

- Add support for EVRC,QCELP and other
  QCOM vocoders

Change-Id: I9b2a18fe7d01a9198eb470e94e7176b7a6da2c7c

Conflicts:
	core/jni/android_media_AudioTrack.cpp
	media/java/android/media/AudioRecord.java
	policy/src/com/android/internal/policy/impl/PhoneWindowManager.java

base: fix constant conflict

There is a conflict 2 media type which shares the same constants which is a DVIX and JPEG.
which causes some app to think jpeg is a dvix video file
It was due to the merge of the qualcomm patches (patch: http://review.cyanogenmod.org/#/c/28960/ ) which was merged on the 23rd

Change-Id: Ida014adab4a954aa81a16d1ff401f9847f87d1a5

frameworks/base: Add changes for Incall Music Delivery

- Add Flag and Stream type required for incall music delivery.
- Add Tone types for ToneGenerator

Change-Id: Ic05cd1af1172dda3c527af826c6e9a48d6ae20d5
Fix App Ops permission mapping structure.

The entry to map the post notification op
to a permission is at the wrong offset
within the sOpPerms array. This patch
fixes the issue.

Change-Id: Ia241d274e484b6a24edbfb17b87bb887b61f1ee1
Signed-off-by: rpcraig <rpcraig@tycho.ncsc.mil>
Regenerate all the OpenGL stubs.

Bug: https://code.google.com/p/android/issues/detail?id=60390
Change-Id: I2e6f210178f656a5f08a1fcd4239581d680329a6
Pie: fix PIE_GRAVITY receiver

pie gravity in pie settings will not take effect immediately,this commit can fix it.
Merge branch 'jb43-legacy' of https://github.com/ParanoidAndroid/android_frameworks_base into PA

Conflicts:
	media/java/android/media/AudioManager.java
	media/java/android/media/AudioSystem.java
Lower the RAM requirement for hardware acceleration

There are legacy devices with about 365 MBytes of RAM
available to the kernel (HDPI with 512 MB RAM onboard).
Lowering the requirement value for available RAM allows
these devices to also use hardware acceleration, thus
making the UI a lot more responsive and fixing bugs like
this: https://dl.dropboxusercontent.com/u/16268774/Screenshots/Phone/Screenshot_2013-10-07-01-27-45.png
(notice the "shadow" is missing)

Change-Id: I0343ddbb3c7f95bed674b5852772ab819065ea69