From bc05b6aac789b46735080d1185ab45ccfd5b17c1 Mon Sep 17 00:00:00 2001 From: chkr Date: Feb 28 2010 18:02:52 +0000 Subject: - Add a patch to fix a crash when sys tray icon is enabled (BZ 567672) --- diff --git a/0001-Fix-crash-with-enabled-sys-tray-icon.patch b/0001-Fix-crash-with-enabled-sys-tray-icon.patch new file mode 100644 index 0000000..9a514fb --- /dev/null +++ b/0001-Fix-crash-with-enabled-sys-tray-icon.patch @@ -0,0 +1,16 @@ +diff --git a/ankiqt/ui/tray.py b/ankiqt/ui/tray.py +index 615738c..b63ef77 100644 +--- a/ankiqt/ui/tray.py ++++ b/ankiqt/ui/tray.py +@@ -29,7 +29,7 @@ class AnkiTrayIcon(QtCore.QObject): + mw.addView(self) + mw.connect(self.ti, QtCore.SIGNAL("activated(QSystemTrayIcon::ActivationReason)"),lambda i: self.activated(i)) + mw.connect(self.ti, QtCore.SIGNAL("messageClicked()"), lambda : self.messageClicked()) +- mw.connect(self.mw.app, QtCore.SIGNAL("focusChanged(QWidget*,QWidget*)"), lambda old,now: self.focusChanged(old,now)) ++ mw.connect(self.mw.app, QtCore.SIGNAL("focusChanged(QWidget*,QWidget*)"), self.focusChanged) + self.ti.show() + + def showAll(self): +-- +1.6.2.5 + diff --git a/anki.spec b/anki.spec index 63a32ed..1cf2962 100644 --- a/anki.spec +++ b/anki.spec @@ -2,7 +2,7 @@ Name: anki Version: 0.9.9.8.6 -Release: 1%{?dist} +Release: 2%{?dist} Summary: Flashcard program for using space repetition learning Group: Amusements/Games @@ -21,6 +21,8 @@ Source1: generate-anki-tarball.sh # Config change: don't check for new updates. Patch0: anki-0.9.9.8.6-noupdate.patch +# https://bugzilla.redhat.com/show_bug.cgi?id=567672 +Patch1: 0001-Fix-crash-with-enabled-sys-tray-icon.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: python-devel, python-setuptools, python-sqlalchemy BuildRequires: desktop-file-utils, PyQt4 @@ -38,6 +40,7 @@ as possible. Anki is based on a theory called spaced repetition. %prep %setup -q %patch0 -p1 -b .noupdate +%patch1 -p1 -b .trayicon_crash %build pushd libanki @@ -107,6 +110,9 @@ rm -rf %{buildroot} %{_datadir}/pixmaps/%{name}.png %changelog +* Sun Feb 28 2010 Christian Krause - 0.9.9.8.6-2 +- Add a patch to fix a crash when sys tray icon is enabled (BZ 567672) + * Fri Feb 19 2010 Christian Krause - 0.9.9.8.6-1 - Update to new upstream version - Remove example files from upstream tarball due to unknown license