Browse Source

wxGUI: fix TaskFrame - goutput can be None

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@56216 15284696-431f-4ddb-bdfa-cd5b030d7da7
Martin Landa 12 năm trước cách đây
mục cha
commit
9b6a926989
1 tập tin đã thay đổi với 4 bổ sung3 xóa
  1. 4 3
      gui/wxpython/gui_core/forms.py

+ 4 - 3
gui/wxpython/gui_core/forms.py

@@ -452,11 +452,12 @@ class TaskFrame(wx.Frame):
         self.notebookpanel = CmdPanel(parent = self.panel, giface = self._giface, task = self.task,
                                       frame = self)
         self._gconsole = self.notebookpanel._gconsole
-        self.goutput = self.notebookpanel.goutput
         if self._gconsole:
             self._gconsole.mapCreated.connect(self.OnMapCreated)
-        self.goutput.showNotification.connect(lambda message: self.SetStatusText(message))
-
+        self.goutput = self.notebookpanel.goutput
+        if self.goutput:
+            self.goutput.showNotification.connect(lambda message: self.SetStatusText(message))
+        
         self.notebookpanel.OnUpdateValues = self.updateValuesHook
         guisizer.Add(item = self.notebookpanel, proportion = 1, flag = wx.EXPAND)