diff --git a/UM/Qt/qml/UM/Menu.qml b/UM/Qt/qml/UM/Menu.qml index 30538cbcf..0148981a8 100644 --- a/UM/Qt/qml/UM/Menu.qml +++ b/UM/Qt/qml/UM/Menu.qml @@ -17,7 +17,7 @@ Menu { root.parent.visible = shouldBeVisible root.parent.height = shouldBeVisible ? UM.Theme.getSize("menu").height : 0 - root.width = shouldBeVisible ? Qt.binding(setWidth) : 0 + root.width = shouldBeVisible ? setWidth() : 0 } } diff --git a/UM/Qt/qml/UM/MenuItem.qml b/UM/Qt/qml/UM/MenuItem.qml index 7f5ea0c1c..12c804b67 100644 --- a/UM/Qt/qml/UM/MenuItem.qml +++ b/UM/Qt/qml/UM/MenuItem.qml @@ -84,8 +84,7 @@ MenuItem { // Middle margin id: middleSpacer - width: visible ? UM.Theme.getSize("default_margin").width : 0 - visible: _shortcut.nativeText != "" || root.subMenu + width: (_shortcut.nativeText != "" || root.subMenu) ? UM.Theme.getSize("default_margin").width : 0 } UM.Label