diff options
author | pnfisher <pnfisher> | 1999-09-20 19:54:11 +0000 |
---|---|---|
committer | pnfisher <pnfisher> | 1999-09-20 19:54:11 +0000 |
commit | 603220309b80483b50312b2827e3c3fd9897045e (patch) | |
tree | 1027d6ea08411e1bb492adedde4327ebf78680e0 /gui.py | |
parent | 35e068eb6c328334daded553e2458a55962439f7 (diff) | |
download | anaconda-603220309b80483b50312b2827e3c3fd9897045e.tar.gz anaconda-603220309b80483b50312b2827e3c3fd9897045e.tar.xz anaconda-603220309b80483b50312b2827e3c3fd9897045e.zip |
No longer call getPrev, and cache all previous states.
Diffstat (limited to 'gui.py')
-rwxr-xr-x | gui.py | 33 |
1 files changed, 20 insertions, 13 deletions
@@ -251,20 +251,23 @@ class InstallControlWindow (Thread): self.stateListIndex = pos def prevClicked (self, *args): - prev = self.currentScreen.getPrev () - if prev: - instantiated = 0 - for x in self.windowList: - if isinstance (x, prev): - self.currentScreen = x - instantiated = 1 - break - if not instantiated: - self.currentScreen = self.instantiateWindow (prev) +# prev = self.currentScreen.getPrev () +# if prev: +# instantiated = 0 +# for x in self.windowList: +# if isinstance (x, prev): +# self.currentScreen = x +# instantiated = 1 +# break +# if not instantiated: +# self.currentScreen = self.instantiateWindow (prev) - else: - self.stateListIndex = self.stateListIndex - 1 - self.currentScreen = self.stateList[self.stateListIndex] +# else: +# self.stateListIndex = self.stateListIndex - 1 +# self.currentScreen = self.stateList[self.stateListIndex] + + self.prevList.pop () + (self.currentScreen, self.stateListIndex) = self.prevList[-1] self.setScreen (self.currentScreen, self.prevClicked) def nextClicked (self, *args): @@ -331,6 +334,10 @@ class InstallControlWindow (Thread): if not self.initialScreenShown: self.initialScreenShown = 1 screen.getICS ().setPrevEnabled (FALSE) + self.prevList = [] + + if not direction == self.prevClicked: + self.prevList.append ((screen, self.stateListIndex)) if self.helpState != self.displayHelp: if self.displayHelp: |