[vlc-commits] [Git][videolan/vlc][master] 5 commits: qml/IconToolButton: Update the Tooltip support
Steve Lhomme (@robUx4)
gitlab at videolan.org
Sun Jun 18 03:40:23 UTC 2023
Steve Lhomme pushed to branch master at VideoLAN / VLC
Commits:
1c1691f3 by Benjamin Arnaud at 2023-06-18T02:45:24+00:00
qml/IconToolButton: Update the Tooltip support
- - - - -
cabdb0d5 by Benjamin Arnaud at 2023-06-18T02:45:24+00:00
qml/BannerTabButton: Update the Tooltip support
- - - - -
337c4cce by Benjamin Arnaud at 2023-06-18T02:45:24+00:00
qml/PlaylistDelegate: Update the Tooltip timeout
- - - - -
c7dc1d23 by Benjamin Arnaud at 2023-06-18T02:45:24+00:00
qml: Update the Tooltip usage
- - - - -
dfbf7346 by Benjamin Arnaud at 2023-06-18T02:45:24+00:00
qml/IconToolButton(s): Set missing text values
- - - - -
11 changed files:
- modules/gui/qt/dialogs/toolbar/qml/ToolbarEditorDialog.qml
- modules/gui/qt/medialibrary/qml/VideoInfoExpandPanel.qml
- modules/gui/qt/player/qml/PlaybackSpeed.qml
- modules/gui/qt/player/qml/controlbarcontrols/ExtendedSettingsButton.qml
- modules/gui/qt/player/qml/controlbarcontrols/TeletextColorButton.qml
- modules/gui/qt/player/qml/controlbarcontrols/TeletextWidget.qml
- modules/gui/qt/playlist/qml/PlaylistDelegate.qml
- modules/gui/qt/widgets/qml/BannerTabButton.qml
- modules/gui/qt/widgets/qml/IconToolButton.qml
- modules/gui/qt/widgets/qml/SearchBox.qml
- modules/gui/qt/widgets/qml/TableViewDelegate.qml
Changes:
=====================================
modules/gui/qt/dialogs/toolbar/qml/ToolbarEditorDialog.qml
=====================================
@@ -143,8 +143,6 @@ WindowDialog {
MainCtx.controlbarProfileModel.cloneSelectedProfile(npDialog.text)
MainCtx.controlbarProfileModel.selectedProfile = (MainCtx.controlbarProfileModel.rowCount() - 1)
}
-
- T.ToolTip.visible: hovered
}
Widgets.IconToolButton {
@@ -156,8 +154,6 @@ WindowDialog {
onClicked: {
MainCtx.controlbarProfileModel.currentModel.injectDefaults(false)
}
-
- T.ToolTip.visible: hovered
}
Widgets.IconToolButton {
@@ -167,8 +163,6 @@ WindowDialog {
onClicked: {
MainCtx.controlbarProfileModel.deleteSelectedProfile()
}
-
- T.ToolTip.visible: hovered
}
}
=====================================
modules/gui/qt/medialibrary/qml/VideoInfoExpandPanel.qml
=====================================
@@ -176,6 +176,8 @@ FocusScope {
iconText: VLCIcons.close
+ text: I18n.qtr("Close")
+
onClicked: root.retract()
Navigation.parentItem: root
=====================================
modules/gui/qt/player/qml/PlaybackSpeed.qml
=====================================
@@ -204,6 +204,8 @@ ColumnLayout {
focus: true
+ text: I18n.qtr("Reset")
+
Navigation.parentItem: rowA
Navigation.downItem: slider
=====================================
modules/gui/qt/player/qml/controlbarcontrols/ExtendedSettingsButton.qml
=====================================
@@ -27,6 +27,9 @@ Widgets.IconControlButton {
id: extdSettingsBtn
iconText: VLCIcons.extended
+
+ text: I18n.qtr("Extended settings")
+
onClicked: DialogsProvider.extendedDialog()
- Accessible.name: I18n.qtr("Extended settings")
+ Accessible.name: text
}
=====================================
modules/gui/qt/player/qml/controlbarcontrols/TeletextColorButton.qml
=====================================
@@ -28,6 +28,4 @@ Widgets.IconControlButton {
// Settings
iconText: VLCIcons.circle
-
- T.ToolTip.visible: (hovered || visualFocus)
}
=====================================
modules/gui/qt/player/qml/controlbarcontrols/TeletextWidget.qml
=====================================
@@ -108,8 +108,6 @@ T.Pane {
iconText: VLCIcons.transparency
text: I18n.qtr("Teletext transparency")
- T.ToolTip.visible: (hovered || visualFocus)
-
Navigation.parentItem: root
Navigation.leftItem: teleActivateBtn
Navigation.rightItem: telePageNumber
@@ -184,8 +182,6 @@ T.Pane {
iconText: VLCIcons.home
text: I18n.qtr("Index key")
- T.ToolTip.visible: (hovered || visualFocus)
-
Navigation.parentItem: root
Navigation.leftItem: telePageNumber
Navigation.rightItem: redKeyBtn
=====================================
modules/gui/qt/playlist/qml/PlaylistDelegate.qml
=====================================
@@ -61,7 +61,9 @@ T.ItemDelegate {
!overlayMenu.shown && MainCtx.playlistVisible &&
(textInfoColumn.implicitWidth > textInfoColumn.width) )
- T.ToolTip.timeout: (hovered ? 0 : VLCStyle.duration_humanMoment)
+ // NOTE: This is useful for keyboard navigation on a column, to avoid blocking visibility on
+ // the surrounding items.
+ T.ToolTip.timeout: (visualFocus) ? VLCStyle.duration_humanMoment : 0
T.ToolTip.text: (textInfo.text + '\n' + textArtist.text)
=====================================
modules/gui/qt/widgets/qml/BannerTabButton.qml
=====================================
@@ -63,6 +63,14 @@ T.TabButton {
Accessible.onPressAction: control.clicked()
+ // Tooltip
+
+ T.ToolTip.visible: (showText === false && T.ToolTip.text && (hovered || visualFocus))
+
+ T.ToolTip.delay: VLCStyle.delayToolTipAppear
+
+ T.ToolTip.text: text
+
// Childs
ColorContext {
=====================================
modules/gui/qt/widgets/qml/IconToolButton.qml
=====================================
@@ -62,11 +62,20 @@ T.ToolButton {
Accessible.onPressAction: control.clicked()
- // Childs
+ // Tooltip
+
+ T.ToolTip.visible: (hovered || visualFocus)
- T.ToolTip.text: control.text
T.ToolTip.delay: VLCStyle.delayToolTipAppear
+ T.ToolTip.text: text
+
+ // Events
+
+ Component.onCompleted: console.assert(text !== "", "text is empty")
+
+ // Children
+
readonly property ColorContext colorContext : ColorContext {
id: theme
colorSet: ColorContext.ToolButton
=====================================
modules/gui/qt/widgets/qml/SearchBox.qml
=====================================
@@ -173,6 +173,8 @@ FocusScope {
size: VLCStyle.icon_banner
iconText: VLCIcons.close
+ text: I18n.qtr("Clear")
+
visible: (textField.text.length > 0)
onVisibleChanged: {
=====================================
modules/gui/qt/widgets/qml/TableViewDelegate.qml
=====================================
@@ -232,6 +232,8 @@ T.Control {
size: VLCStyle.icon_normal
+ text: I18n.qtr("Menu")
+
visible: delegate.hovered
onClicked: {
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/88d40b7a6eddb4b11393d9e5e02d98281356747c...dfbf73467111bc06f59989ff59d21c2efbbaa02e
--
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/88d40b7a6eddb4b11393d9e5e02d98281356747c...dfbf73467111bc06f59989ff59d21c2efbbaa02e
You're receiving this email because of your account on code.videolan.org.
VideoLAN code repository instance
More information about the vlc-commits
mailing list