From 1342bc0baddad195a1be588792b548a49bb105e6 Mon Sep 17 00:00:00 2001 From: Tim Waugh Date: Wed, 26 Aug 2009 11:34:34 +0000 Subject: [PATCH] - Fixed traceback in on_tvNPDeviceURIs_cursor_changed (bug #519367). --- system-config-printer-get_cursor.patch | 17 +++++++++++++++++ system-config-printer.spec | 7 ++++++- 2 files changed, 23 insertions(+), 1 deletion(-) create mode 100644 system-config-printer-get_cursor.patch diff --git a/system-config-printer-get_cursor.patch b/system-config-printer-get_cursor.patch new file mode 100644 index 0000000..cb46a15 --- /dev/null +++ b/system-config-printer-get_cursor.patch @@ -0,0 +1,17 @@ +diff -up system-config-printer-1.1.12/system-config-printer.py.get_cursor system-config-printer-1.1.12/system-config-printer.py +--- system-config-printer-1.1.12/system-config-printer.py.get_cursor 2009-08-25 17:01:28.000000000 +0100 ++++ system-config-printer-1.1.12/system-config-printer.py 2009-08-26 12:32:02.757680412 +0100 +@@ -5655,7 +5655,12 @@ class NewPrinterGUI(GtkGUI): + self.expNPDeviceURIs.hide () + + def on_tvNPDeviceURIs_cursor_changed(self, widget): +- model, iter = widget.get_selection().get_selected() ++ path, column = widget.get_cursor () ++ if path == None: ++ return ++ ++ model = widget.get_model () ++ iter = model.get_iter (path) + device = model.get_value(iter, 1) + self.device = device + self.lblNPDeviceDescription.set_text ('') diff --git a/system-config-printer.spec b/system-config-printer.spec index 73de42c..9acbe09 100644 --- a/system-config-printer.spec +++ b/system-config-printer.spec @@ -7,13 +7,14 @@ Summary: A printer administration tool Name: system-config-printer Version: 1.1.12 -Release: 1%{?dist} +Release: 2%{?dist} License: GPLv2+ URL: http://cyberelk.net/tim/software/system-config-printer/ Group: System Environment/Base Source0: http://cyberelk.net/tim/data/system-config-printer/1.1/system-config-printer-%{version}.tar.xz Source1: http://cyberelk.net/tim/data/pycups/pycups-%{pycups_version}.tar.bz2 Source2: http://cyberelk.net/tim/data/pysmbc/pysmbc-%{pysmbc_version}.tar.bz2 +Patch1: system-config-printer-get_cursor.patch BuildRequires: cups-devel >= 1.2 BuildRequires: python-devel >= 2.4 @@ -74,6 +75,7 @@ printers. %prep %setup -q -a 1 -a 2 +%patch1 -p1 -b .get_cursor %build %configure --with-udev-rules @@ -185,6 +187,9 @@ rm -rf %buildroot exit 0 %changelog +* Wed Aug 26 2009 Tim Waugh 1.1.12-2 +- Fixed traceback in on_tvNPDeviceURIs_cursor_changed (bug #519367). + * Tue Aug 25 2009 Tim Waugh 1.1.12-1 - 1.1.12: - Troubleshooting fix.