rpms/system-config-printer/F-12 system-config-printer-duplicate-current.patch, NONE, 1.1 system-config-printer.spec, 1.353, 1.354

Tim Waugh twaugh at fedoraproject.org
Mon Jan 25 16:27:35 UTC 2010


Author: twaugh

Update of /cvs/pkgs/rpms/system-config-printer/F-12
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv28426

Modified Files:
	system-config-printer.spec 
Added Files:
	system-config-printer-duplicate-current.patch 
Log Message:
* Mon Jan 25 2010 Tim Waugh <twaugh at redhat.com> - 1.1.16-13
- Only add current device to list when all devices found (bug #558524).


system-config-printer-duplicate-current.patch:
 system-config-printer.py |    8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

--- NEW FILE system-config-printer-duplicate-current.patch ---
diff -up system-config-printer-1.1.16/system-config-printer.py.duplicate-current system-config-printer-1.1.16/system-config-printer.py
--- system-config-printer-1.1.16/system-config-printer.py.duplicate-current	2010-01-25 16:03:02.859210318 +0000
+++ system-config-printer-1.1.16/system-config-printer.py	2010-01-25 16:03:38.617208297 +0000
@@ -4828,7 +4828,7 @@ class NewPrinterGUI(GtkGUI):
         gobject.idle_add (self.queryPPDs)
 
         # Add the network devices to the list.
-        self.add_devices (result, current_uri)
+        self.add_devices (result, current_uri, no_more=True)
 
     def install_hplip_plugin(self, uri):
         """
@@ -5171,16 +5171,18 @@ class NewPrinterGUI(GtkGUI):
         self.fetchDevices_conn._begin_operation (_("fetching device list"))
         self.fetchDevices (network=False, current_uri=current_uri)
 
-    def add_devices (self, devices, current_uri):
+    def add_devices (self, devices, current_uri, no_more=False):
         if current_uri:
             if devices.has_key (current_uri):
                 current = devices.pop(current_uri)
             elif devices.has_key (current_uri.replace (":9100", "")):
                 current_uri = current_uri.replace (":9100", "")
                 current = devices.pop(current_uri)
-            else:
+            elif no_more:
                 current = cupshelpers.Device (current_uri)
                 current.info = "Current device"
+            else:
+                current_uri = None
 
         devices = devices.values()
 


Index: system-config-printer.spec
===================================================================
RCS file: /cvs/pkgs/rpms/system-config-printer/F-12/system-config-printer.spec,v
retrieving revision 1.353
retrieving revision 1.354
diff -u -p -r1.353 -r1.354
--- system-config-printer.spec	24 Jan 2010 11:59:00 -0000	1.353
+++ system-config-printer.spec	25 Jan 2010 16:27:35 -0000	1.354
@@ -7,7 +7,7 @@
 Summary: A printer administration tool
 Name: system-config-printer
 Version: 1.1.16
-Release: 12%{?dist}
+Release: 13%{?dist}
 License: GPLv2+
 URL: http://cyberelk.net/tim/software/system-config-printer/
 Group: System Environment/Base
@@ -34,6 +34,7 @@ Patch16: system-config-printer-statereas
 Patch17: system-config-printer-asyncpk0-fallback.patch
 Patch18: system-config-printer-async-fallback-2.patch
 Patch19: system-config-printer-raw-statereason.patch
+Patch20: system-config-printer-duplicate-current.patch
 
 BuildRequires: cups-devel >= 1.2
 BuildRequires: python-devel >= 2.4
@@ -112,6 +113,7 @@ printers.
 %patch17 -p1 -b .asyncpk0-fallback
 %patch18 -p1 -b .async-fallback-2
 %patch19 -p1 -b .raw-statereason
+%patch20 -p1 -b .duplicate-current
 
 %build
 %configure --with-udev-rules --with-polkit-1
@@ -228,6 +230,9 @@ rm -rf %buildroot
 exit 0
 
 %changelog
+* Mon Jan 25 2010 Tim Waugh <twaugh at redhat.com> - 1.1.16-13
+- Only add current device to list when all devices found (bug #558524).
+
 * Sun Jan 24 2010 Tim Waugh <twaugh at redhat.com> - 1.1.16-12
 - Fixed statereason localization for raw queues (bug #558156).
 - Fixed async fallback again (bug #557854).



More information about the scm-commits mailing list