aboutsummaryrefslogtreecommitdiffstats
path: root/src/quicktemplates/qquickselectionrectangle.cpp
diff options
context:
space:
mode:
authorTasuku Suzuki <tasuku.suzuki@signal-slot.co.jp>2023-01-16 01:23:00 +0900
committerTasuku Suzuki <tasuku.suzuki@signal-slot.co.jp>2023-01-17 00:36:26 +0900
commit74b9c2a96f25b69002e5cbb261abf425c9f51a3d (patch)
treecd576ae2f3499896ad6af3ba3e19f4d15a2ddae5 /src/quicktemplates/qquickselectionrectangle.cpp
parent7409c217e8691beae5cd195fc8a0e3479de1db77 (diff)
Fix build with -no-feature-cursor
Pick-to: 6.5 Change-Id: Ibb89885c6cde3e49fffbc02f9c83880f2f2dda5d Reviewed-by: Oliver Eftevaag <oliver.eftevaag@qt.io>
Diffstat (limited to 'src/quicktemplates/qquickselectionrectangle.cpp')
-rw-r--r--src/quicktemplates/qquickselectionrectangle.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/quicktemplates/qquickselectionrectangle.cpp b/src/quicktemplates/qquickselectionrectangle.cpp
index dedde0858a..95e28fd1ca 100644
--- a/src/quicktemplates/qquickselectionrectangle.cpp
+++ b/src/quicktemplates/qquickselectionrectangle.cpp
@@ -315,7 +315,9 @@ QQuickItem *QQuickSelectionRectanglePrivate::createHandle(QQmlComponent *delegat
QQuickHoverHandler *hoverHandler = new QQuickHoverHandler();
hoverHandler->setTarget(nullptr);
hoverHandler->setParentItem(handleItem);
+#if QT_CONFIG(cursor)
hoverHandler->setCursorShape(Qt::SizeFDiagCursor);
+#endif
hoverHandler->setBlocking(true);
// Add a dummy TapHandler that blocks the user from being
@@ -339,12 +341,16 @@ QQuickItem *QQuickSelectionRectanglePrivate::createHandle(QQmlComponent *delegat
m_draggedHandle = handleItem;
updateHandles();
updateDraggingState(true);
+#if QT_CONFIG(cursor)
QGuiApplication::setOverrideCursor(Qt::SizeFDiagCursor);
+#endif
} else {
m_scrollTimer.stop();
m_selectable->normalizeSelection();
updateDraggingState(false);
+#if QT_CONFIG(cursor)
QGuiApplication::restoreOverrideCursor();
+#endif
}
});