Commit 69812574e92767d2ee8ba8935180ac203c22357a

Authored by Paulo Henrique Junqueira Amorim
2 parents f14f47b9 00603f92

Merge remote-tracking branch 'remote-principal/master'

invesalius/gui/frame.py
@@ -353,7 +353,8 @@ class Frame(wx.Frame): @@ -353,7 +353,8 @@ class Frame(wx.Frame):
353 Close all project data. 353 Close all project data.
354 """ 354 """
355 Publisher.sendMessage('Close Project') 355 Publisher.sendMessage('Close Project')
356 - Publisher.sendMessage('Exit') 356 + if not ses.Session().IsOpen():
  357 + Publisher.sendMessage('Exit')
357 358
358 def OnMenuClick(self, evt): 359 def OnMenuClick(self, evt):
359 """ 360 """
@@ -462,6 +463,8 @@ class Frame(wx.Frame): @@ -462,6 +463,8 @@ class Frame(wx.Frame):
462 """ 463 """
463 path = os.path.join(const.DOC_DIR, 464 path = os.path.join(const.DOC_DIR,
464 "user_guide_pt_BR.pdf") 465 "user_guide_pt_BR.pdf")
  466 + if sys.platform == 'darwin':
  467 + path = r'file://' + path
465 webbrowser.open(path) 468 webbrowser.open(path)
466 469
467 def ShowImportDicomPanel(self): 470 def ShowImportDicomPanel(self):
invesalius/gui/task_slice.py
@@ -800,6 +800,10 @@ class EditionTools(wx.Panel): @@ -800,6 +800,10 @@ class EditionTools(wx.Panel):
800 def OnComboBrushOp(self, evt): 800 def OnComboBrushOp(self, evt):
801 brush_op_id = evt.GetSelection() 801 brush_op_id = evt.GetSelection()
802 Publisher.sendMessage('Set edition operation', brush_op_id) 802 Publisher.sendMessage('Set edition operation', brush_op_id)
  803 + if brush_op_id == const.BRUSH_THRESH:
  804 + self.gradient_thresh.Enable()
  805 + else:
  806 + self.gradient_thresh.Disable()
803 807
804 808
805 class WatershedTool(EditionTools): 809 class WatershedTool(EditionTools):