From 4d88e99937a08432b902204bdd49039c361aaee3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=A5=D0=B8=D1=80=D0=B5=D1=86=D0=BA=D0=B8=D0=B9=20=D0=9C?= =?UTF-8?q?=D0=B8=D1=85=D0=B0=D0=B8=D0=BB?= Date: Tue, 19 Feb 2013 14:08:21 +0400 Subject: [PATCH] Add commonerror --- consolegui/application/mainframe.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/consolegui/application/mainframe.py b/consolegui/application/mainframe.py index cccd7e3..a37fe52 100755 --- a/consolegui/application/mainframe.py +++ b/consolegui/application/mainframe.py @@ -182,7 +182,7 @@ class MainFrame(QtGui.QWidget): self.add_element_label (field, x, y) x += 1 - elif field.element in ['error','pwderror']: + elif field.element in ['error','pwderror','commonerror']: error_lbl = ErrorLabel(self, field.label) error_lbl.setStyleSheet("QLabel {color: red;}") error_lbl.show() @@ -1206,7 +1206,7 @@ class MainFrame(QtGui.QWidget): for res in result[0]: meth_result.append(ReturnedMessage(res.type, res.field, \ res.message, res.expert)) - if res.type in ['error', 'pwderror']: + if res.type in ['error', 'pwderror', 'commonerror']: error = True self.ClientObj.param_objects[self.method_name] \ ['error'] = meth_result @@ -1896,7 +1896,7 @@ class MainFrame(QtGui.QWidget): gb_layout.addWidget(label, x, y, 1, 2) x += 1 - elif field.element in ['error','pwderror']: + elif field.element in ['error','pwderror','commonerror']: error_lbl = ErrorLabel(self, field.label) error_lbl.setStyleSheet("QLabel {color: red;}") error_lbl.show() @@ -2244,7 +2244,7 @@ class MainFrame(QtGui.QWidget): for res in meth_result_temp[0]: meth_result.append(ReturnedMessage(res.type, res.field, \ res.message, res.expert)) - if res.type == 'error' or res.type == 'pwderror': + if res.type in ('error','pwderror','commonerror'): self.ClientObj.param_objects[self.method_name] \ ['error'] = meth_result error = True