mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-25 15:44:04 -06:00
Fix keeping settings visible when showing all settings
This commit is contained in:
parent
711d60e8c7
commit
7123441db8
1 changed files with 4 additions and 5 deletions
|
@ -18,7 +18,6 @@ Item
|
||||||
property Action configureSettings
|
property Action configureSettings
|
||||||
property bool findingSettings
|
property bool findingSettings
|
||||||
property bool showingAllSettings
|
property bool showingAllSettings
|
||||||
property bool inhibitSwitchToCustom: false
|
|
||||||
signal showTooltip(Item item, point location, string text)
|
signal showTooltip(Item item, point location, string text)
|
||||||
signal hideTooltip()
|
signal hideTooltip()
|
||||||
|
|
||||||
|
@ -559,13 +558,13 @@ Item
|
||||||
MenuItem
|
MenuItem
|
||||||
{
|
{
|
||||||
//: Settings context menu action
|
//: Settings context menu action
|
||||||
visible: !findingSettings;
|
visible: !(findingSettings || showingAllSettings);
|
||||||
text: catalog.i18nc("@action:menu", "Hide this setting");
|
text: catalog.i18nc("@action:menu", "Hide this setting");
|
||||||
onTriggered:
|
onTriggered:
|
||||||
{
|
{
|
||||||
definitionsModel.hide(contextMenu.key);
|
definitionsModel.hide(contextMenu.key);
|
||||||
// visible settings have changed, so we're no longer showing a preset
|
// visible settings have changed, so we're no longer showing a preset
|
||||||
if (Cura.SettingVisibilityPresetsModel.activePreset != "")
|
if (Cura.SettingVisibilityPresetsModel.activePreset != "" && !showingAllSettings)
|
||||||
{
|
{
|
||||||
Cura.SettingVisibilityPresetsModel.setActivePreset("custom");
|
Cura.SettingVisibilityPresetsModel.setActivePreset("custom");
|
||||||
}
|
}
|
||||||
|
@ -585,7 +584,7 @@ Item
|
||||||
return catalog.i18nc("@action:menu", "Keep this setting visible");
|
return catalog.i18nc("@action:menu", "Keep this setting visible");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
visible: findingSettings;
|
visible: (findingSettings || showingAllSettings);
|
||||||
onTriggered:
|
onTriggered:
|
||||||
{
|
{
|
||||||
if (contextMenu.settingVisible)
|
if (contextMenu.settingVisible)
|
||||||
|
@ -597,7 +596,7 @@ Item
|
||||||
definitionsModel.show(contextMenu.key);
|
definitionsModel.show(contextMenu.key);
|
||||||
}
|
}
|
||||||
// visible settings have changed, so we're no longer showing a preset
|
// visible settings have changed, so we're no longer showing a preset
|
||||||
if (Cura.SettingVisibilityPresetsModel.activePreset != "")
|
if (Cura.SettingVisibilityPresetsModel.activePreset != "" && !showingAllSettings)
|
||||||
{
|
{
|
||||||
Cura.SettingVisibilityPresetsModel.setActivePreset("custom");
|
Cura.SettingVisibilityPresetsModel.setActivePreset("custom");
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue