Add a stub recovery UI.
This allows recovery to work on devices without screen.
The stub recovery UI does nothing except print to stdout.
Test: write 'recovery\n--wipe_data\n--reason=wipe_data_from_ota\n'
to misc and boot to recovery on a device without screen.
Bug: 33175036
Change-Id: Icde698aa2e2e29f4b3d0532dfd3c6a939ac2bc63
This commit is contained in:
@@ -80,12 +80,13 @@ static void* InputThreadLoop(void*) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
void RecoveryUI::Init() {
|
||||
bool RecoveryUI::Init() {
|
||||
ev_init(InputCallback, this);
|
||||
|
||||
ev_iterate_available_keys(std::bind(&RecoveryUI::OnKeyDetected, this, std::placeholders::_1));
|
||||
|
||||
pthread_create(&input_thread_, nullptr, InputThreadLoop, nullptr);
|
||||
return true;
|
||||
}
|
||||
|
||||
int RecoveryUI::OnInputEvent(int fd, uint32_t epevents) {
|
||||
|
||||
Reference in New Issue
Block a user