diff options
author | Johan Klokkhammer Helsing <johan.helsing@qt.io> | 2018-09-27 13:58:04 +0200 |
---|---|---|
committer | Johan Helsing <johan.helsing@qt.io> | 2018-10-01 07:31:30 +0000 |
commit | 55acc7bf06ff6c972f33acb6a8a24075d9e178c3 (patch) | |
tree | 1e4f19411a91ee6391e9cec7da8fb6139ffed01b | |
parent | b1ae478a754435a545877fa075ad9fd19ba6f5a0 (diff) | |
download | qtwayland-55acc7bf06ff6c972f33acb6a8a24075d9e178c3.tar.gz |
Compositor: Remove WaylandCursorItem.scaleCorrection
It's an implementation detail, so shouldn't be exposed as a property.
Change-Id: Ib0a5b7dd92403cf45e1067710d1aad330a7a340f
Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
-rw-r--r-- | src/imports/compositor/WaylandCursorItem.qml | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/imports/compositor/WaylandCursorItem.qml b/src/imports/compositor/WaylandCursorItem.qml index 33178410..1fa09967 100644 --- a/src/imports/compositor/WaylandCursorItem.qml +++ b/src/imports/compositor/WaylandCursorItem.qml @@ -46,16 +46,15 @@ WaylandQuickItem { property QtObject seat property int hotspotX: 0 property int hotspotY: 0 - // If we've set an output scale factor different from the device pixel ratio - // then the item will be rendered scaled, so we need to shift the hotspot accordingly - property real scaleCorrection: output ? output.scaleFactor / Screen.devicePixelRatio : 1 visible: cursorItem.surface != null inputEventsEnabled: false enabled: false transform: Translate { - x: -hotspotX * scaleCorrection - y: -hotspotY * scaleCorrection + // If we've set an output scale factor different from the device pixel ratio + // then the item will be rendered scaled, so we need to shift the hotspot accordingly + x: -hotspotX * (output ? output.scaleFactor / Screen.devicePixelRatio : 1) + y: -hotspotY * (output ? output.scaleFactor / Screen.devicePixelRatio : 1) } Connections { |