mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-12 10:29:05 +08:00
Update machines preferences page to QtControls 2
CURA-8684
This commit is contained in:
parent
3e98282871
commit
b6e375a3be
@ -1,8 +1,8 @@
|
|||||||
// Copyright (c) 2018 Ultimaker B.V.
|
// Copyright (c) 2022 Ultimaker B.V.
|
||||||
// Cura is released under the terms of the LGPLv3 or higher.
|
// Cura is released under the terms of the LGPLv3 or higher.
|
||||||
|
|
||||||
import QtQuick 2.7
|
import QtQuick 2.7
|
||||||
import QtQuick.Controls 1.4
|
import QtQuick.Controls 2.1
|
||||||
import QtQuick.Window 2.1
|
import QtQuick.Window 2.1
|
||||||
|
|
||||||
import UM 1.5 as UM
|
import UM 1.5 as UM
|
||||||
@ -38,7 +38,7 @@ UM.ManagementPage
|
|||||||
{
|
{
|
||||||
id: activateMenuButton
|
id: activateMenuButton
|
||||||
text: catalog.i18nc("@action:button", "Activate");
|
text: catalog.i18nc("@action:button", "Activate");
|
||||||
iconName: "list-activate";
|
icon.name: "list-activate";
|
||||||
enabled: base.currentItem != null && base.currentItem.id != Cura.MachineManager.activeMachine.id
|
enabled: base.currentItem != null && base.currentItem.id != Cura.MachineManager.activeMachine.id
|
||||||
onClicked: Cura.MachineManager.setActiveMachine(base.currentItem.id)
|
onClicked: Cura.MachineManager.setActiveMachine(base.currentItem.id)
|
||||||
},
|
},
|
||||||
@ -46,14 +46,14 @@ UM.ManagementPage
|
|||||||
{
|
{
|
||||||
id: addMenuButton
|
id: addMenuButton
|
||||||
text: catalog.i18nc("@action:button", "Add");
|
text: catalog.i18nc("@action:button", "Add");
|
||||||
iconName: "list-add";
|
icon.name: "list-add";
|
||||||
onClicked: Cura.Actions.addMachine.trigger()
|
onClicked: Cura.Actions.addMachine.trigger()
|
||||||
},
|
},
|
||||||
Button
|
Button
|
||||||
{
|
{
|
||||||
id: removeMenuButton
|
id: removeMenuButton
|
||||||
text: catalog.i18nc("@action:button", "Remove");
|
text: catalog.i18nc("@action:button", "Remove");
|
||||||
iconName: "list-remove";
|
icon.name: "list-remove";
|
||||||
enabled: base.currentItem != null && model.count > 1
|
enabled: base.currentItem != null && model.count > 1
|
||||||
onClicked: confirmDialog.open();
|
onClicked: confirmDialog.open();
|
||||||
},
|
},
|
||||||
@ -61,7 +61,7 @@ UM.ManagementPage
|
|||||||
{
|
{
|
||||||
id: renameMenuButton
|
id: renameMenuButton
|
||||||
text: catalog.i18nc("@action:button", "Rename");
|
text: catalog.i18nc("@action:button", "Rename");
|
||||||
iconName: "edit-rename";
|
icon.name: "edit-rename";
|
||||||
enabled: base.currentItem != null && base.currentItem.metadata.group_name == null
|
enabled: base.currentItem != null && base.currentItem.metadata.group_name == null
|
||||||
onClicked: renameDialog.open();
|
onClicked: renameDialog.open();
|
||||||
}
|
}
|
||||||
@ -125,7 +125,7 @@ UM.ManagementPage
|
|||||||
rightButtons: Button
|
rightButtons: Button
|
||||||
{
|
{
|
||||||
text: catalog.i18nc("@action:button", "Close")
|
text: catalog.i18nc("@action:button", "Close")
|
||||||
iconName: "dialog-close"
|
icon.name: "dialog-close"
|
||||||
onClicked: actionDialog.reject()
|
onClicked: actionDialog.reject()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user