From 812660fd1d49bec7129d4c32a8493038a48385d7 Mon Sep 17 00:00:00 2001 From: Dees_Troy Date: Thu, 20 Sep 2012 09:55:17 -0400 Subject: Add and improve OpenRecoveryScript support Improve zip finding in ORS engine Add support for restoring with just a backup name --- gui/action.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'gui') diff --git a/gui/action.cpp b/gui/action.cpp index bbcca23f5..80a582c6c 100644 --- a/gui/action.cpp +++ b/gui/action.cpp @@ -20,6 +20,7 @@ #include #include "../partitions.hpp" #include "../twrp-functions.hpp" +#include "../openrecoveryscript.hpp" #include "../ui.h" #include "../adb_install.h" @@ -1028,10 +1029,9 @@ int GUIAction::doAction(Action action, int isThreaded /* = 0 */) DataManager::SetValue(TW_IS_ENCRYPTED, 0); DataManager::ReadSettingsFile(); -LOGE("TODO: Implement ORS support\n"); - if (0/*check_for_script_file()*/) { + if (OpenRecoveryScript::check_for_script_file()) { ui_print("Processing OpenRecoveryScript file...\n"); - if (/*run_script_file() ==*/ 0) { + if (OpenRecoveryScript::run_script_file() == 0) { usleep(2000000); // Sleep for 2 seconds before rebooting tw_reboot(rb_system); load_theme = 0; -- cgit v1.2.3