mirror of
https://github.com/ankitects/anki.git
synced 2025-09-24 08:46:37 -04:00
dump error on deck load fail, don't update widget on space
This commit is contained in:
parent
1313cca356
commit
4aa958a40f
2 changed files with 2 additions and 7 deletions
|
@ -267,11 +267,7 @@ class FactEditor(object):
|
|||
"Save field text into fact."
|
||||
for (w, f) in self.widgets.items():
|
||||
v = tidyHTML(unicode(w.toHtml()))
|
||||
if not v.strip():
|
||||
# strip blank spaces
|
||||
v = u""
|
||||
w.setText(v)
|
||||
self.fact[f.name] = v
|
||||
self.fact[f.name] = v.strip()
|
||||
self.fact.setModified(textChanged=True)
|
||||
self.deck.setModified()
|
||||
|
||||
|
|
|
@ -5,8 +5,6 @@
|
|||
from PyQt4.QtGui import *
|
||||
from PyQt4.QtCore import *
|
||||
|
||||
# fixme: sample files read only, need to copy
|
||||
|
||||
import os, sys, re, types, gettext, stat, traceback
|
||||
import copy, shutil, time, glob
|
||||
|
||||
|
@ -413,6 +411,7 @@ class AnkiQt(QMainWindow):
|
|||
if interactive:
|
||||
ui.utils.showInfo(_("Deck is already open."))
|
||||
else:
|
||||
traceback.print_exc()
|
||||
ui.utils.showInfo(_("""\
|
||||
Unable to load deck.
|
||||
|
||||
|
|
Loading…
Reference in a new issue