Expose Viewport.gui_accept_event()
#9853
timothyqiu
started this conversation in
GUI
Replies: 1 comment 1 reply
-
Looking at the source code, |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Control.accept_event()
callsViewport._gui_accept_event()
, this is handy for consuming the event inside a Control's script.However, one would also want to
accept_event()
in a Control'sgui_input
signal. The signal is not necessarily handled by a script extending Control.So the only way to consume the event in the signal handler is to get a Control node and call its
accept_event()
method.I suggest exposing
Viewport._gui_accept_event()
to scripting. We've already exposedViewport.gui_release_focus()
for the same reason.Beta Was this translation helpful? Give feedback.
All reactions