diff options
author | Doug Zongker <dougz@android.com> | 2013-09-04 13:44:38 -0700 |
---|---|---|
committer | Doug Zongker <dougz@android.com> | 2013-09-04 15:02:29 -0700 |
commit | 9e805d6ca0101f6bfc458e5c1e9b48fecb495a72 (patch) | |
tree | 245f36ae41f95e64faca59401ff6ccc0394d9c76 /ui.h | |
parent | e428f624653bd0b6f66e8d4c95f54f6e90fc6218 (diff) | |
download | bootable_recovery-9e805d6ca0101f6bfc458e5c1e9b48fecb495a72.zip bootable_recovery-9e805d6ca0101f6bfc458e5c1e9b48fecb495a72.tar.gz bootable_recovery-9e805d6ca0101f6bfc458e5c1e9b48fecb495a72.tar.bz2 |
allow CheckKey to request mounting /system
Also provide a default implementation of CheckKey that's reasonable
for many devices (those that have power and volume keys).
Change-Id: Icf6c7746ebd866152d402059dbd27fd16bd51ff8
Diffstat (limited to 'ui.h')
-rw-r--r-- | ui.h | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -77,7 +77,7 @@ class RecoveryUI { // Return value indicates whether an immediate operation should be // triggered (toggling the display, rebooting the device), or if // the key should be enqueued for use by the main thread. - enum KeyAction { ENQUEUE, TOGGLE, REBOOT, IGNORE }; + enum KeyAction { ENQUEUE, TOGGLE, REBOOT, IGNORE, MOUNT_SYSTEM }; virtual KeyAction CheckKey(int key); // Called immediately before each call to CheckKey(), tell you if @@ -121,6 +121,10 @@ private: int key_down_count; // under key_queue_mutex int rel_sum; + int consecutive_power_keys; + int consecutive_alternate_keys; + int last_key; + typedef struct { RecoveryUI* ui; int key_code; |