Browse Source

x11: Support mouse buttons 4 and 5

rdb 4 years ago
parent
commit
210f7aecfb
1 changed files with 2 additions and 0 deletions
  1. 2 0
      panda/src/x11display/x11GraphicsWindow.cxx

+ 2 - 0
panda/src/x11display/x11GraphicsWindow.cxx

@@ -1990,6 +1990,8 @@ get_mouse_button(XButtonEvent &button_event) {
     return MouseButton::wheel_left();
   } else if (index == x_wheel_right_button) {
     return MouseButton::wheel_right();
+  } else if (index >= 8) {
+    return MouseButton::button(index - 5);
   } else {
     return MouseButton::button(index - 1);
   }