summaryrefslogtreecommitdiffstats
path: root/scene/main/node.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'scene/main/node.cpp')
-rw-r--r--scene/main/node.cpp16
1 files changed, 12 insertions, 4 deletions
diff --git a/scene/main/node.cpp b/scene/main/node.cpp
index 2082736653..b947526e96 100644
--- a/scene/main/node.cpp
+++ b/scene/main/node.cpp
@@ -2791,7 +2791,9 @@ void Node::request_ready() {
}
void Node::_call_input(const Ref<InputEvent> &p_event) {
- GDVIRTUAL_CALL(_input, p_event);
+ if (p_event->get_device() != InputEvent::DEVICE_ID_INTERNAL) {
+ GDVIRTUAL_CALL(_input, p_event);
+ }
if (!is_inside_tree() || !get_viewport() || get_viewport()->is_input_handled()) {
return;
}
@@ -2799,7 +2801,9 @@ void Node::_call_input(const Ref<InputEvent> &p_event) {
}
void Node::_call_shortcut_input(const Ref<InputEvent> &p_event) {
- GDVIRTUAL_CALL(_shortcut_input, p_event);
+ if (p_event->get_device() != InputEvent::DEVICE_ID_INTERNAL) {
+ GDVIRTUAL_CALL(_shortcut_input, p_event);
+ }
if (!is_inside_tree() || !get_viewport() || get_viewport()->is_input_handled()) {
return;
}
@@ -2807,7 +2811,9 @@ void Node::_call_shortcut_input(const Ref<InputEvent> &p_event) {
}
void Node::_call_unhandled_input(const Ref<InputEvent> &p_event) {
- GDVIRTUAL_CALL(_unhandled_input, p_event);
+ if (p_event->get_device() != InputEvent::DEVICE_ID_INTERNAL) {
+ GDVIRTUAL_CALL(_unhandled_input, p_event);
+ }
if (!is_inside_tree() || !get_viewport() || get_viewport()->is_input_handled()) {
return;
}
@@ -2815,7 +2821,9 @@ void Node::_call_unhandled_input(const Ref<InputEvent> &p_event) {
}
void Node::_call_unhandled_key_input(const Ref<InputEvent> &p_event) {
- GDVIRTUAL_CALL(_unhandled_key_input, p_event);
+ if (p_event->get_device() != InputEvent::DEVICE_ID_INTERNAL) {
+ GDVIRTUAL_CALL(_unhandled_key_input, p_event);
+ }
if (!is_inside_tree() || !get_viewport() || get_viewport()->is_input_handled()) {
return;
}