mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-08-10 23:35:07 -06:00
Merge branch 'master' into feature_intent
Conflicts: plugins/VersionUpgrade/VersionUpgrade41to42/VersionUpgrade41to42.py -> There is a new version upgrade in master, so the old one is sort of obsolete. We may have to move this part to a new version upgrade for 4.3. plugins/VersionUpgrade/VersionUpgrade41to42/__init__.py
This commit is contained in:
commit
5ab1881a21
811 changed files with 1746 additions and 1169 deletions
|
@ -67,6 +67,15 @@ Button
|
|||
anchors.verticalCenter: parent.verticalCenter
|
||||
}
|
||||
|
||||
TextMetrics
|
||||
{
|
||||
id: buttonTextMetrics
|
||||
text: buttonText.text
|
||||
font: buttonText.font
|
||||
elide: buttonText.elide
|
||||
elideWidth: buttonText.width
|
||||
}
|
||||
|
||||
Label
|
||||
{
|
||||
id: buttonText
|
||||
|
@ -124,7 +133,7 @@ Button
|
|||
Cura.ToolTip
|
||||
{
|
||||
id: tooltip
|
||||
visible: button.hovered
|
||||
visible: button.hovered && buttonTextMetrics.elidedText != buttonText.text
|
||||
}
|
||||
|
||||
BusyIndicator
|
||||
|
|
|
@ -368,14 +368,30 @@ UM.PreferencesPage
|
|||
{
|
||||
width: childrenRect.width;
|
||||
height: childrenRect.height;
|
||||
text: catalog.i18nc("@info:tooltip", "Should zooming move in the direction of the mouse?")
|
||||
text: zoomToMouseCheckbox.enabled ? catalog.i18nc("@info:tooltip", "Should zooming move in the direction of the mouse?") : catalog.i18nc("@info:tooltip", "Zooming towards the mouse is not supported in the orthogonal perspective.")
|
||||
|
||||
CheckBox
|
||||
{
|
||||
id: zoomToMouseCheckbox
|
||||
text: catalog.i18nc("@action:button", "Zoom toward mouse direction");
|
||||
checked: boolCheck(UM.Preferences.getValue("view/zoom_to_mouse"))
|
||||
text: catalog.i18nc("@action:button", "Zoom toward mouse direction")
|
||||
checked: boolCheck(UM.Preferences.getValue("view/zoom_to_mouse")) && zoomToMouseCheckbox.enabled
|
||||
onClicked: UM.Preferences.setValue("view/zoom_to_mouse", checked)
|
||||
enabled: UM.Preferences.getValue("general/camera_perspective_mode") !== "orthogonal"
|
||||
}
|
||||
|
||||
//Because there is no signal for individual preferences, we need to manually link to the onPreferenceChanged signal.
|
||||
Connections
|
||||
{
|
||||
target: UM.Preferences
|
||||
onPreferenceChanged:
|
||||
{
|
||||
if(preference != "general/camera_perspective_mode")
|
||||
{
|
||||
return;
|
||||
}
|
||||
zoomToMouseCheckbox.enabled = UM.Preferences.getValue("general/camera_perspective_mode") !== "orthogonal";
|
||||
zoomToMouseCheckbox.checked = boolCheck(UM.Preferences.getValue("view/zoom_to_mouse")) && zoomToMouseCheckbox.enabled;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue