The method PrinterJob.lookupStreamPrintServices(java.lang.String) has
been commented out because at that time it was missing another method.
Apparantly this method is already there, so I uncommented this method
and corrected the parameters a little so that we pass a public constant
DocFlavor rather than creating a new one.
2006-12-11 Roman Kennke <[EMAIL PROTECTED]>
* java/awt/print/PrinterJob.java
(lookupStreamPrintServices): Uncommented and fixed parameters.
/Roman
Index: java/awt/print/PrinterJob.java
===================================================================
RCS file: /cvsroot/classpath/classpath/java/awt/print/PrinterJob.java,v
retrieving revision 1.17
diff -u -1 -5 -r1.17 PrinterJob.java
--- java/awt/print/PrinterJob.java 13 May 2006 15:05:12 -0000 1.17
+++ java/awt/print/PrinterJob.java 11 Dec 2006 20:40:50 -0000
@@ -252,39 +252,35 @@
new DocFlavor("application/x-java-jvm-local-objectref",
"java.awt.print.Pageable"),
null);
}
/**
* Find and return 2D image stream print services.
*
* This is the same as calling
* StreamPrintServiceFactory.lookupStreamPrintServices()
* with Pageable service-specified DocFlavor.
* @param mimeType The output format mime type, or null for any type.
* @return Array of stream print services, could be empty.
* @since 1.4
*/
- // FIXME:
- // Enable when StreamPrintServiceFactory has lookupStreamServiceFactories
-// public static StreamPrintServiceFactory[] lookupStreamPrintServices(String mimeType)
-// {
-// return StreamPrintServiceFactory.lookupStreamServiceFactories(
-// new DocFlavor("application/x-java-jvm-local-objectref",
-// "java.awt.print.Pageable"),
-// mimeType);
-// }
+ public static StreamPrintServiceFactory[] lookupStreamPrintServices(String mimeType)
+ {
+ return StreamPrintServiceFactory.lookupStreamPrintServiceFactories(
+ DocFlavor.SERVICE_FORMATTED.PAGEABLE, mimeType);
+ }
/**
* Return the printer for this job. If print services aren't supported by
* the subclass, returns null.
*
* @return The associated PrintService.
* @since 1.4
*/
public PrintService getPrintService()
{
return printer;
}
/**
* Change the printer for this print job to service. Subclasses that