mirror of
https://github.com/zoriya/noctalia-shell.git
synced 2026-08-15 18:43:59 +00:00
NTooltip: wip
This commit is contained in:
+10
-2
@@ -12,6 +12,8 @@ Rectangle {
|
||||
property string icon
|
||||
property bool enabled: true
|
||||
property bool hovering: false
|
||||
property var onEntered: function () {}
|
||||
property var onExited: function () {}
|
||||
|
||||
implicitWidth: size
|
||||
implicitHeight: size
|
||||
@@ -35,7 +37,13 @@ Rectangle {
|
||||
anchors.fill: parent
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
hoverEnabled: true
|
||||
onEntered: hovering = true
|
||||
onExited: hovering = false
|
||||
onEntered: {
|
||||
hovering = true
|
||||
root.onEntered()
|
||||
}
|
||||
onExited: {
|
||||
hovering = false
|
||||
root.onExited()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user