diff options
| author | Tarja Sundqvist <tarja.sundqvist@qt.io> | 2025-12-15 16:14:16 +0200 |
|---|---|---|
| committer | Tarja Sundqvist <tarja.sundqvist@qt.io> | 2025-12-15 16:14:16 +0200 |
| commit | 2d66011e197f96cf17b170fe10b6a78354d3117c (patch) | |
| tree | e4737ff487171dc946ef33d9c355de128ab8d6d5 /src/plugins/platforms/xcb/qxcbscreen.cpp | |
| parent | 8216f5c5249db2c368434129fb6f4e35cb75edfc (diff) | |
| parent | f9e9e1f1a566511d663b32e422f7b054713e5112 (diff) | |
Merge tag 'v6.5.8-lts-lgpl' into 6.56.5
Qt 6.5.8-lts-lgpl release
Diffstat (limited to 'src/plugins/platforms/xcb/qxcbscreen.cpp')
| -rw-r--r-- | src/plugins/platforms/xcb/qxcbscreen.cpp | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/src/plugins/platforms/xcb/qxcbscreen.cpp b/src/plugins/platforms/xcb/qxcbscreen.cpp index 06f4b66edb2..9d1aa795e0a 100644 --- a/src/plugins/platforms/xcb/qxcbscreen.cpp +++ b/src/plugins/platforms/xcb/qxcbscreen.cpp @@ -657,12 +657,16 @@ void QXcbScreen::setMonitor(xcb_randr_monitor_info_t *monitorInfo, xcb_timestamp if (m_crtcs.size() == 1) { auto crtc = Q_XCB_REPLY(xcb_randr_get_crtc_info, xcb_connection(), m_crtcs[0], timestamp); - m_singlescreen = (monitorGeometry == (QRect(crtc->x, crtc->y, crtc->width, crtc->height))); - if (m_singlescreen) { - if (crtc->mode) { - updateGeometry(QRect(crtc->x, crtc->y, crtc->width, crtc->height), crtc->rotation); - if (mode() != crtc->mode) - updateRefreshRate(crtc->mode); + if (crtc == XCB_NONE) { + qCDebug(lcQpaScreen, "Didn't get crtc info when m_crtcs.size() == 1"); + } else { + m_singlescreen = (monitorGeometry == (QRect(crtc->x, crtc->y, crtc->width, crtc->height))); + if (m_singlescreen) { + if (crtc->mode) { + updateGeometry(QRect(crtc->x, crtc->y, crtc->width, crtc->height), crtc->rotation); + if (mode() != crtc->mode) + updateRefreshRate(crtc->mode); + } } } } |
