From f8935dc8aabfbd9283db653b8f29a32435f84842 Mon Sep 17 00:00:00 2001 From: Tim Waugh Date: Fri, 18 Sep 2009 12:10:03 +0000 Subject: [PATCH] - Fixed data button state. --- system-config-printer-data-button-state.patch | 32 +++++++++++++++++++ system-config-printer.spec | 8 ++++- 2 files changed, 39 insertions(+), 1 deletion(-) create mode 100644 system-config-printer-data-button-state.patch diff --git a/system-config-printer-data-button-state.patch b/system-config-printer-data-button-state.patch new file mode 100644 index 0000000..08a1dba --- /dev/null +++ b/system-config-printer-data-button-state.patch @@ -0,0 +1,32 @@ +diff -up system-config-printer-1.1.13/system-config-printer.py.data-button-state system-config-printer-1.1.13/system-config-printer.py +--- system-config-printer-1.1.13/system-config-printer.py.data-button-state 2009-09-04 18:12:11.000000000 +0100 ++++ system-config-printer-1.1.13/system-config-printer.py 2009-09-18 13:04:40.062438371 +0100 +@@ -1907,19 +1907,20 @@ class GUI(GtkGUI, monitor.Watcher): + # set buttons sensitivity + def setDataButtonState(self): + try: +- possible = (self.ppd and +- not bool (self.changed) and +- self.printer.enabled and +- not self.printer.rejecting) ++ printable = (self.ppd and ++ not bool (self.changed) and ++ self.printer.enabled and ++ not self.printer.rejecting) + +- self.btnPrintTestPage.set_sensitive (possible) ++ self.btnPrintTestPage.set_sensitive (printable) ++ adjustable = not (self.discovered or bool (self.changed)) + for button in [self.btnChangePPD, + self.btnSelectDevice]: +- button.set_sensitive (not bool (self.changed)) ++ button.set_sensitive (adjustable) + + commands = (self.printer.type & cups.CUPS_PRINTER_COMMANDS) != 0 +- self.btnSelfTest.set_sensitive (commands and possible) +- self.btnCleanHeads.set_sensitive (commands and possible) ++ self.btnSelfTest.set_sensitive (commands and printable) ++ self.btnCleanHeads.set_sensitive (commands and printable) + except: + pass + diff --git a/system-config-printer.spec b/system-config-printer.spec index 6d9900b..301f37a 100644 --- a/system-config-printer.spec +++ b/system-config-printer.spec @@ -7,7 +7,7 @@ Summary: A printer administration tool Name: system-config-printer Version: 1.1.13 -Release: 1%{?dist} +Release: 2%{?dist} License: GPLv2+ URL: http://cyberelk.net/tim/software/system-config-printer/ Group: System Environment/Base @@ -15,6 +15,8 @@ Source0: http://cyberelk.net/tim/data/system-config-printer/1.1/system-config-pr 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-data-button-state.patch + BuildRequires: cups-devel >= 1.2 BuildRequires: python-devel >= 2.4 BuildRequires: libsmbclient-devel >= 3.2 @@ -74,6 +76,7 @@ printers. %prep %setup -q -a 1 -a 2 +%patch1 -p1 -b .data-button-state %build %configure --with-udev-rules --with-polkit-1 @@ -185,6 +188,9 @@ rm -rf %buildroot exit 0 %changelog +* Fri Sep 18 2009 Tim Waugh 1.1.13-2 +- Fixed data button state. + * Mon Sep 14 2009 Tim Waugh 1.1.13-1 - 1.1.13: - Translation updates (bug #522451).