diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/android/keycodes.h | 4 | ||||
-rw-r--r-- | include/binder/Parcel.h | 4 | ||||
-rw-r--r-- | include/input/Input.h | 6 | ||||
-rw-r--r-- | include/input/InputEventLabels.h | 1 | ||||
-rw-r--r-- | include/input/KeyCharacterMap.h | 8 | ||||
-rw-r--r-- | include/input/Keyboard.h | 7 | ||||
-rw-r--r-- | include/media/openmax/OMX_Core.h | 6 | ||||
-rw-r--r-- | include/media/openmax/OMX_VideoExt.h | 9 | ||||
-rw-r--r-- | include/ui/DisplayInfo.h | 1 |
9 files changed, 42 insertions, 4 deletions
diff --git a/include/android/keycodes.h b/include/android/keycodes.h index 1f55d9f..421abe5 100644 --- a/include/android/keycodes.h +++ b/include/android/keycodes.h @@ -735,7 +735,9 @@ enum { AKEYCODE_MEDIA_SKIP_FORWARD = 272, AKEYCODE_MEDIA_SKIP_BACKWARD = 273, AKEYCODE_MEDIA_STEP_FORWARD = 274, - AKEYCODE_MEDIA_STEP_BACKWARD = 275 + AKEYCODE_MEDIA_STEP_BACKWARD = 275, + /** Put device to sleep unless a wakelock is held. */ + AKEYCODE_SOFT_SLEEP = 276 // NOTE: If you add a new keycode here you must also add it to several other files. // Refer to frameworks/base/core/java/android/view/KeyEvent.java for the full list. diff --git a/include/binder/Parcel.h b/include/binder/Parcel.h index 3ada1e9..16cd6cf 100644 --- a/include/binder/Parcel.h +++ b/include/binder/Parcel.h @@ -341,10 +341,12 @@ public: }; private: - size_t mBlobAshmemSize; + size_t mOpenAshmemSize; public: + // TODO: Remove once ABI can be changed. size_t getBlobAshmemSize() const; + size_t getOpenAshmemSize() const; }; // --------------------------------------------------------------------------- diff --git a/include/input/Input.h b/include/input/Input.h index 4a67f47..617175b 100644 --- a/include/input/Input.h +++ b/include/input/Input.h @@ -28,6 +28,7 @@ #include <utils/String8.h> #include <utils/Timers.h> #include <utils/Vector.h> +#include <stdint.h> /* * Additional private constants not defined in ndk/ui/input.h. @@ -111,6 +112,11 @@ enum { #define MAX_POINTERS 16 /* + * Maximum number of samples supported per motion event. + */ +#define MAX_SAMPLES UINT16_MAX + +/* * Maximum pointer id value supported in a motion event. * Smallest pointer id is 0. * (This is limited by our use of BitSet32 to track pointer assignments.) diff --git a/include/input/InputEventLabels.h b/include/input/InputEventLabels.h index 344f2f3..f0a6238 100644 --- a/include/input/InputEventLabels.h +++ b/include/input/InputEventLabels.h @@ -311,6 +311,7 @@ static const InputEventLabel KEYCODES[] = { DEFINE_KEYCODE(MEDIA_SKIP_BACKWARD), DEFINE_KEYCODE(MEDIA_STEP_FORWARD), DEFINE_KEYCODE(MEDIA_STEP_BACKWARD), + DEFINE_KEYCODE(SOFT_SLEEP), { NULL, 0 } }; diff --git a/include/input/KeyCharacterMap.h b/include/input/KeyCharacterMap.h index e70666a..3f0914b 100644 --- a/include/input/KeyCharacterMap.h +++ b/include/input/KeyCharacterMap.h @@ -124,6 +124,11 @@ public: * the mapping in some way. */ status_t mapKey(int32_t scanCode, int32_t usageCode, int32_t* outKeyCode) const; + /* Tries to find a replacement key code for a given key code and meta state + * in character map. */ + void tryRemapKey(int32_t scanCode, int32_t metaState, + int32_t* outKeyCode, int32_t* outMetaState) const; + #if HAVE_ANDROID_OS /* Reads a key map from a parcel. */ static sp<KeyCharacterMap> readFromParcel(Parcel* parcel); @@ -151,6 +156,9 @@ private: /* The fallback keycode if the key is not handled. */ int32_t fallbackKeyCode; + + /* The replacement keycode if the key has to be replaced outright. */ + int32_t replacementKeyCode; }; struct Key { diff --git a/include/input/Keyboard.h b/include/input/Keyboard.h index 519bb22..d4903e9 100644 --- a/include/input/Keyboard.h +++ b/include/input/Keyboard.h @@ -88,6 +88,13 @@ extern bool isEligibleBuiltInKeyboard(const InputDeviceIdentifier& deviceIdentif extern int32_t updateMetaState(int32_t keyCode, bool down, int32_t oldMetaState); /** + * Normalizes the meta state such that if either the left or right modifier + * meta state bits are set then the result will also include the universal + * bit for that modifier. + */ +extern int32_t normalizeMetaState(int32_t oldMetaState); + +/** * Returns true if a key is a meta key like ALT or CAPS_LOCK. */ extern bool isMetaKey(int32_t keyCode); diff --git a/include/media/openmax/OMX_Core.h b/include/media/openmax/OMX_Core.h index 521c223..f746a69 100644 --- a/include/media/openmax/OMX_Core.h +++ b/include/media/openmax/OMX_Core.h @@ -509,7 +509,7 @@ typedef enum OMX_EVENTTYPE OMX_EventKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */ OMX_EventVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */ - /** Event when tunneled decoder has rendered an output + /** Event when tunneled decoder has rendered an output or reached EOS * nData1 must contain the number of timestamps returned * pEventData must point to an array of the OMX_VIDEO_RENDEREVENTTYPE structs containing the * render-timestamps of each frame. Component may batch rendered timestamps using this event, @@ -518,6 +518,10 @@ typedef enum OMX_EVENTTYPE * * If component is doing frame-rate conversion, it must signal the render time of each * converted frame, and must interpolate media timestamps for in-between frames. + * + * When the component reached EOS, it must signal an EOS timestamp using the same mechanism. + * This is in addition to the timestamp of the last rendered frame, and should follow that + * frame. */ OMX_EventOutputRendered = 0x7F000001, OMX_EventMax = 0x7FFFFFFF diff --git a/include/media/openmax/OMX_VideoExt.h b/include/media/openmax/OMX_VideoExt.h index 34c0405..3971bc5 100644 --- a/include/media/openmax/OMX_VideoExt.h +++ b/include/media/openmax/OMX_VideoExt.h @@ -203,10 +203,17 @@ typedef struct OMX_VIDEO_SLICESEGMENTSTYPE { OMX_BOOL bEnableLoopFilterAcrossSlices; } OMX_VIDEO_SLICESEGMENTSTYPE; -/** Structure to return timestamps of rendered output frames for tunneled components */ +/** Structure to return timestamps of rendered output frames as well as EOS + * for tunneled components. + */ typedef struct OMX_VIDEO_RENDEREVENTTYPE { OMX_S64 nMediaTimeUs; // timestamp of rendered video frame OMX_S64 nSystemTimeNs; // system monotonic time at the time frame was rendered + // Use INT64_MAX for nMediaTimeUs to signal that the EOS + // has been reached. In this case, nSystemTimeNs MUST be + // the system time when the last frame was rendered. + // This MUST be done in addition to returning (and + // following) the render information for the last frame. } OMX_VIDEO_RENDEREVENTTYPE; #ifdef __cplusplus diff --git a/include/ui/DisplayInfo.h b/include/ui/DisplayInfo.h index 799944f..ad73ee7 100644 --- a/include/ui/DisplayInfo.h +++ b/include/ui/DisplayInfo.h @@ -36,6 +36,7 @@ struct DisplayInfo { bool secure; nsecs_t appVsyncOffset; nsecs_t presentationDeadline; + int colorTransform; }; /* Display orientations as defined in Surface.java and ISurfaceComposer.h. */ |