src/eric7/Plugins/VcsPlugins/vcsSubversion/SvnSwitchDialog.py

branch
eric7
changeset 9221
bf71ee032bb4
parent 9209
b99e7fd55fd3
child 9653
e67609152c5e
equal deleted inserted replaced
9220:e9e7eca7efee 9221:bf71ee032bb4
14 14
15 class SvnSwitchDialog(QDialog, Ui_SvnSwitchDialog): 15 class SvnSwitchDialog(QDialog, Ui_SvnSwitchDialog):
16 """ 16 """
17 Class implementing a dialog to enter the data for a switch operation. 17 Class implementing a dialog to enter the data for a switch operation.
18 """ 18 """
19
19 def __init__(self, taglist, reposURL, standardLayout, parent=None): 20 def __init__(self, taglist, reposURL, standardLayout, parent=None):
20 """ 21 """
21 Constructor 22 Constructor
22 23
23 @param taglist list of previously entered tags (list of strings) 24 @param taglist list of previously entered tags (list of strings)
24 @param reposURL repository path (string) or None 25 @param reposURL repository path (string) or None
25 @param standardLayout flag indicating the layout of the 26 @param standardLayout flag indicating the layout of the
26 repository (boolean) 27 repository (boolean)
27 @param parent parent widget (QWidget) 28 @param parent parent widget (QWidget)
28 """ 29 """
29 super().__init__(parent) 30 super().__init__(parent)
30 self.setupUi(self) 31 self.setupUi(self)
31 32
32 self.tagCombo.clear() 33 self.tagCombo.clear()
33 self.tagCombo.addItems(sorted(taglist)) 34 self.tagCombo.addItems(sorted(taglist))
34 35
35 if reposURL is not None and reposURL != "": 36 if reposURL is not None and reposURL != "":
36 self.tagCombo.setEditText(reposURL) 37 self.tagCombo.setEditText(reposURL)
37 38
38 if not standardLayout: 39 if not standardLayout:
39 self.TagTypeGroup.setEnabled(False) 40 self.TagTypeGroup.setEnabled(False)
40 41
41 msh = self.minimumSizeHint() 42 msh = self.minimumSizeHint()
42 self.resize(max(self.width(), msh.width()), msh.height()) 43 self.resize(max(self.width(), msh.width()), msh.height())
43 44
44 def getParameters(self): 45 def getParameters(self):
45 """ 46 """
46 Public method to retrieve the tag data. 47 Public method to retrieve the tag data.
47 48
48 @return tuple of string and int (tag, tag type) 49 @return tuple of string and int (tag, tag type)
49 """ 50 """
50 tag = self.tagCombo.currentText() 51 tag = self.tagCombo.currentText()
51 tagType = 0 52 tagType = 0
52 if self.regularButton.isChecked(): 53 if self.regularButton.isChecked():

eric ide

mercurial