diff --git a/syncplay/client.py b/syncplay/client.py
index fe59d1b..156c991 100644
--- a/syncplay/client.py
+++ b/syncplay/client.py
@@ -37,12 +37,11 @@ class SyncClientFactory(ClientFactory):
reactor.callLater(0.1*(2**self._timesTried), connector.connect)
else:
message = getMessage("en", "disconnection-notification")
- self._client.ui.showMessage(message)
+ self._client.ui.showErrorMessage(message)
def clientConnectionFailed(self, connector, reason):
if not self.reconnecting:
- self._client.ui.showMessage(getMessage("en", "connection-failed-notification"))
- self._client.stop(True)
+ self._client.ui.showErrorMessage(getMessage("en", "connection-failed-notification"))
else:
self.clientConnectionLost(connector, reason)
diff --git a/syncplay/ui/gui.py b/syncplay/ui/gui.py
index ebaac3f..b8b852f 100644
--- a/syncplay/ui/gui.py
+++ b/syncplay/ui/gui.py
@@ -85,7 +85,11 @@ class MainWindow(QtGui.QMainWindow):
print(message)
def showErrorMessage(self, message):
- print("ERROR:\t" + message)
+ message = unicode(message)
+ message = message.replace("&", "&").replace('"', """).replace("<", "<").replace(">", ">")
+ message = message.replace("\n", "
")
+ message = "" + message + ""
+ self.newMessage(time.strftime(constants.UI_TIME_FORMAT, time.localtime()) + message + "
")
def joinRoom(self, room = None):
if room == None: