|
1 # -*- coding: utf-8 -*- |
|
2 |
|
3 # Copyright (c) 2013 Detlev Offenbach <detlev@die-offenbachs.de> |
|
4 # |
|
5 |
|
6 """ |
|
7 Module implementing a dialog to enter the user data for a minimal hgrc file. |
|
8 """ |
|
9 |
|
10 from __future__ import unicode_literals # __IGNORE_WARNING__ |
|
11 |
|
12 from PyQt4.QtGui import QDialog |
|
13 |
|
14 from .Ui_MercurialUserDataDialog import Ui_MercurialUserDataDialog |
|
15 |
|
16 |
|
17 class MercurialUserDataDialog(QDialog, Ui_MercurialUserDataDialog): |
|
18 """ |
|
19 Class implementing a dialog to enter the user data for a minimal hgrc file. |
|
20 """ |
|
21 def __init__(self, parent=None): |
|
22 """ |
|
23 Constructor |
|
24 |
|
25 @param parent reference to the parent widget (QWidget) |
|
26 """ |
|
27 super(MercurialUserDataDialog, self).__init__(parent) |
|
28 self.setupUi(self) |
|
29 |
|
30 def getData(self): |
|
31 """ |
|
32 Public method to retrieve the data. |
|
33 |
|
34 @return tuple containing the user name and the user email address (string, string) |
|
35 """ |
|
36 return self.usernameEdit.text(), self.emailEdit.text() |