51 |
51 |
52 self.localPath = hd |
52 self.localPath = hd |
53 self.networkPath = "localhost/" |
53 self.networkPath = "localhost/" |
54 self.localProtocol = True |
54 self.localProtocol = True |
55 |
55 |
56 self.vcsProjectDirEdit.setText(Utilities.toNativeSeparators( |
56 ipath = Preferences.getMultiProject("Workspace") or \ |
57 Preferences.getMultiProject("Workspace") or |
57 Utilities.getHomeDir() |
58 Utilities.getHomeDir())) |
58 self.__initPaths = [ |
|
59 Utilities.fromNativeSeparators(ipath), |
|
60 Utilities.fromNativeSeparators(ipath) + "/", |
|
61 ] |
|
62 self.vcsProjectDirEdit.setText( |
|
63 Utilities.toNativeSeparators(self.__initPaths[0])) |
|
64 |
|
65 self.resize(self.width(), self.minimumSizeHint().height()) |
|
66 |
|
67 self.buttonBox.button(QDialogButtonBox.Ok).setEnabled(False) |
|
68 |
|
69 @pyqtSlot(str) |
|
70 def on_vcsProjectDirEdit_textChanged(self, txt): |
|
71 """ |
|
72 Private slot to handle a change of the project directory. |
|
73 |
|
74 @param txt name of the project directory (string) |
|
75 """ |
|
76 self.buttonBox.button(QDialogButtonBox.Ok).setEnabled( |
|
77 bool(txt) and |
|
78 Utilities.fromNativeSeparators(txt) not in self.__initPaths) |
59 |
79 |
60 @pyqtSlot() |
80 @pyqtSlot() |
61 def on_vcsUrlButton_clicked(self): |
81 def on_vcsUrlButton_clicked(self): |
62 """ |
82 """ |
63 Private slot to display a selection dialog. |
83 Private slot to display a selection dialog. |