summaryrefslogtreecommitdiffstats
path: root/gui/action.cpp
diff options
context:
space:
mode:
authorEthan Yonker <dees_troy@teamw.in>2016-09-19 20:50:25 +0200
committerDees Troy <dees_troy@teamw.in>2016-11-30 16:27:07 +0100
commite080c1f8fbb4e4d7d5d6a911f804be13344fda26 (patch)
treea4791391a9d76df1c09aeade7d54ac664f275cbc /gui/action.cpp
parentUpdate to android-7.1 (diff)
downloadandroid_bootable_recovery-e080c1f8fbb4e4d7d5d6a911f804be13344fda26.tar
android_bootable_recovery-e080c1f8fbb4e4d7d5d6a911f804be13344fda26.tar.gz
android_bootable_recovery-e080c1f8fbb4e4d7d5d6a911f804be13344fda26.tar.bz2
android_bootable_recovery-e080c1f8fbb4e4d7d5d6a911f804be13344fda26.tar.lz
android_bootable_recovery-e080c1f8fbb4e4d7d5d6a911f804be13344fda26.tar.xz
android_bootable_recovery-e080c1f8fbb4e4d7d5d6a911f804be13344fda26.tar.zst
android_bootable_recovery-e080c1f8fbb4e4d7d5d6a911f804be13344fda26.zip
Diffstat (limited to 'gui/action.cpp')
-rw-r--r--gui/action.cpp9
1 files changed, 1 insertions, 8 deletions
diff --git a/gui/action.cpp b/gui/action.cpp
index a917d2be3..a96e15ac9 100644
--- a/gui/action.cpp
+++ b/gui/action.cpp
@@ -1737,18 +1737,11 @@ int GUIAction::flashimage(std::string arg __unused)
{
int op_status = 0;
- PartitionSettings part_settings;
operation_start("Flash Image");
string path, filename;
DataManager::GetValue("tw_zip_location", path);
DataManager::GetValue("tw_file", filename);
- part_settings.Backup_Folder = path + "/" + filename;
- unsigned long long total_bytes = TWFunc::Get_File_Size(part_settings.Backup_Folder);
- ProgressTracking progress(total_bytes);
- part_settings.progress = &progress;
- part_settings.adbbackup = false;
- part_settings.PM_Method = PM_RESTORE;
- if (PartitionManager.Flash_Image(&part_settings))
+ if (PartitionManager.Flash_Image(path, filename))
op_status = 0; // success
else
op_status = 1; // fail