mirror of
https://github.com/ankitects/anki.git
synced 2025-09-20 06:52:21 -04:00
make sync msg box configurable, fix bug in initial->study screen
This commit is contained in:
parent
329caf7f96
commit
2eaadcfa08
2 changed files with 8 additions and 3 deletions
|
@ -44,6 +44,7 @@ class Config(dict):
|
||||||
'iconSize': 32,
|
'iconSize': 32,
|
||||||
'syncOnLoad': True,
|
'syncOnLoad': True,
|
||||||
'syncOnClose': True,
|
'syncOnClose': True,
|
||||||
|
'syncInMsgBox': False,
|
||||||
'checkForUpdates': True,
|
'checkForUpdates': True,
|
||||||
'interfaceLang': "",
|
'interfaceLang': "",
|
||||||
'syncUsername': "",
|
'syncUsername': "",
|
||||||
|
|
|
@ -230,7 +230,7 @@ Please do not file a bug report with Anki.<br><br>""")
|
||||||
self.updateRecentFilesMenu()
|
self.updateRecentFilesMenu()
|
||||||
self.updateViews(state)
|
self.updateViews(state)
|
||||||
if self.state == "studyScreen":
|
if self.state == "studyScreen":
|
||||||
return self.updateStudyStats()
|
return self.showStudyScreen()
|
||||||
else:
|
else:
|
||||||
return self.moveToState("getQuestion")
|
return self.moveToState("getQuestion")
|
||||||
else:
|
else:
|
||||||
|
@ -1822,9 +1822,13 @@ it to your friends.
|
||||||
self.setStatus("")
|
self.setStatus("")
|
||||||
|
|
||||||
def noSyncResponse(self):
|
def noSyncResponse(self):
|
||||||
self.showToolTip(_("""\
|
msg = _("""\
|
||||||
<h1>Sync Failed</h1>
|
<h1>Sync Failed</h1>
|
||||||
Couldn't contact Anki Online. Please check your internet connection."""))
|
Couldn't contact Anki Online. Please check your internet connection.""")
|
||||||
|
if self.config['syncInMsgBox']:
|
||||||
|
ui.utils.showWarning(msg)
|
||||||
|
else:
|
||||||
|
self.showToolTip(msg)
|
||||||
|
|
||||||
def openSyncProgress(self):
|
def openSyncProgress(self):
|
||||||
self.syncProgressDialog = QProgressDialog(_("Syncing Media..."),
|
self.syncProgressDialog = QProgressDialog(_("Syncing Media..."),
|
||||||
|
|
Loading…
Reference in a new issue