diff frontends/src/tools/xmlui.py @ 1109:0a448c947038

frontends: dialog don't crash anymore is no submit_id is given (submit does nothing in this case)
author Goffi <goffi@goffi.org>
date Wed, 20 Aug 2014 21:16:14 +0200
parents e2e1e27a3680
children f91e7028e2c3
line wrap: on
line diff
--- a/frontends/src/tools/xmlui.py	Wed Aug 20 21:15:04 2014 +0200
+++ b/frontends/src/tools/xmlui.py	Wed Aug 20 21:16:14 2014 +0200
@@ -161,7 +161,10 @@
         self._xmluiClose()
 
     def _xmluiSubmit(self, data):
-        self._xmlui_parent.submit(data)
+        if self._xmlui_parent.submit_id is None:
+            log.debug(_("Nothing to submit"))
+        else:
+            self._xmlui_parent.submit(data)
 
     def _xmluiSetData(self, status, data):
         pass