mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-11 08:47:50 -06:00
Bring back print job preview images
This commit is contained in:
parent
cf1dff3fdc
commit
69102643b7
6 changed files with 38 additions and 23 deletions
|
@ -2,6 +2,8 @@
|
|||
# Cura is released under the terms of the LGPLv3 or higher.
|
||||
from typing import List, Optional, Union, Dict, Any
|
||||
|
||||
from PyQt5.QtCore import QUrl
|
||||
|
||||
from cura.PrinterOutput.Models.PrinterConfigurationModel import PrinterConfigurationModel
|
||||
|
||||
from .ClusterBuildPlate import ClusterBuildPlate
|
||||
|
|
|
@ -6,6 +6,7 @@ from PyQt5.QtCore import QUrl
|
|||
|
||||
from cura.PrinterOutput.PrinterOutputController import PrinterOutputController
|
||||
from cura.PrinterOutput.Models.PrinterOutputModel import PrinterOutputModel
|
||||
|
||||
from .ClusterBuildPlate import ClusterBuildPlate
|
||||
from .ClusterPrintCoreConfiguration import ClusterPrintCoreConfiguration
|
||||
from ..BaseModel import BaseModel
|
||||
|
|
|
@ -3,6 +3,7 @@
|
|||
from typing import List
|
||||
|
||||
from PyQt5.QtCore import pyqtProperty, pyqtSignal
|
||||
from PyQt5.QtGui import QImage
|
||||
|
||||
from cura.PrinterOutput.Models.PrintJobOutputModel import PrintJobOutputModel
|
||||
from cura.PrinterOutput.PrinterOutputController import PrinterOutputController
|
||||
|
@ -26,3 +27,8 @@ class UM3PrintJobOutputModel(PrintJobOutputModel):
|
|||
return
|
||||
self._configuration_changes = changes
|
||||
self.configurationChangesChanged.emit()
|
||||
|
||||
def updatePreviewImageData(self, data: bytes) -> None:
|
||||
image = QImage()
|
||||
image.loadFromData(data)
|
||||
self.updatePreviewImage(image)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue