internal: fix qmlls freezing

This commit is contained in:
2 * r + 2 * t 2025-06-19 17:05:40 +10:00
parent d329949fc8
commit c125f1c7e4
2 changed files with 5 additions and 9 deletions

View file

@ -51,10 +51,10 @@ MouseArea {
} }
} }
onPositionChanged: ({ onPositionChanged: event => {
x, const x = event.x;
y const y = event.y;
}) => {
// Show osd on hover // Show osd on hover
const showOsd = inRightPanel(panels.osd, x, y); const showOsd = inRightPanel(panels.osd, x, y);

View file

@ -128,7 +128,7 @@ Item {
return 0; return 0;
if (mouse.pressed) if (mouse.pressed)
return 0.7; return 0.7;
if (mouse.hovered) if (mouse.containsMouse)
return 0.8; return 0.8;
return 1; return 1;
} }
@ -139,14 +139,10 @@ Item {
MouseArea { MouseArea {
id: mouse id: mouse
property bool hovered
anchors.fill: parent anchors.fill: parent
hoverEnabled: true hoverEnabled: true
cursorShape: search.text ? Qt.PointingHandCursor : undefined cursorShape: search.text ? Qt.PointingHandCursor : undefined
onEntered: hovered = true
onExited: hovered = false
onClicked: search.text = "" onClicked: search.text = ""
} }