Commit a019f32675664022964d5ae4726a7b8a8553060e
1 parent
14fee751
Exists in
master
and in
6 other branches
ENH: Hide default cursor in the editor mode
Showing
1 changed file
with
6 additions
and
1 deletions
Show diff stats
invesalius/data/viewer_slice.py
@@ -638,6 +638,12 @@ class Viewer(wx.Panel): | @@ -638,6 +638,12 @@ class Viewer(wx.Panel): | ||
638 | #slice_data.cursor.Show() | 638 | #slice_data.cursor.Show() |
639 | 639 | ||
640 | self.pick.Pick(mouse_x, mouse_y, 0, render) | 640 | self.pick.Pick(mouse_x, mouse_y, 0, render) |
641 | + | ||
642 | + if (self.pick.GetProp()): | ||
643 | + self.interactor.SetCursor(wx.StockCursor(wx.CURSOR_BLANK)) | ||
644 | + else: | ||
645 | + self.interactor.SetCursor(wx.StockCursor(wx.CURSOR_DEFAULT)) | ||
646 | + | ||
641 | coord = self.get_coordinate_cursor() | 647 | coord = self.get_coordinate_cursor() |
642 | slice_data.cursor.SetPosition(coord) | 648 | slice_data.cursor.SetPosition(coord) |
643 | slice_data.cursor.SetEditionPosition( | 649 | slice_data.cursor.SetEditionPosition( |
@@ -830,7 +836,6 @@ class Viewer(wx.Panel): | @@ -830,7 +836,6 @@ class Viewer(wx.Panel): | ||
830 | ps.Publisher().subscribe(self.OnHideText, | 836 | ps.Publisher().subscribe(self.OnHideText, |
831 | 'Hide text actors on viewers') | 837 | 'Hide text actors on viewers') |
832 | ps.Publisher().subscribe(self.OnExportPicture,'Export picture to file') | 838 | ps.Publisher().subscribe(self.OnExportPicture,'Export picture to file') |
833 | - | ||
834 | 839 | ||
835 | 840 | ||
836 | def OnExportPicture(self, pubsub_evt): | 841 | def OnExportPicture(self, pubsub_evt): |