Limited StatusToolTip width for maxWidth. Fixes #1817

This commit is contained in:
ace-smart 2021-02-10 20:25:54 +04:00 committed by Iuri Matias
parent 9950221159
commit f4ebb5feae
2 changed files with 2 additions and 3 deletions

View File

@ -58,7 +58,6 @@ Item {
icon.name: "info"
StatusToolTip {
visible: infoButton.hovered
width: 337
//% "Signing phrase is a 3 word combination that displayed when you entered the wallet on this device for the first time."
text: qsTrId("signing-phrase-is-a-3-word-combination-that-displayed-when-you-entered-the-wallet-on-this-device-for-the-first-time-")
}
@ -87,7 +86,6 @@ Item {
icon.name: "info"
StatusToolTip {
visible: passwordInfoButton.hovered
width: 224
//% "Enter the password you use to unlock this device"
text: qsTrId("enter-the-password-you-use-to-unlock-this-device")
}

View File

@ -5,7 +5,8 @@ import "../../shared"
ToolTip {
id: tooltip
implicitWidth: textContent.implicitWidth + Style.current.bigPadding
property int maxWidth: 400
implicitWidth: Math.min(maxWidth, textContent.implicitWidth + Style.current.bigPadding)
leftPadding: Style.current.smallPadding
rightPadding: Style.current.smallPadding
topPadding: Style.current.smallPadding