forked from qt-creator/qt-creator
QmlDesigner: Don't enable position or layout menu if no content
Changed node position and layout context menu enabled checks to correspond to checks that are used to determine the enabled state of their contents. Fixes: QDS-5483 Change-Id: I71a26ffce9cc12036397b62658a08d9895f7cb63 Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
This commit is contained in:
@@ -892,14 +892,14 @@ bool isPositioner(const SelectionContext &context)
|
||||
|
||||
bool layoutOptionVisible(const SelectionContext &context)
|
||||
{
|
||||
return multiSelectionAndInBaseState(context)
|
||||
return selectionCanBeLayoutedAndQtQuickLayoutPossible(context)
|
||||
|| singleSelectionAndInQtQuickLayout(context)
|
||||
|| isLayout(context);
|
||||
}
|
||||
|
||||
bool positionOptionVisible(const SelectionContext &context)
|
||||
{
|
||||
return multiSelectionAndInBaseState(context)
|
||||
return selectionCanBeLayouted(context)
|
||||
|| isPositioner(context);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user