Merge pull request #1834 from whiskeyPeak/fix-launcher-scrolling-interrupt

fix launcher scrolling pin button interrupt
This commit is contained in:
Lysec
2026-02-28 23:02:13 +01:00
committed by GitHub
2 changed files with 11 additions and 1 deletions
+2
View File
@@ -1034,6 +1034,7 @@ Rectangle {
baseSize: Style.baseWidgetSize * 0.75
tooltipText: modelData.tooltip
z: 1
allowScroll: true
onClicked: {
if (modelData.action) {
modelData.action();
@@ -1410,6 +1411,7 @@ Rectangle {
baseSize: Style.baseWidgetSize * 0.75
tooltipText: modelData.tooltip
z: 11
allowScroll: true
onClicked: {
if (modelData.action) {
modelData.action();
+9 -1
View File
@@ -14,6 +14,7 @@ Item {
property string tooltipText
property string tooltipDirection: "auto"
property bool allowClickWhenDisabled: false
property bool allowScroll: false
property bool hovering: false
property color colorBg: Color.mSurfaceVariant
@@ -122,6 +123,13 @@ Item {
root.middleClicked();
}
}
onWheel: wheel => root.wheel(wheel.angleDelta.y)
onWheel: wheel => {
if (root.allowScroll) {
root.wheel(wheel.angleDelta.y);
wheel.accepted = false;
} else {
wheel.accepted = true;
}
}
}
}