From 88543a0d4848e9069ae1f07eceef34a6441f63c6 Mon Sep 17 00:00:00 2001 From: Papoteur Date: Thu, 5 May 2016 20:11:01 +0200 Subject: Manage the default value for release and destination directory. Doesn't update lists when prefs are canceled. --- mageiaSync/mageiasync.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'mageiaSync') diff --git a/mageiaSync/mageiasync.py b/mageiaSync/mageiasync.py index 617c37e..d5fd11f 100644 --- a/mageiaSync/mageiasync.py +++ b/mageiaSync/mageiasync.py @@ -381,8 +381,7 @@ class IsosViewer(QMainWindow, mageiaSyncUI.Ui_mainWindow): # dialog box to select the destination (local directory) directory = QFileDialog.getExistingDirectory(self, self.tr('Select a directory'),self.destination) if directory != "": - isosSync.destination = directory - self.pd.selectDest.setText(isosSync.destination) + self.pd.selectDest.setText(directory) def selectAllIsos(self): @@ -465,6 +464,7 @@ class IsosViewer(QMainWindow, mageiaSyncUI.Ui_mainWindow): if code==0: for item in list: self.pd.release.addItem(item) + self.pd.release.setCurrentText(self.release) self.pd.password.setText(self.password) self.pd.user.setText(self.user) self.pd.location.setText(self.location) @@ -479,8 +479,8 @@ class IsosViewer(QMainWindow, mageiaSyncUI.Ui_mainWindow): params.setValue("location",self.pd.location.text()) params.setValue("destination",self.pd.selectDest.text()) params.setValue("bwl",str(self.pd.bwl.value())) - self.prefsInit() - self.updateList() + self.prefsInit() + self.updateList() self.pd.close() def about(self): -- cgit v1.2.1