diff options
author | Rémi Verschelde <rverschelde@gmail.com> | 2018-05-02 10:47:49 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-05-02 10:47:49 +0200 |
commit | 18c28c159d12c9d3227c2199998b271f7c5e5998 (patch) | |
tree | ba3591964e6dea9d06daa5aaea399fa53a8c2c8e /core/os | |
parent | 04a4270a3485bcc4bd1ce8f7095fe9ea36bc5518 (diff) | |
parent | de9d40a9537bafa613dc54f2200b7509ad6fa9e3 (diff) |
Merge pull request #17196 from RandomShaper/improve-gui-touch
Implement universal translation of touch to mouse (3.1)
Diffstat (limited to 'core/os')
-rw-r--r-- | core/os/input.h | 3 | ||||
-rw-r--r-- | core/os/os.cpp | 2 |
2 files changed, 3 insertions, 2 deletions
diff --git a/core/os/input.h b/core/os/input.h index 027147b987..001871c5dc 100644 --- a/core/os/input.h +++ b/core/os/input.h @@ -118,7 +118,8 @@ public: void get_argument_options(const StringName &p_function, int p_idx, List<String> *r_options) const; - virtual bool is_emulating_touchscreen() const = 0; + virtual bool is_emulating_touch_from_mouse() const = 0; + virtual bool is_emulating_mouse_from_touch() const = 0; virtual CursorShape get_default_cursor_shape() = 0; virtual void set_default_cursor_shape(CursorShape p_shape) = 0; diff --git a/core/os/os.cpp b/core/os/os.cpp index 618a4bbac3..854d554b10 100644 --- a/core/os/os.cpp +++ b/core/os/os.cpp @@ -411,7 +411,7 @@ Error OS::set_cwd(const String &p_cwd) { bool OS::has_touchscreen_ui_hint() const { //return false; - return Input::get_singleton() && Input::get_singleton()->is_emulating_touchscreen(); + return Input::get_singleton() && Input::get_singleton()->is_emulating_touch_from_mouse(); } int OS::get_free_static_memory() const { |