comparison gwt-client/src/main/java/org/dive4elements/river/client/client/ui/WikiImgLink.java @ 6233:a8613826bcac

Call update after setting the instance Also adds an override and changes the ambigousness of the variable name "flys"
author Andre Heinecke <aheinecke@intevation.de>
date Fri, 07 Jun 2013 13:06:20 +0200
parents bfbccad9c3f0
children a52a038a6a09
comparison
equal deleted inserted replaced
6232:175df4c01ae7 6233:a8613826bcac
13 import org.dive4elements.river.client.client.FLYS; 13 import org.dive4elements.river.client.client.FLYS;
14 import org.dive4elements.river.client.client.ui.WikiLinks; 14 import org.dive4elements.river.client.client.ui.WikiLinks;
15 15
16 public class WikiImgLink extends ImgLink { 16 public class WikiImgLink extends ImgLink {
17 17
18 protected FLYS flys; 18 protected FLYS instance;
19 19
20 public WikiImgLink(String imgUrl, String href, int width, int height, FLYS flys) { 20 public WikiImgLink(String imgUrl, String href, int width, int height, FLYS instance) {
21 super(imgUrl, href, width, height, false); 21 super(imgUrl, href, width, height, false);
22 this.flys = flys; 22 this.instance = instance;
23 update();
23 } 24 }
24 25
26 @Override
25 protected void update() { 27 protected void update() {
26 setContents(WikiLinks.imageLinkHTML(flys, href, imgUrl)); 28 setContents(WikiLinks.imageLinkHTML(instance, href, imgUrl));
27 setWidth(width); 29 setWidth(width);
28 setHeight(height); 30 setHeight(height);
29 setOverflow(Overflow.VISIBLE); 31 setOverflow(Overflow.VISIBLE);
30 } 32 }
31 } 33 }

http://dive4elements.wald.intevation.org