20 |
20 |
21 def __init__(self, excList, ignore, parent=None): |
21 def __init__(self, excList, ignore, parent=None): |
22 """ |
22 """ |
23 Constructor |
23 Constructor |
24 |
24 |
25 @param excList list of exceptions to be edited (list of strings) |
25 @param excList list of exceptions to be edited |
26 @param ignore flag indicating the ignore exceptions mode (boolean) |
26 @type list of str |
27 @param parent the parent widget (QWidget) |
27 @param ignore flag indicating the ignore exceptions mode |
|
28 @type bool |
|
29 @param parent reference to the parent widget |
|
30 @type QWidget |
28 """ |
31 """ |
29 super().__init__(parent) |
32 super().__init__(parent) |
30 self.setupUi(self) |
33 self.setupUi(self) |
31 self.setModal(True) |
34 self.setModal(True) |
32 |
35 |
77 Private slot to handle the textChanged signal of exceptionEdit. |
80 Private slot to handle the textChanged signal of exceptionEdit. |
78 |
81 |
79 This slot sets the enabled status of the add button and sets the forms |
82 This slot sets the enabled status of the add button and sets the forms |
80 default button. |
83 default button. |
81 |
84 |
82 @param txt the text entered into exceptionEdit (string) |
85 @param txt the text entered into exceptionEdit |
|
86 @type str |
83 """ |
87 """ |
84 if not txt: |
88 if not txt: |
85 self.okButton.setDefault(True) |
89 self.okButton.setDefault(True) |
86 self.addButton.setDefault(False) |
90 self.addButton.setDefault(False) |
87 self.addButton.setEnabled(False) |
91 self.addButton.setEnabled(False) |
92 |
96 |
93 def getExceptionsList(self): |
97 def getExceptionsList(self): |
94 """ |
98 """ |
95 Public method to retrieve the list of exception types. |
99 Public method to retrieve the list of exception types. |
96 |
100 |
97 @return list of exception types (list of strings) |
101 @return list of exception types |
|
102 @rtype list of str |
98 """ |
103 """ |
99 excList = [] |
104 excList = [] |
100 for row in range(0, self.exceptionList.count()): |
105 for row in range(0, self.exceptionList.count()): |
101 itm = self.exceptionList.item(row) |
106 itm = self.exceptionList.item(row) |
102 excList.append(itm.text()) |
107 excList.append(itm.text()) |