mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-14 02:07:51 -06:00
Automatically show the Print Monitor when starting a print
CURA-1036
This commit is contained in:
parent
6800991fa1
commit
087ebc0768
3 changed files with 11 additions and 1 deletions
|
@ -242,6 +242,8 @@ class CuraApplication(QtApplication):
|
|||
def _onEngineCreated(self):
|
||||
self._engine.addImageProvider("camera", CameraImageProvider.CameraImageProvider())
|
||||
|
||||
showPrintMonitor = pyqtSignal(bool, arguments = ["show"])
|
||||
|
||||
## Cura has multiple locations where instance containers need to be saved, so we need to handle this differently.
|
||||
#
|
||||
# Note that the AutoSave plugin also calls this method.
|
||||
|
|
|
@ -365,6 +365,7 @@ class USBPrinterOutputDevice(PrinterOutputDevice):
|
|||
self.onError.emit()
|
||||
|
||||
def requestWrite(self, node, file_name = None, filter_by_machine = False):
|
||||
Application.getInstance().showPrintMonitor.emit(True)
|
||||
self.startPrint()
|
||||
|
||||
def _setEndstopState(self, endstop_key, value):
|
||||
|
@ -516,6 +517,7 @@ class USBPrinterOutputDevice(PrinterOutputDevice):
|
|||
self._is_printing = False
|
||||
self._is_paused = False
|
||||
self._updateJobState("ready")
|
||||
Application.getInstance().showPrintMonitor.emit(False)
|
||||
|
||||
## Check if the process did not encounter an error yet.
|
||||
def hasError(self):
|
||||
|
|
|
@ -15,6 +15,11 @@ Rectangle
|
|||
|
||||
property int currentModeIndex;
|
||||
property bool monitoringPrint: false
|
||||
Connections
|
||||
{
|
||||
target: Printer
|
||||
onShowPrintMonitor: base.monitoringPrint = show
|
||||
}
|
||||
|
||||
// Is there an output device for this printer?
|
||||
property bool printerConnected: Cura.MachineManager.printerOutputDevices.length != 0
|
||||
|
@ -83,7 +88,7 @@ Rectangle
|
|||
onClicked: monitoringPrint = false
|
||||
iconSource: UM.Theme.getIcon("tab_settings");
|
||||
checkable: true
|
||||
checked: true
|
||||
checked: !monitoringPrint
|
||||
exclusiveGroup: sidebarHeaderBarGroup
|
||||
|
||||
style: UM.Theme.styles.sidebar_header_tab
|
||||
|
@ -104,6 +109,7 @@ Rectangle
|
|||
return UM.Theme.getIcon("tab_monitor_connected")
|
||||
}
|
||||
checkable: true
|
||||
checked: monitoringPrint
|
||||
exclusiveGroup: sidebarHeaderBarGroup
|
||||
|
||||
style: UM.Theme.styles.sidebar_header_tab
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue