b/12068020 add nonce to InputDeviceDescriptor. Do not merge

This is a cherry-pick of https://googleplex-android-review.git.corp.google.com/#/c/401795/

Adds a nonce field to allow generation of unique descriptors for
input devices.

Change-Id: Ie82bfb728bea95792b3b138dd3974f8b0aff63e0
This commit is contained in:
RoboErik 2013-12-19 11:54:29 -08:00
parent 9b04f860f2
commit d9e113f0e0
1 changed files with 5 additions and 0 deletions

View File

@ -46,6 +46,11 @@ struct InputDeviceIdentifier {
// Ideally, the way this value is computed should not change between Android releases
// because that would invalidate persistent settings that rely on it.
String8 descriptor;
// A value added to uniquely identify a device in the absence of a unique id. This
// is intended to be a minimum way to distinguish from other active devices and may
// reuse values that are not associated with an input anymore.
uint16_t nonce;
};
/*