mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-14 10:17:52 -06:00
Update messages to use the message_types
CURA-8418
This commit is contained in:
parent
f11079adcf
commit
900db57f0f
23 changed files with 81 additions and 39 deletions
|
@ -19,7 +19,8 @@ class LegacyDeviceNoLongerSupportedMessage(Message):
|
|||
"running Ultimaker Connect. Please update the printer to the "
|
||||
"latest firmware."),
|
||||
title = I18N_CATALOG.i18nc("@info:title", "Update your printer"),
|
||||
lifetime = 10
|
||||
lifetime = 10,
|
||||
message_type = Message.MessageType.WARNING
|
||||
)
|
||||
|
||||
def show(self) -> None:
|
||||
|
|
|
@ -29,7 +29,8 @@ class NotClusterHostMessage(Message):
|
|||
"it as a group host.", device.name),
|
||||
title = I18N_CATALOG.i18nc("@info:title", "Not a group host"),
|
||||
lifetime = 0,
|
||||
dismissable = True
|
||||
dismissable = True,
|
||||
message_type = Message.MessageType.ERROR
|
||||
)
|
||||
self._address = device.address
|
||||
self.addAction("", I18N_CATALOG.i18nc("@action", "Configure group"), "", "")
|
||||
|
|
|
@ -14,5 +14,6 @@ class PrintJobUploadBlockedMessage(Message):
|
|||
super().__init__(
|
||||
text = I18N_CATALOG.i18nc("@info:status", "Please wait until the current job has been sent."),
|
||||
title = I18N_CATALOG.i18nc("@info:title", "Print error"),
|
||||
lifetime = 10
|
||||
lifetime = 10,
|
||||
message_type = Message.MessageType.WARNING
|
||||
)
|
||||
|
|
|
@ -13,5 +13,6 @@ class PrintJobUploadErrorMessage(Message):
|
|||
def __init__(self, message: str = None) -> None:
|
||||
super().__init__(
|
||||
text = message or I18N_CATALOG.i18nc("@info:text", "Could not upload the data to the printer."),
|
||||
title = I18N_CATALOG.i18nc("@info:title", "Network error")
|
||||
title = I18N_CATALOG.i18nc("@info:title", "Network error"),
|
||||
message_type=Message.MessageType.ERROR
|
||||
)
|
||||
|
|
|
@ -15,5 +15,6 @@ class PrintJobUploadQueueFullMessage(Message):
|
|||
super().__init__(
|
||||
text = I18N_CATALOG.i18nc("@info:status", "Print job queue is full. The printer can't accept a new job."),
|
||||
title = I18N_CATALOG.i18nc("@info:title", "Queue Full"),
|
||||
lifetime = 10
|
||||
lifetime = 10,
|
||||
message_type=Message.MessageType.WARNING
|
||||
)
|
||||
|
|
|
@ -13,5 +13,6 @@ class PrintJobUploadSuccessMessage(Message):
|
|||
def __init__(self) -> None:
|
||||
super().__init__(
|
||||
text = I18N_CATALOG.i18nc("@info:status", "Print job was successfully sent to the printer."),
|
||||
title = I18N_CATALOG.i18nc("@info:title", "Data Sent")
|
||||
title = I18N_CATALOG.i18nc("@info:title", "Data Sent"),
|
||||
message_type = Message.MessageType.POSITIVE
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue