Cursor move event handler and validator.
(self, event)
| 4245 | |
| 4246 | @_call_with_reparented_event |
| 4247 | def onmove(self, event): |
| 4248 | """Cursor move event handler and validator.""" |
| 4249 | # Method overrides _SelectorWidget.onmove because the polygon selector |
| 4250 | # needs to process the move callback even if there is no button press. |
| 4251 | # _SelectorWidget.onmove include logic to ignore move event if |
| 4252 | # _eventpress is None. |
| 4253 | if self.ignore(event): |
| 4254 | # Hide the cursor when interactive zoom/pan is active |
| 4255 | if not self.canvas.widgetlock.available(self) and self._xys: |
| 4256 | self._xys[-1] = (np.nan, np.nan) |
| 4257 | self._draw_polygon() |
| 4258 | return False |
| 4259 | |
| 4260 | else: |
| 4261 | event = self._clean_event(event) |
| 4262 | self._onmove(event) |
| 4263 | return True |
| 4264 | |
| 4265 | def _onmove(self, event): |
| 4266 | """Cursor move event handler.""" |
nothing calls this directly
no test coverage detected