Commit b27b4dad54672d6c9952cb1f5237aa94c11aacef

Authored by Paulo Henrique Junqueira Amorim
1 parent 0759f72d

ENH: Busy cursor in open project

invesalius/control.py
@@ -176,6 +176,7 @@ class Controller(): @@ -176,6 +176,7 @@ class Controller():
176 176
177 177
178 def OpenProject(self, filepath): 178 def OpenProject(self, filepath):
  179 + ps.Publisher().sendMessage('Begin busy cursor')
179 path = os.path.abspath(filepath) 180 path = os.path.abspath(filepath)
180 181
181 proj = prj.Project() 182 proj = prj.Project()
@@ -187,7 +188,7 @@ class Controller(): @@ -187,7 +188,7 @@ class Controller():
187 188
188 surface = srf.Surface() 189 surface = srf.Surface()
189 surface._set_class_index(proj.last_surface_index) 190 surface._set_class_index(proj.last_surface_index)
190 - 191 +
191 self.LoadProject() 192 self.LoadProject()
192 193
193 session = ses.Session() 194 session = ses.Session()
@@ -310,6 +311,7 @@ class Controller(): @@ -310,6 +311,7 @@ class Controller():
310 ps.Publisher().sendMessage('Show content panel') 311 ps.Publisher().sendMessage('Show content panel')
311 ps.Publisher().sendMessage('Update AUI') 312 ps.Publisher().sendMessage('Update AUI')
312 ps.Publisher().sendMessage('Load slice plane') 313 ps.Publisher().sendMessage('Load slice plane')
  314 + ps.Publisher().sendMessage('End busy cursor')
313 315
314 def CreateAnalyzeProject(self, imagedata): 316 def CreateAnalyzeProject(self, imagedata):
315 proj = prj.Project() 317 proj = prj.Project()
invesalius/gui/frame.py
@@ -211,7 +211,6 @@ class Frame(wx.Frame): @@ -211,7 +211,6 @@ class Frame(wx.Frame):
211 aui_manager.GetPane("Data").Show(1) 211 aui_manager.GetPane("Data").Show(1)
212 aui_manager.GetPane("Tasks").Show(1) 212 aui_manager.GetPane("Tasks").Show(1)
213 aui_manager.Update() 213 aui_manager.Update()
214 - ps.Publisher().sendMessage('End busy cursor')  
215 214
216 def HideContentPanel(self, pubsub_evt): 215 def HideContentPanel(self, pubsub_evt):
217 aui_manager = self.aui_manager 216 aui_manager = self.aui_manager