Lines Matching refs:key_code
91 void RecoveryUI::OnKeyDetected(int key_code) { in OnKeyDetected() argument
92 if (key_code == KEY_POWER) { in OnKeyDetected()
94 } else if (key_code == KEY_DOWN || key_code == KEY_VOLUMEDOWN) { in OnKeyDetected()
96 } else if (key_code == KEY_UP || key_code == KEY_VOLUMEUP) { in OnKeyDetected()
98 } else if (key_code == ABS_MT_POSITION_X || key_code == ABS_MT_POSITION_Y) { in OnKeyDetected()
343 void RecoveryUI::ProcessKey(int key_code, int updown) { in ProcessKey() argument
349 key_pressed[key_code] = updown; in ProcessKey()
352 key_last_down = key_code; in ProcessKey()
354 std::thread time_key_thread(&RecoveryUI::TimeKey, this, key_code, key_down_count); in ProcessKey()
357 if (key_last_down == key_code) { in ProcessKey()
367 switch (CheckKey(key_code, long_press)) { in ProcessKey()
382 EnqueueKey(key_code); in ProcessKey()
388 void RecoveryUI::TimeKey(int key_code, int count) { in TimeKey() argument
393 if (key_last_down == key_code && key_down_count == count) { in TimeKey()
397 if (long_press) KeyLongPress(key_code); in TimeKey()
400 void RecoveryUI::EnqueueKey(int key_code) { in EnqueueKey() argument
404 key_queue[key_queue_len++] = key_code; in EnqueueKey()