Commit 80c49b32491b74ca704c4d2f01f9678c2a18f320
1 parent
87049fe9
Exists in
master
and in
26 other branches
Changing mouse cursor when above a measure mark
Showing
1 changed file
with
7 additions
and
1 deletions
Show diff stats
invesalius/data/styles.py
... | ... | @@ -407,14 +407,20 @@ class LinearMeasureInteractorStyle(DefaultInteractorStyle): |
407 | 407 | self.selected = None |
408 | 408 | |
409 | 409 | def OnMoveMeasurePoint(self, obj, evt): |
410 | + x, y, z = self._get_pos_clicked() | |
410 | 411 | if self.selected: |
411 | 412 | n, m, mr = self.selected |
412 | - x, y, z = self._get_pos_clicked() | |
413 | 413 | idx = self.measures._list_measures.index((m, mr)) |
414 | 414 | Publisher.sendMessage('Change measurement point position', (idx, n, (x, y, z))) |
415 | 415 | |
416 | 416 | Publisher.sendMessage('Reload actual slice %s' % self.orientation) |
417 | 417 | |
418 | + else: | |
419 | + if self._verify_clicked(x, y, z): | |
420 | + self.viewer.interactor.SetCursor(wx.StockCursor(wx.CURSOR_HAND)) | |
421 | + else: | |
422 | + self.viewer.interactor.SetCursor(wx.StockCursor(wx.CURSOR_DEFAULT)) | |
423 | + | |
418 | 424 | def CleanUp(self): |
419 | 425 | self.picker.PickFromListOff() |
420 | 426 | Publisher.sendMessage("Remove incomplete measurements") | ... | ... |