Update of /var/cvs/applications/resources/src/org/mmbase/module/builders
In directory james.mmbase.org:/tmp/cvs-serv6554

Modified Files:
        Images.java 
Log Message:
adding filenames to gui urls too


See also: 
http://cvs.mmbase.org/viewcvs/applications/resources/src/org/mmbase/module/builders


Index: Images.java
===================================================================
RCS file: 
/var/cvs/applications/resources/src/org/mmbase/module/builders/Images.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -b -r1.9 -r1.10
--- Images.java 14 Jul 2008 12:30:08 -0000      1.9
+++ Images.java 5 Sep 2008 16:39:00 -0000       1.10
@@ -32,7 +32,7 @@
  * @author Daniel Ockeloen
  * @author Rico Jansen
  * @author Michiel Meeuwissen
- * @version $Id: Images.java,v 1.9 2008/07/14 12:30:08 nklasens Exp $
+ * @version $Id: Images.java,v 1.10 2008/09/05 16:39:00 michiel Exp $
  */
 public class Images extends AbstractImages {
 
@@ -236,6 +236,7 @@
      * @since MMBase-1.6
      */
     protected String getGUIIndicatorWithAlt(MMObjectNode node, String alt, 
Parameters args) {
+        log.debug("gui for image");
         int num = node.getNumber();
         if (num < 0) {   // image servlet cannot handle uncommited images..
             return "...";
@@ -325,6 +326,17 @@
                 title = " title=\"" + getMimeType(node) + "\"";
             }
         }
+        if(addFileName(node, image)) {
+            StringBuilder buf = new StringBuilder(image);
+            buf.append('/');
+            image = getFileName(node, buf).toString();
+        }
+        if(addFileName(node, imageThumb)) {
+            StringBuilder buf = new StringBuilder(imageThumb);
+            buf.append('/');
+            imageThumb = getFileName(node, buf).toString();
+        }
+
 
         return
             "<a href=\"" + image + "\" class=\"mm_gui\" 
onclick=\"window.open(this.href); return false;\"><img src=\"" + imageThumb + 
"\" " +
_______________________________________________
Cvs mailing list
Cvs@lists.mmbase.org
http://lists.mmbase.org/mailman/listinfo/cvs

Reply via email to