Updated message with message types

Contributes to CURA-8418
This commit is contained in:
Jelle Spijker 2021-07-28 08:45:42 +02:00
parent 900db57f0f
commit 2263969d5f
No known key found for this signature in database
GPG key ID: 6662DC033BE6B99A
26 changed files with 136 additions and 82 deletions

View file

@ -186,7 +186,8 @@ class AuthorizationService:
self._server.start(verification_code, state)
except OSError:
Logger.logException("w", "Unable to create authorization request server")
Message(i18n_catalog.i18nc("@info", "Unable to start a new sign in process. Check if another sign in attempt is still active."),
Message(i18n_catalog.i18nc("@info",
"Unable to start a new sign in process. Check if another sign in attempt is still active."),
title=i18n_catalog.i18nc("@info:title", "Warning"),
message_type = Message.MessageType.WARNING).show()
return
@ -242,7 +243,10 @@ class AuthorizationService:
if self._unable_to_get_data_message is not None:
self._unable_to_get_data_message.hide()
self._unable_to_get_data_message = Message(i18n_catalog.i18nc("@info", "Unable to reach the Ultimaker account server."), title = i18n_catalog.i18nc("@info:title", "Warning"))
self._unable_to_get_data_message = Message(i18n_catalog.i18nc("@info",
"Unable to reach the Ultimaker account server."),
title = i18n_catalog.i18nc("@info:title", "Warning"),
message_type = Message.MessageType.ERROR)
self._unable_to_get_data_message.show()
except (ValueError, TypeError):
Logger.logException("w", "Could not load auth data from preferences")