mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-12 01:39:03 +08:00
Sets the platform activity on true when a model is loaded
Also solved a problem with the deleteSelection trigger contributes to #128
This commit is contained in:
parent
d41f1a410c
commit
a687c9c89e
@ -41,7 +41,10 @@ UM.MainWindow {
|
||||
var path = modelData.toString()
|
||||
return (index + 1) + ". " + path.slice(path.lastIndexOf("/") + 1);
|
||||
}
|
||||
onTriggered: UM.MeshFileHandler.readLocalFile(modelData);
|
||||
onTriggered: {
|
||||
UM.MeshFileHandler.readLocalFile(modelData);
|
||||
Printer.setPlatformActivity(true)
|
||||
}
|
||||
}
|
||||
onObjectAdded: fileMenu.insertItem(index, object)
|
||||
onObjectRemoved: fileMenu.removeItem(object)
|
||||
@ -318,7 +321,11 @@ UM.MainWindow {
|
||||
redo.onTriggered: UM.OperationStack.redo();
|
||||
redo.enabled: UM.OperationStack.canRedo;
|
||||
|
||||
deleteSelection.onTriggered: UM.Controller.removeSelection();
|
||||
deleteSelection.onTriggered: {
|
||||
if(objectContextMenu.objectId != 0) {
|
||||
Printer.deleteObject(objectContextMenu.objectId);
|
||||
}
|
||||
}
|
||||
|
||||
deleteObject.onTriggered: {
|
||||
if(objectContextMenu.objectId != 0) {
|
||||
@ -408,6 +415,7 @@ UM.MainWindow {
|
||||
onAccepted:
|
||||
{
|
||||
UM.MeshFileHandler.readLocalFile(fileUrl)
|
||||
Printer.setPlatformActivity(true)
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user