16 |
16 |
17 class AuthenticationDialog(QDialog, Ui_AuthenticationDialog): |
17 class AuthenticationDialog(QDialog, Ui_AuthenticationDialog): |
18 """ |
18 """ |
19 Class implementing the authentication dialog for the help browser. |
19 Class implementing the authentication dialog for the help browser. |
20 """ |
20 """ |
21 def __init__(self, info, username, showSave=False, saveIt=False, parent=None): |
21 def __init__(self, info, username, showSave=False, saveIt=False, |
|
22 parent=None): |
22 """ |
23 """ |
23 Constructor |
24 Constructor |
24 |
25 |
25 @param info information to be shown (string) |
26 @param info information to be shown (string) |
26 @param username username as supplied by subversion (string) |
27 @param username username as supplied by subversion (string) |
27 @param showSave flag to indicate to show the save checkbox (boolean) |
28 @param showSave flag to indicate to show the save checkbox (boolean) |
28 @param saveIt flag indicating the value for the save checkbox (boolean) |
29 @param saveIt flag indicating the value for the save checkbox (boolean) |
|
30 @param parent reference to the parent widget (QWidget) |
29 """ |
31 """ |
30 super(AuthenticationDialog, self).__init__(parent) |
32 super(AuthenticationDialog, self).__init__(parent) |
31 self.setupUi(self) |
33 self.setupUi(self) |
32 |
34 |
33 self.infoLabel.setText(info) |
35 self.infoLabel.setText(info) |
35 self.saveCheckBox.setVisible(showSave) |
37 self.saveCheckBox.setVisible(showSave) |
36 self.saveCheckBox.setChecked(saveIt) |
38 self.saveCheckBox.setChecked(saveIt) |
37 |
39 |
38 self.iconLabel.setText("") |
40 self.iconLabel.setText("") |
39 self.iconLabel.setPixmap( |
41 self.iconLabel.setPixmap( |
40 self.style().standardIcon(QStyle.SP_MessageBoxQuestion).pixmap(32, 32)) |
42 self.style().standardIcon(QStyle.SP_MessageBoxQuestion).pixmap( |
|
43 32, 32)) |
41 |
44 |
42 def setData(self, username, password): |
45 def setData(self, username, password): |
43 """ |
46 """ |
44 Public method to set the login data. |
47 Public method to set the login data. |
45 |
48 |