GTK: make Space Navigator actually work.

Before this commit, no events would actually be received.
This commit is contained in:
whitequark 2016-06-27 10:35:17 +00:00
parent 51f3d7e438
commit 61904280a3
2 changed files with 12 additions and 0 deletions

View File

@ -14,6 +14,7 @@ Bug fixes:
* Unbreak the "Show degrees of freedom" command.
* Three.js: correctly respond to controls when browser zoom is used.
* OS X: do not completely hide main window when defocused.
* GTK: unbreak 3Dconnexion support.
2.1
---

View File

@ -1578,6 +1578,17 @@ int main(int argc, char** argv) {
TW->show_all();
GW->show_all();
#ifdef HAVE_SPACEWARE
#ifdef HAVE_GTK3
// We don't care if it can't be opened; just continue without.
spnav_x11_open(gdk_x11_get_default_xdisplay(),
gdk_x11_window_get_xid(GW->get_window()->gobj()));
#else
spnav_x11_open(gdk_x11_get_default_xdisplay(),
GDK_WINDOW_XWINDOW(GW->get_window()->gobj()));
#endif
#endif
SS.Init();
if(argc >= 2) {