From 02abde50851f66196c74d215150014f1378cb853 Mon Sep 17 00:00:00 2001 From: Doug Zongker Date: Tue, 1 Apr 2014 09:45:24 -0700 Subject: remove DefaultDevice's UI subclass RecoveryUI (which is the superclass of ScreenRecoveryUI), provides a basic CheckKey method that is useful for devices that have KEY_POWER, KEY_VOLUMEUP, and KEY_VOLUMEDOWN. Stop overriding it with a less featureful method; with this no recovery UI customization is needed for most handheld devices (phones, tablets, etc.). Change-Id: I7d57cfaaef79afea8af4fc3dbc570afc61aeb5bc --- ui.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'ui.cpp') diff --git a/ui.cpp b/ui.cpp index 67a2500..091012f 100644 --- a/ui.cpp +++ b/ui.cpp @@ -276,7 +276,7 @@ void RecoveryUI::FlushKeys() { // - Press power seven times in a row to reboot. // - Alternate vol-up and vol-down seven times to mount /system. RecoveryUI::KeyAction RecoveryUI::CheckKey(int key) { - if (IsKeyPressed(KEY_POWER) && key == KEY_VOLUMEUP) { + if ((IsKeyPressed(KEY_POWER) && key == KEY_VOLUMEUP) || key == KEY_HOME) { return TOGGLE; } -- cgit v1.1