mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-15 10:47:49 -06:00
Hide the Preview shortcut in the action panel when the active stage is the PreviewStage.
Also adjust the size of the output button when the Preview button is not visible. Contributes to CURA-5786.
This commit is contained in:
parent
69daa0d91a
commit
3669a3791d
1 changed files with 4 additions and 1 deletions
|
@ -102,6 +102,8 @@ Column
|
||||||
|
|
||||||
Cura.ActionButton
|
Cura.ActionButton
|
||||||
{
|
{
|
||||||
|
id: previewStageShortcut
|
||||||
|
|
||||||
leftPadding: UM.Theme.getSize("default_margin").width
|
leftPadding: UM.Theme.getSize("default_margin").width
|
||||||
rightPadding: UM.Theme.getSize("default_margin").width
|
rightPadding: UM.Theme.getSize("default_margin").width
|
||||||
height: UM.Theme.getSize("action_panel_button").height
|
height: UM.Theme.getSize("action_panel_button").height
|
||||||
|
@ -111,11 +113,12 @@ Column
|
||||||
textColor: UM.Theme.getColor("primary")
|
textColor: UM.Theme.getColor("primary")
|
||||||
textHoverColor: UM.Theme.getColor("text")
|
textHoverColor: UM.Theme.getColor("text")
|
||||||
onClicked: UM.Controller.setActiveStage("PreviewStage")
|
onClicked: UM.Controller.setActiveStage("PreviewStage")
|
||||||
|
visible: UM.Controller.activeStage != null && UM.Controller.activeStage.stageId != "PreviewStage"
|
||||||
}
|
}
|
||||||
|
|
||||||
Cura.OutputDevicesActionButton
|
Cura.OutputDevicesActionButton
|
||||||
{
|
{
|
||||||
width: UM.Theme.getSize("action_panel_button").width
|
width: previewStageShortcut.visible ? UM.Theme.getSize("action_panel_button").width : parent.width
|
||||||
height: UM.Theme.getSize("action_panel_button").height
|
height: UM.Theme.getSize("action_panel_button").height
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue