diff options
| author | punto- <ariel@godotengine.org> | 2016-01-12 03:59:19 -0300 |
|---|---|---|
| committer | punto- <ariel@godotengine.org> | 2016-01-12 03:59:19 -0300 |
| commit | 7393e404521350cbb3e69ce87a19ee602ec2a7a4 (patch) | |
| tree | 2c0b71bce28a0bbbbd448084b80bc602183e19b0 /platform/x11 | |
| parent | 8cb013a1bf4728853851d0cbcbc963754632d330 (diff) | |
| parent | c632c13c66db715b816390f0734f2b1839a7ff3e (diff) | |
| download | redot-engine-7393e404521350cbb3e69ce87a19ee602ec2a7a4.tar.gz | |
Merge pull request #3272 from Hinsbart/joy-binding
Add some joystick functions to input. Enables manipulation of mapping…
Diffstat (limited to 'platform/x11')
| -rw-r--r-- | platform/x11/os_x11.cpp | 8 | ||||
| -rw-r--r-- | platform/x11/os_x11.h | 4 |
2 files changed, 12 insertions, 0 deletions
diff --git a/platform/x11/os_x11.cpp b/platform/x11/os_x11.cpp index 437e41eead..82df8dff60 100644 --- a/platform/x11/os_x11.cpp +++ b/platform/x11/os_x11.cpp @@ -1774,6 +1774,14 @@ void OS_X11::run() { main_loop->finish(); } +bool OS_X11::is_joy_known(int p_device) { + return input->is_joy_mapped(p_device); +} + +String OS_X11::get_joy_guid(int p_device) const { + return input->get_joy_guid_remapped(p_device); +} + OS_X11::OS_X11() { #ifdef RTAUDIO_ENABLED diff --git a/platform/x11/os_x11.h b/platform/x11/os_x11.h index a556ba49e3..91dbeac284 100644 --- a/platform/x11/os_x11.h +++ b/platform/x11/os_x11.h @@ -222,6 +222,10 @@ public: virtual void move_window_to_foreground(); virtual void alert(const String& p_alert,const String& p_title="ALERT!"); + + virtual bool is_joy_known(int p_device); + virtual String get_joy_guid(int p_device) const; + void run(); OS_X11(); |
