Mercurial > dive4elements > river
comparison gwt-client/src/main/java/org/dive4elements/river/client/client/ui/WikiImgLink.java @ 6231:bfbccad9c3f0
Subclass ImgLink with a new class WikiImgLink
author | Andre Heinecke <aheinecke@intevation.de> |
---|---|
date | Fri, 07 Jun 2013 11:49:03 +0200 |
parents | |
children | a8613826bcac |
comparison
equal
deleted
inserted
replaced
6230:954dbb0806f3 | 6231:bfbccad9c3f0 |
---|---|
1 /* Copyright (C) 2011, 2012, 2013 by Bundesanstalt für Gewässerkunde | |
2 * Software engineering by Intevation GmbH | |
3 * | |
4 * This file is Free Software under the GNU AGPL (>=v3) | |
5 * and comes with ABSOLUTELY NO WARRANTY! Check out the | |
6 * documentation coming with Dive4Elements River for details. | |
7 */ | |
8 | |
9 package org.dive4elements.river.client.client.ui; | |
10 | |
11 import com.smartgwt.client.types.Overflow; | |
12 | |
13 import org.dive4elements.river.client.client.FLYS; | |
14 import org.dive4elements.river.client.client.ui.WikiLinks; | |
15 | |
16 public class WikiImgLink extends ImgLink { | |
17 | |
18 protected FLYS flys; | |
19 | |
20 public WikiImgLink(String imgUrl, String href, int width, int height, FLYS flys) { | |
21 super(imgUrl, href, width, height, false); | |
22 this.flys = flys; | |
23 } | |
24 | |
25 protected void update() { | |
26 setContents(WikiLinks.imageLinkHTML(flys, href, imgUrl)); | |
27 setWidth(width); | |
28 setHeight(height); | |
29 setOverflow(Overflow.VISIBLE); | |
30 } | |
31 } |