[Kde-print-devel] [Bug 112536] kprinter fails to detect options for cups printer classes
Cristian Tibirna
tibirna at kde.org
Mon Nov 14 04:21:30 CET 2005
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
http://bugs.kde.org/show_bug.cgi?id=112536
tibirna kde org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution| |FIXED
------- Additional Comments From tibirna kde org 2005-11-14 04:21 -------
SVN commit 480261 by tibirna:
patch from Patrick Gosling (jpmg eng cam ac uk) for selecting the
PPD of first printer in a class.
BUG:112536
M +18 -1 kmcupsmanager.cpp
--- branches/KDE/3.5/kdelibs/kdeprint/cups/kmcupsmanager.cpp #480260:480261
@ -524,9 +524,26 @
DrMain* KMCupsManager::loadPrinterDriver(KMPrinter *p, bool)
{
- if (!p || p->isClass(true))
+ if (!p)
return NULL;
+ if (p->isClass(true))
+ {
+ KMPrinter *first_class_member = NULL;
+ /* find the first printer in the class */
+ first_class_member = findPrinter(p->members().first());
+
+ if (first_class_member == NULL)
+ {
+ /* we didn't find a printer in the class */
+ return NULL;
+ }
+ else
+ {
+ p = first_class_member;
+ }
+ }
+
QString fname = downloadDriver(p);
DrMain *driver(0);
if (!fname.isEmpty())
More information about the Kde-print-devel
mailing list