[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[PATCH f13-branch master] Retain user's UTC checkbox setting (#591125)



This sets the initial UTC setting when anaconda.timezone is initialized
instead of every time the timezone UI is entered.
---
 anaconda           |    9 ++++++++-
 iw/timezone_gui.py |    4 ----
 2 files changed, 8 insertions(+), 5 deletions(-)

diff --git a/anaconda b/anaconda
index 0f54d65..d16abd8 100755
--- a/anaconda
+++ b/anaconda
@@ -588,8 +588,15 @@ class Anaconda(object):
     def timezone(self):
         if not self._timezone:
             import timezone
+            from bootloader import hasWindows
+
             self._timezone = timezone.Timezone()
-            self._timezone.setTimezoneInfo(self.instLanguage.getDefaultTimeZone(self.rootPath))
+            tz = self.instLanguage.getDefaultTimeZone(self.rootPath)
+            if not self.ksdata:
+                utc = not hasWindows(anaconda.bootloader)
+            else:
+                utc = 0
+            self._timezone.setTimezoneInfo(tz, utc)
 
         return self._timezone
 
diff --git a/iw/timezone_gui.py b/iw/timezone_gui.py
index c5ecd88..1a821b7 100644
--- a/iw/timezone_gui.py
+++ b/iw/timezone_gui.py
@@ -30,7 +30,6 @@ import sys
 from timezone_map_gui import TimezoneMap, Enum
 from iw_gui import *
 from booty.bootloaderInfo import dosFilesystems
-from bootloader import hasWindows
 
 from constants import *
 import gettext
@@ -104,9 +103,6 @@ class TimezoneWindow(InstallWindow):
         self.tz.setCurrent(self.zonetab.findEntryByTZ(self.default))
         self.utcCheckbox.set_active(asUTC)
 
-        if not anaconda.ksdata:
-            self.utcCheckbox.set_active(not hasWindows(anaconda.bootloader))
-
         self.notebook.remove(self.vbox)
         return self.vbox
 
-- 
1.6.6.1


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]