Commit 83e102a8 authored by Andreas Cord-Landwehr's avatar Andreas Cord-Landwehr

Add tooltips for shortcuts

parent 05d780b6
......@@ -5,7 +5,7 @@
*/
import QtQuick 2.5
import QtQuick.Controls 2.0
import QtQuick.Controls 2.5
import org.kde.kirigami 2.7 as Kirigami
Kirigami.BasicListItem
......@@ -25,6 +25,10 @@ Kirigami.BasicListItem
Kirigami.MnemonicData.label: action.text
label: Kirigami.MnemonicData.richTextLabel
readonly property var tooltip: ToolTip {
text: action.shortcut ? action.shortcut : p0.nativeText
}
readonly property var p0: Shortcut {
sequence: item.Kirigami.MnemonicData.sequence
onActivated: item.clicked()
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment