diff options
| author | Juan Linietsky | 2017-05-20 12:38:03 -0300 |
|---|---|---|
| committer | Juan Linietsky | 2017-05-20 17:05:38 -0300 |
| commit | 5b3709d3096df737b8bb2344446be818b0389bfe (patch) | |
| tree | 649a0989b1494f3c4687d59e503310f4e6bbeb40 /core/os/main_loop.cpp | |
| parent | 93f9a83062dbe74474a4a7928758c5cf5588238e (diff) | |
| download | godot-5b3709d3096df737b8bb2344446be818b0389bfe.tar.gz godot-5b3709d3096df737b8bb2344446be818b0389bfe.tar.zst godot-5b3709d3096df737b8bb2344446be818b0389bfe.zip | |
Removal of InputEvent as built-in Variant type..
this might cause bugs I haven't found yet..
Diffstat (limited to 'core/os/main_loop.cpp')
| -rw-r--r-- | core/os/main_loop.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/core/os/main_loop.cpp b/core/os/main_loop.cpp index 9f8fcccd8..248f5537c 100644 --- a/core/os/main_loop.cpp +++ b/core/os/main_loop.cpp @@ -39,7 +39,7 @@ void MainLoop::_bind_methods() { ClassDB::bind_method(D_METHOD("idle", "delta"), &MainLoop::idle); ClassDB::bind_method(D_METHOD("finish"), &MainLoop::finish); - BIND_VMETHOD(MethodInfo("_input_event", PropertyInfo(Variant::INPUT_EVENT, "ev"))); + BIND_VMETHOD(MethodInfo("_input_event", PropertyInfo(Variant::OBJECT, "ev", PROPERTY_HINT_RESOURCE_TYPE, "InputEvent"))); BIND_VMETHOD(MethodInfo("_input_text", PropertyInfo(Variant::STRING, "text"))); BIND_VMETHOD(MethodInfo("_initialize")); BIND_VMETHOD(MethodInfo("_iteration", PropertyInfo(Variant::REAL, "delta"))); @@ -73,7 +73,7 @@ void MainLoop::input_text(const String &p_text) { get_script_instance()->call("_input_text", p_text); } -void MainLoop::input_event(const InputEvent &p_event) { +void MainLoop::input_event(const Ref<InputEvent> &p_event) { if (get_script_instance()) get_script_instance()->call("_input_event", p_event); |
