Lines Matching refs:ui
129 static void FinishRecovery(RecoveryUI* ui) { in FinishRecovery() argument
130 std::string locale = ui->GetLocale(); in FinishRecovery()
270 static void run_graphics_test(RecoveryUI* ui) { in run_graphics_test() argument
272 ui->ShowText(false); in run_graphics_test()
274 ui->SetProgressType(RecoveryUI::INDETERMINATE); in run_graphics_test()
275 ui->SetBackground(RecoveryUI::INSTALLING_UPDATE); in run_graphics_test()
278 ui->SetBackground(RecoveryUI::ERROR); in run_graphics_test()
281 ui->SetBackground(RecoveryUI::NO_COMMAND); in run_graphics_test()
284 ui->SetBackground(RecoveryUI::ERASING); in run_graphics_test()
288 ui->SetStage(1, 3); in run_graphics_test()
289 ui->SetBackground(RecoveryUI::INSTALLING_UPDATE); in run_graphics_test()
291 ui->SetStage(2, 3); in run_graphics_test()
292 ui->SetBackground(RecoveryUI::INSTALLING_UPDATE); in run_graphics_test()
294 ui->SetStage(3, 3); in run_graphics_test()
295 ui->SetBackground(RecoveryUI::INSTALLING_UPDATE); in run_graphics_test()
298 ui->SetStage(-1, -1); in run_graphics_test()
299 ui->SetBackground(RecoveryUI::INSTALLING_UPDATE); in run_graphics_test()
301 ui->SetProgressType(RecoveryUI::DETERMINATE); in run_graphics_test()
302 ui->ShowProgress(1.0, 10.0); in run_graphics_test()
306 ui->SetProgress(fraction); in run_graphics_test()
310 ui->ShowText(true); in run_graphics_test()
361 auto ui = device->GetUI(); in PromptAndWait() local
364 FinishRecovery(ui); in PromptAndWait()
371 ui->SetBackground(RecoveryUI::NO_COMMAND); in PromptAndWait()
376 ui->SetBackground(RecoveryUI::ERROR); in PromptAndWait()
385 ui->SetProgressType(RecoveryUI::EMPTY); in PromptAndWait()
393 size_t chosen_item = ui->ShowMenu( in PromptAndWait()
423 if (!ui->IsTextVisible()) { in PromptAndWait()
438 if (ui->IsTextVisible()) { in PromptAndWait()
453 WipeCache(ui, ui->IsTextVisible() ? confirm_func : nullptr); in PromptAndWait()
454 if (!ui->IsTextVisible()) return Device::NO_ACTION; in PromptAndWait()
470 ui->ShowText(false); in PromptAndWait()
479 ui->Print("\nInstall from %s completed with status %d.\n", adb ? "ADB" : "SD card", status); in PromptAndWait()
486 if (!ui->IsTextVisible()) { in PromptAndWait()
490 ui->SetBackground(RecoveryUI::ERROR); in PromptAndWait()
491 ui->Print("Installation aborted.\n"); in PromptAndWait()
502 run_graphics_test(ui); in PromptAndWait()
506 ScreenRecoveryUI* screen_ui = static_cast<ScreenRecoveryUI*>(ui); in PromptAndWait()
514 ui->Print("Virtual A/B: snapshot partitions creation failed.\n"); in PromptAndWait()
518 ui->Print("Mounted /system.\n"); in PromptAndWait()
692 auto ui = device->GetUI(); in start_recovery() local
696 ui->SetSystemUpdateText(security_update); in start_recovery()
701 ui->SetStage(st_cur, st_max); in start_recovery()
707 ui->SetTitle(title_lines); in start_recovery()
709 ui->ResetKeyInterruptStatus(); in start_recovery()
732 ui->Print("battery capacity is not enough for installing package: %d%% needed\n", in start_recovery()
739 ui->Print("bootreason is in the blocklist; skip OTA installation\n"); in start_recovery()
761 status = InstallWithFuseFromPath(update_package, ui); in start_recovery()
764 std::bind(&RecoveryUI::SetProgress, ui, std::placeholders::_1)); in start_recovery()
767 retry_count, ui); in start_recovery()
774 status = InstallWithFuseFromPath(update_package, ui); in start_recovery()
777 ui->Print("Installation aborted.\n"); in start_recovery()
787 ui->Print("Retry attempt %d\n", retry_count); in start_recovery()
796 ui->ShowText(true); in start_recovery()
811 ui->ShowText(true); in start_recovery()
812 ui->SetBackground(RecoveryUI::ERROR); in start_recovery()
815 ui->ShowText(false); in start_recovery()
819 if (!WipeCache(ui, nullptr)) { in start_recovery()
833 ui->ShowText(true); in start_recovery()
836 ui->Print("\nInstall from ADB complete (status: %d).\n", status); in start_recovery()
839 ui->Print("Rebooting automatically.\n"); in start_recovery()
844 ui->Print("\nInstall from ADB complete (status: %d).\n", status); in start_recovery()
850 ui->ShowText(true); in start_recovery()
853 ui->SetBackground(RecoveryUI::NO_COMMAND); in start_recovery()
857 ui->SetBackground(RecoveryUI::ERROR); in start_recovery()
858 if (!ui->IsTextVisible()) { in start_recovery()
873 if (status == INSTALL_NONE || ui->IsTextVisible()) { in start_recovery()
882 FinishRecovery(ui); in start_recovery()