Browse Source

Fixed a bug on linux where the mouse pointer would jump around while dragging sliders

tags/2021-05-28
hogliux 8 years ago
parent
commit
b198fa4c2c
1 changed files with 10 additions and 5 deletions
  1. +10
    -5
      modules/juce_gui_basics/native/juce_linux_X11_Windowing.cpp

+ 10
- 5
modules/juce_gui_basics/native/juce_linux_X11_Windowing.cpp View File

@@ -2268,13 +2268,18 @@ public:
{
updateKeyModifiers ((int) movedEvent.state);
lastMousePos = Point<int> (movedEvent.x_root, movedEvent.y_root);
if ((movedEvent.state & (Button1MotionMask | Button2MotionMask
| Button3MotionMask | Button4MotionMask
| Button5MotionMask)) != 0)
{
lastMousePos = Point<int> (movedEvent.x_root, movedEvent.y_root);
if (dragState->dragging)
handleExternalDragMotionNotify();
if (dragState->dragging)
handleExternalDragMotionNotify();
handleMouseEvent (MouseInputSource::InputSourceType::mouse, getMousePos (movedEvent), currentModifiers,
MouseInputSource::invalidPressure, MouseInputSource::invalidOrientation, getEventTime (movedEvent));
handleMouseEvent (MouseInputSource::InputSourceType::mouse, getMousePos (movedEvent), currentModifiers,
MouseInputSource::invalidPressure, MouseInputSource::invalidOrientation, getEventTime (movedEvent));
}
}
void handleEnterNotifyEvent (const XEnterWindowEvent& enterEvent)


Loading…
Cancel
Save