summaryrefslogtreecommitdiffstats
path: root/gui/pages.cpp
diff options
context:
space:
mode:
authorthat <github@that.at>2016-01-24 21:59:00 +0100
committerz31s1g <z31s1g@googlemail.com>2016-01-25 19:25:34 +0100
commit235c648a6828bdd8201e1151b7e2815a4daf1201 (patch)
treeea3d840730107fdec717a32d496e3b085cab1ce0 /gui/pages.cpp
parentUpdate mStartPage to make language selection work on other pages (diff)
downloadandroid_bootable_recovery-235c648a6828bdd8201e1151b7e2815a4daf1201.tar
android_bootable_recovery-235c648a6828bdd8201e1151b7e2815a4daf1201.tar.gz
android_bootable_recovery-235c648a6828bdd8201e1151b7e2815a4daf1201.tar.bz2
android_bootable_recovery-235c648a6828bdd8201e1151b7e2815a4daf1201.tar.lz
android_bootable_recovery-235c648a6828bdd8201e1151b7e2815a4daf1201.tar.xz
android_bootable_recovery-235c648a6828bdd8201e1151b7e2815a4daf1201.tar.zst
android_bootable_recovery-235c648a6828bdd8201e1151b7e2815a4daf1201.zip
Diffstat (limited to '')
-rw-r--r--gui/pages.cpp9
1 files changed, 2 insertions, 7 deletions
diff --git a/gui/pages.cpp b/gui/pages.cpp
index def262998..c45566232 100644
--- a/gui/pages.cpp
+++ b/gui/pages.cpp
@@ -64,7 +64,6 @@ extern std::vector<std::string> gConsoleColor;
std::map<std::string, PageSet*> PageManager::mPageSets;
PageSet* PageManager::mCurrentSet;
-PageSet* PageManager::mBaseSet = NULL;
MouseCursor *PageManager::mMouseCursor = NULL;
HardwareKeyboard *PageManager::mHardwareKeyboard = NULL;
bool PageManager::mReloadTheme = false;
@@ -1421,10 +1420,6 @@ int PageManager::LoadPackage(std::string name, std::string package, std::string
LOGERR("Package %s failed to load.\n", name.c_str());
}
- // The first successful package we loaded is the base
- if (mBaseSet == NULL)
- mBaseSet = mCurrentSet;
-
mCurrentSet = pageSet;
if (pZip) {
@@ -1500,8 +1495,6 @@ int PageManager::ReloadPackage(std::string name, std::string package)
}
if (mCurrentSet == set)
SelectPackage(name);
- if (mBaseSet == set)
- mBaseSet = mCurrentSet;
delete set;
GUIConsole::Translate_Now();
return 0;
@@ -1518,6 +1511,8 @@ void PageManager::ReleasePackage(std::string name)
PageSet* set = (*iter).second;
mPageSets.erase(iter);
delete set;
+ if (set == mCurrentSet)
+ mCurrentSet = NULL;
return;
}