]> source.dussan.org Git - xmlgraphics-fop.git/commitdiff
Method signature wrong, was using super class implementation.
authorAdrian Cumiskey <acumiskey@apache.org>
Wed, 19 Nov 2008 13:51:25 +0000 (13:51 +0000)
committerAdrian Cumiskey <acumiskey@apache.org>
Wed, 19 Nov 2008 13:51:25 +0000 (13:51 +0000)
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/branches/Temp_AFPGOCAResources@718958 13f79535-47bb-0310-9956-ffa450edef68

src/java/org/apache/fop/render/afp/AFPImageHandlerXML.java

index fee355da7920865d1e57f7e7ee64f467d6b51a78..b7345811a2555c3b595911fd90629af692c36164 100644 (file)
 
 package org.apache.fop.render.afp;
 
-import java.awt.Point;
-import java.awt.Rectangle;
+import java.awt.geom.Rectangle2D;
 import java.io.IOException;
 import java.util.Map;
 
 import org.apache.fop.afp.AFPDataObjectInfo;
 import org.apache.fop.render.RendererContext;
 import org.apache.fop.render.RendererContextConstants;
-import org.apache.xmlgraphics.image.loader.Image;
 import org.apache.xmlgraphics.image.loader.ImageFlavor;
 import org.apache.xmlgraphics.image.loader.impl.ImageXMLDOM;
 import org.w3c.dom.Document;
@@ -46,15 +44,16 @@ public class AFPImageHandlerXML extends AFPImageHandler {
     };
 
     /** {@inheritDoc} */
-    public AFPDataObjectInfo generateDataObjectInfo(RendererContext context, Image image,
-            Point origin, Rectangle pos)
+    public AFPDataObjectInfo generateDataObjectInfo(AFPRendererImageInfo rendererImageInfo)
             throws IOException {
-        AFPRenderer renderer = (AFPRenderer)context.getRenderer();
-        ImageXMLDOM imgXML = (ImageXMLDOM)image;
+        RendererContext rendererContext = rendererImageInfo.getRendererContext();
+        AFPRenderer renderer = (AFPRenderer)rendererContext.getRenderer();
+        ImageXMLDOM imgXML = (ImageXMLDOM)rendererImageInfo.getImage();
         Document doc = imgXML.getDocument();
         String ns = imgXML.getRootNamespace();
-        Map foreignAttributes = (Map)context.getProperty(
+        Map foreignAttributes = (Map)rendererContext.getProperty(
                 RendererContextConstants.FOREIGN_ATTRIBUTES);
+        Rectangle2D pos = rendererImageInfo.getPosition();
         renderer.renderDocument(doc, ns, pos, foreignAttributes);
         return null;
     }