Helpviewer/Sync/SyncHostTypePage.py

changeset 1695
7b115f986d48
parent 1626
a77c8ea8582c
child 2302
f29e9405c851
equal deleted inserted replaced
1694:648466a9451b 1695:7b115f986d48
27 @param parent reference to the parent widget (QWidget) 27 @param parent reference to the parent widget (QWidget)
28 """ 28 """
29 super().__init__(parent) 29 super().__init__(parent)
30 self.setupUi(self) 30 self.setupUi(self)
31 31
32 if Preferences.getHelp("SyncType") == 0: 32 if Preferences.getHelp("SyncType") == SyncGlobals.SyncTypeFtp:
33 self.ftpRadioButton.setChecked(True) 33 self.ftpRadioButton.setChecked(True)
34 elif Preferences.getHelp("SyncType") == SyncGlobals.SyncTypeDirectory:
35 self.directoryRadioButton.setChecked(True)
34 else: 36 else:
35 self.noneRadioButton.setChecked(True) 37 self.noneRadioButton.setChecked(True)
36 38
37 def nextId(self): 39 def nextId(self):
38 """ 40 """
40 42
41 @return next wizard page ID (integer) 43 @return next wizard page ID (integer)
42 """ 44 """
43 # save the settings 45 # save the settings
44 if self.ftpRadioButton.isChecked(): 46 if self.ftpRadioButton.isChecked():
45 Preferences.setHelp("SyncType", 0) 47 Preferences.setHelp("SyncType", SyncGlobals.SyncTypeFtp)
46 return SyncGlobals.PageFTPSettings 48 return SyncGlobals.PageFTPSettings
49 elif self.directoryRadioButton.isChecked():
50 Preferences.setHelp("SyncType", SyncGlobals.SyncTypeDirectory)
51 return SyncGlobals.PageDirectorySettings
47 else: 52 else:
48 Preferences.setHelp("SyncType", -1) 53 Preferences.setHelp("SyncType", SyncGlobals.SyncTypeNone)
49 return SyncGlobals.PageCheck 54 return SyncGlobals.PageCheck

eric ide

mercurial