diff options
author | Louai Al-Khanji <louai.al-khanji@theqtcompany.com> | 2014-10-17 11:45:02 +0300 |
---|---|---|
committer | Laszlo Agocs <laszlo.agocs@digia.com> | 2014-10-17 15:48:14 +0200 |
commit | d63e012fcdd8567f5d94dc5e234a8b3007879497 (patch) | |
tree | cd5b9458179b8587608ab08a960873ebfe2eebf2 /src/plugins/platforms/eglfs | |
parent | 4f1de1432c0a028ac68d5a800f3b670ce539d848 (diff) |
eglfs: Make KMS hooks compile on older systems
drmModeSetCursor2 has not been available for very long and doesn't
actually buy us much, so don't use it. Also one more missing cast.
Change-Id: I1120b933759bbabf73edd23bfc837a2a27a93a0c
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Diffstat (limited to 'src/plugins/platforms/eglfs')
-rw-r--r-- | src/plugins/platforms/eglfs/qeglfshooks_kms.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/plugins/platforms/eglfs/qeglfshooks_kms.cpp b/src/plugins/platforms/eglfs/qeglfshooks_kms.cpp index c057abb8e4..5052b0fc52 100644 --- a/src/plugins/platforms/eglfs/qeglfshooks_kms.cpp +++ b/src/plugins/platforms/eglfs/qeglfshooks_kms.cpp @@ -412,8 +412,7 @@ void QEglFSKmsCursor::changeCursor(QCursor *windowCursor, QWindow *window) gbm_bo_write(m_bo, cursorImage.constBits(), cursorImage.byteCount()); uint32_t handle = gbm_bo_get_handle(m_bo).u32; - QPoint hot = m_cursorImage.hotspot(); - int status = drmModeSetCursor2(m_screen->device()->fd(), m_screen->output().crtc_id, handle, 64, 64, hot.x(), hot.y()); + int status = drmModeSetCursor(m_screen->device()->fd(), m_screen->output().crtc_id, handle, 64, 64); if (status != 0) qWarning("Could not set cursor: %d", status); } @@ -515,7 +514,7 @@ QEglFSKmsScreen::FrameBuffer *QEglFSKmsScreen::framebufferForBufferObject(gbm_bo } QEglFSKmsScreen::QEglFSKmsScreen(QEglFSKmsDevice *device, QEglFSKmsOutput output, QPoint position) - : QEglFSScreen(eglGetDisplay(device->device())) + : QEglFSScreen(eglGetDisplay(reinterpret_cast<EGLNativeDisplayType>(device->device()))) , m_device(device) , m_gbm_surface(Q_NULLPTR) , m_gbm_bo_current(Q_NULLPTR) |