Add a preference to use a single instance for loading files

Contributes to #7664
This commit is contained in:
fieldOfView 2020-05-07 17:26:20 +02:00
parent 47bf094c52
commit 1b34449242
2 changed files with 34 additions and 1 deletions

View file

@ -72,6 +72,9 @@ UM.PreferencesPage
var defaultTheme = UM.Preferences.getValue("general/theme")
setDefaultTheme(defaultTheme)
UM.Preferences.resetPreference("cura/single_instance")
scaleToFitCheckbox.checked = boolCheck(UM.Preferences.getValue("cura/single_instance"))
UM.Preferences.resetPreference("physics/automatic_push_free")
pushFreeCheckbox.checked = boolCheck(UM.Preferences.getValue("physics/automatic_push_free"))
UM.Preferences.resetPreference("physics/automatic_drop_down")
@ -560,6 +563,21 @@ UM.PreferencesPage
text: catalog.i18nc("@label","Opening and saving files")
}
UM.TooltipArea
{
width: childrenRect.width
height: childrenRect.height
text: catalog.i18nc("@info:tooltip","Should opening files from the desktop or external applications open in the same instance of Cura?")
CheckBox
{
id: singleInstanceCheckbox
text: catalog.i18nc("@option:check","Use a single instance of Cura")
checked: boolCheck(UM.Preferences.getValue("cura/single_instance"))
onCheckedChanged: UM.Preferences.setValue("cura/single_instance", checked)
}
}
UM.TooltipArea
{
width: childrenRect.width