show sync errors in a text window

This commit is contained in:
Damien Elmes 2012-03-19 23:20:47 +09:00
parent 9d5c63d3d2
commit 801feaa41b

View file

@ -8,7 +8,7 @@ from anki import Collection
from anki.sync import Syncer, RemoteServer, FullSyncer, MediaSyncer, \ from anki.sync import Syncer, RemoteServer, FullSyncer, MediaSyncer, \
RemoteMediaServer RemoteMediaServer
from anki.hooks import addHook, remHook from anki.hooks import addHook, remHook
from aqt.utils import tooltip, askUserDialog, showWarning from aqt.utils import tooltip, askUserDialog, showWarning, showText
# Sync manager # Sync manager
###################################################################### ######################################################################
@ -83,8 +83,8 @@ class SyncManager(QObject):
self.label = m self.label = m
self._updateLabel() self._updateLabel()
elif evt == "error": elif evt == "error":
showWarning(_("Syncing failed:\n%s")% showText(_("Syncing failed:\n%s")%
self._rewriteError(args[0])) self._rewriteError(args[0]))
elif evt == "clockOff": elif evt == "clockOff":
self._clockOff() self._clockOff()
elif evt == "noChanges": elif evt == "noChanges":