mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-12 17:39:03 +08:00
Fix tooltip showing on hover when no tooltipText in provided.
CURA-8849
This commit is contained in:
parent
cde897ff1e
commit
09f2a73cb1
@ -24,7 +24,7 @@ Item
|
|||||||
property alias wrapMode: label.wrapMode
|
property alias wrapMode: label.wrapMode
|
||||||
property real spacing: UM.Theme.getSize("narrow_margin").width
|
property real spacing: UM.Theme.getSize("narrow_margin").width
|
||||||
|
|
||||||
property string tooltipText
|
property string tooltipText: ""
|
||||||
|
|
||||||
// These properties can be used in combination with layouts.
|
// These properties can be used in combination with layouts.
|
||||||
readonly property real contentWidth: icon.width + margin + label.contentWidth
|
readonly property real contentWidth: icon.width + margin + label.contentWidth
|
||||||
@ -71,7 +71,7 @@ Item
|
|||||||
|
|
||||||
MouseArea
|
MouseArea
|
||||||
{
|
{
|
||||||
enabled: tooltipText != null
|
enabled: tooltipText != ""
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
hoverEnabled: true
|
hoverEnabled: true
|
||||||
onEntered: base.showTooltip(parent, Qt.point(-UM.Theme.getSize("thick_margin").width, 0), tooltipText)
|
onEntered: base.showTooltip(parent, Qt.point(-UM.Theme.getSize("thick_margin").width, 0), tooltipText)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user