Added zoom to mouse preference

https://github.com/Ultimaker/Cura/issues/1572
This commit is contained in:
Jaime van Kessel 2017-06-27 15:41:17 +02:00
parent b9c71a34eb
commit 4370e3a13c

View file

@ -86,6 +86,8 @@ UM.PreferencesPage
centerOnSelectCheckbox.checked = boolCheck(UM.Preferences.getValue("view/center_on_select"))
UM.Preferences.resetPreference("view/invert_zoom");
invertZoomCheckbox.checked = boolCheck(UM.Preferences.getValue("view/invert_zoom"))
UM.Preferences.resetPreference("view/zoom_to_mouse");
zoomToMouseCheckbox.checked = boolCheck(UM.Preferences.getValue("view/zoom_to_mouse"))
UM.Preferences.resetPreference("view/top_layer_count");
topLayerCountCheckbox.checked = boolCheck(UM.Preferences.getValue("view/top_layer_count"))
@ -354,6 +356,20 @@ UM.PreferencesPage
}
}
UM.TooltipArea {
width: childrenRect.width;
height: childrenRect.height;
text: catalog.i18nc("@info:tooltip", "Should zooming move in the direction of the mouse?")
CheckBox
{
id: zoomToMouseCheckbox
text: catalog.i18nc("@action:button","Zoom toward mouse direction");
checked: boolCheck(UM.Preferences.getValue("view/zoom_to_mouse"))
onClicked: UM.Preferences.setValue("view/zoom_to_mouse", checked)
}
}
UM.TooltipArea {
width: childrenRect.width
height: childrenRect.height