Commit 910f59cf authored by Arjen Hiemstra's avatar Arjen Hiemstra

Reference shortcut label directly by id instead of implicitly

Parent can be null in some cases when the binding is executed, so
instead reference the shortcut label directly so we avoid a null
dereference.

Fixes "TypeError: Cannot read property 'visible' of null" that was
produced with recent QQC2-desktop-style.
parent 2d8d8773
......@@ -80,7 +80,7 @@ T.MenuItem {
Shortcut {
id: itemShortcut
sequence: (parent.visible && controlRoot.action !== null) ? controlRoot.action.shortcut : ""
sequence: (shortcut.visible && controlRoot.action !== null) ? controlRoot.action.shortcut : ""
}
text: visible ? itemShortcut.nativeText : ""
......
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