Merge pull request #9507 from Ultimaker/CURA-8127_pref_screen_osx_fix

CURA-8127 preference-screen OSX fix
This commit is contained in:
Jelle Spijker 2021-04-06 11:59:38 +02:00 committed by GitHub
commit e9a8ff05cd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,13 +1,13 @@
// Copyright (c) 2020 Ultimaker B.V.
// Cura is released under the terms of the LGPLv3 or higher.
import QtQuick 2.1
import QtQuick.Controls 1.1
import QtQuick 2.10
import QtQuick.Controls 2.3
import QtQuick.Layouts 1.1
import QtQuick.Controls.Styles 1.1
import UM 1.1 as UM
import Cura 1.0 as Cura
import Cura 1.1 as Cura
UM.PreferencesPage
{
@ -123,8 +123,6 @@ UM.PreferencesPage
width: parent.width
height: parent.height
flickableItem.flickableDirection: Flickable.VerticalFlick;
Column
{
@ -148,16 +146,14 @@ UM.PreferencesPage
text: "Language:" //Don't translate this, to make it easier to find the language drop-down if you can't read the current language.
}
ComboBox
{
id: languageComboBox
model: ListModel
ListModel
{
id: languageList
Component.onCompleted: {
Component.onCompleted:
{
append({ text: "English", code: "en_US" })
append({ text: "Čeština", code: "cs_CZ" })
//Czech is disabled for being incomplete: append({ text: "Čeština", code: "cs_CZ" })
append({ text: "Deutsch", code: "de_DE" })
append({ text: "Español", code: "es_ES" })
//Finnish is disabled for being incomplete: append({ text: "Suomi", code: "fi_FI" })
@ -182,6 +178,13 @@ UM.PreferencesPage
}
}
ComboBox
{
id: languageComboBox
textRole: "text"
model: languageList
currentIndex:
{
var code = UM.Preferences.getValue("general/language");
@ -229,11 +232,7 @@ UM.PreferencesPage
text: catalog.i18nc("@label","Theme:")
}
ComboBox
{
id: themeComboBox
model: ListModel
ListModel
{
id: themeList
@ -246,6 +245,13 @@ UM.PreferencesPage
}
}
ComboBox
{
id: themeComboBox
model: themeList
textRole: "text"
currentIndex:
{
var code = UM.Preferences.getValue("general/theme");
@ -519,20 +525,23 @@ UM.PreferencesPage
{
text: catalog.i18nc("@window:text", "Camera rendering:")
}
ComboBox
{
id: cameraComboBox
model: ListModel
ListModel
{
id: comboBoxList
Component.onCompleted: {
Component.onCompleted:
{
append({ text: catalog.i18n("Perspective"), code: "perspective" })
append({ text: catalog.i18n("Orthographic"), code: "orthographic" })
}
}
ComboBox
{
id: cameraComboBox
model: comboBoxList
textRole: "text"
currentIndex:
{
var code = UM.Preferences.getValue("general/camera_perspective_mode");
@ -683,6 +692,7 @@ UM.PreferencesPage
append({ text: catalog.i18nc("@option:openProject", "Always import models"), code: "open_as_model" })
}
}
textRole: "text"
currentIndex:
{
@ -749,6 +759,7 @@ UM.PreferencesPage
append({ text: catalog.i18nc("@option:discardOrKeep", "Always transfer changed settings to new profile"), code: "always_keep" })
}
}
textRole: "text"
currentIndex:
{