From 27dc1f3fdb67e898633d0612caaea92d6e6c6410 Mon Sep 17 00:00:00 2001 From: Alex Yatskov Date: Tue, 25 Dec 2012 08:39:21 -0800 Subject: [PATCH] fixes --- yomi_base/anki_host.py | 3 ++- yomi_base/reader.py | 2 +- yomi_base/ui/about.ui | 4 ++-- yomi_base/update.py | 1 - yomichan.py | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/yomi_base/anki_host.py b/yomi_base/anki_host.py index 6a2a9e1..e38772c 100644 --- a/yomi_base/anki_host.py +++ b/yomi_base/anki_host.py @@ -66,7 +66,8 @@ class Anki: def stopEditing(self): - self.window().maybeReset() + if self.collection(): + self.window().maybeReset() def window(self): diff --git a/yomi_base/reader.py b/yomi_base/reader.py index c546fe3..24173f9 100644 --- a/yomi_base/reader.py +++ b/yomi_base/reader.py @@ -293,7 +293,7 @@ class MainWindowReader(QtGui.QMainWindow): def onUpdaterSearchResult(self, result): - if result is not None and result > constants['version']: + if result and unicode(result) > constants['version']: QtGui.QMessageBox.information( self, 'Yomichan', diff --git a/yomi_base/ui/about.ui b/yomi_base/ui/about.ui index 25a364f..c0538fc 100644 --- a/yomi_base/ui/about.ui +++ b/yomi_base/ui/about.ui @@ -6,7 +6,7 @@ 0 0 - 600 + 700 400 @@ -53,7 +53,7 @@ - (c) 2011 by Alex Yatskov + (c) 2012 by Alex Yatskov diff --git a/yomi_base/update.py b/yomi_base/update.py index 05856ee..e4315dc 100644 --- a/yomi_base/update.py +++ b/yomi_base/update.py @@ -16,7 +16,6 @@ # along with this program. If not, see . -import os import urllib2 from xml.dom import minidom from PyQt4 import QtCore diff --git a/yomichan.py b/yomichan.py index 6fe4107..66ce431 100755 --- a/yomichan.py +++ b/yomichan.py @@ -77,7 +77,7 @@ class YomichanStandalone(Yomichan): self.window = MainWindowReader( None, self.preferences, - self.languages, + self.language, filename=sys.argv[1] if len(sys.argv) >= 2 else None )