fix: XWindowsScreen: stop centering panned screens on client when leaving screen
panned screens still needs `xtestIsXineramaUnaware` option enabled. this change forcefully uses XTest only when leaving useful examples: * double 1 FullHD screen (main output) by: `xrandr --fb 3840x1080 --output DP-1 --panning 3840x1080+0+0/3840x1000+0+80`, leaving top 80 pixels for moving mouse out without actual panning * dedicate right half of framebuffer to FullHD TV (second output): `xrandr --fb 3840x1080 --output HDMI-0 --panning 1920x1080+1920+0`
This commit is contained in:
committed by
Nick Bolton
parent
bf5b0de6ee
commit
9f8c45b449
@ -328,7 +328,10 @@ void XWindowsScreen::leave()
|
||||
if (m_isPrimary) {
|
||||
warpCursor(m_xCenter, m_yCenter);
|
||||
} else {
|
||||
fakeMouseMove(m_xCenter, m_yCenter);
|
||||
// WARN: not using fakeMouseMove() intentionally
|
||||
// forcibly ignore any xinerama quirks, so that `xrandr --panning ... --tracking ...` works
|
||||
XTestFakeMotionEvent(m_display, DefaultScreen(m_display), m_xCenter, m_yCenter, CurrentTime);
|
||||
XFlush(m_display);
|
||||
}
|
||||
|
||||
// set input context focus to our window
|
||||
|
||||
Reference in New Issue
Block a user