raylib ui: only process mouse events when enabled (#35948)

pull/35843/merge
Shane Smiskol 1 day ago committed by GitHub
parent a79a5e5a16
commit fd32fcd20d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 1
      system/ui/widgets/__init__.py

@ -82,6 +82,7 @@ class Widget(abc.ABC):
ret = self._render(self._rect) ret = self._render(self._rect)
# Keep track of whether mouse down started within the widget's rectangle # Keep track of whether mouse down started within the widget's rectangle
if self.enabled:
for mouse_event in gui_app.mouse_events: for mouse_event in gui_app.mouse_events:
if not self._multi_touch and mouse_event.slot != 0: if not self._multi_touch and mouse_event.slot != 0:
continue continue

Loading…
Cancel
Save