Mercurial > dive4elements > river
comparison gwt-client/src/main/java/org/dive4elements/river/client/client/ui/WikiLinks.java @ 8856:5e38e2924c07 3.2.x
Fix code style.
author | Tom Gottfried <tom@intevation.de> |
---|---|
date | Thu, 18 Jan 2018 20:12:01 +0100 |
parents | bef9937a2dd9 |
children |
comparison
equal
deleted
inserted
replaced
8855:d7c005e12af0 | 8856:5e38e2924c07 |
---|---|
20 import org.dive4elements.river.client.client.FLYS; | 20 import org.dive4elements.river.client.client.FLYS; |
21 import org.dive4elements.river.client.shared.model.User; | 21 import org.dive4elements.river.client.shared.model.User; |
22 | 22 |
23 public class WikiLinks | 23 public class WikiLinks |
24 { | 24 { |
25 public static String imageLinkForm(FLYS instance, String url, String imageUrl, String formName) { | 25 public static String imageLinkForm( |
26 FLYS instance, | |
27 String url, | |
28 String imageUrl, | |
29 String formName | |
30 ) { | |
26 String saml = null; | 31 String saml = null; |
27 if (instance != null && instance.getCurrentUser() != null) { | 32 if (instance != null && instance.getCurrentUser() != null) { |
28 saml = instance.getCurrentUser().getSamlXMLBase64(); | 33 saml = instance.getCurrentUser().getSamlXMLBase64(); |
29 } | 34 } |
30 String quotedUrl = SafeHtmlUtils.htmlEscape(url); | 35 String quotedUrl = SafeHtmlUtils.htmlEscape(url); |
37 + SafeHtmlUtils.htmlEscape(saml) + "\">" | 42 + SafeHtmlUtils.htmlEscape(saml) + "\">" |
38 + "<input type=\"image\" src=\""+ quotedImage + "\">" | 43 + "<input type=\"image\" src=\""+ quotedImage + "\">" |
39 + "</form>"; | 44 + "</form>"; |
40 } | 45 } |
41 else { | 46 else { |
42 return "<a href=\"" + quotedUrl + "\"><img src=\"" + quotedImage + "\"></a>"; | 47 return "<a href=\"" + quotedUrl |
48 + "\"><img src=\"" + quotedImage + "\"></a>"; | |
43 } | 49 } |
44 } | 50 } |
45 | 51 |
46 public static DynamicForm linkDynamicForm(FLYS flys, String url, String text) { | 52 public static DynamicForm linkDynamicForm( |
53 FLYS flys, | |
54 String url, | |
55 String text | |
56 ) { | |
47 User currentUser = flys.getCurrentUser(); | 57 User currentUser = flys.getCurrentUser(); |
48 String quotedUrl = SafeHtmlUtils.htmlEscape(url); | 58 String quotedUrl = SafeHtmlUtils.htmlEscape(url); |
49 String quotedText = SafeHtmlUtils.htmlEscape(text); | 59 String quotedText = SafeHtmlUtils.htmlEscape(text); |
50 | 60 |
51 if (currentUser != null) { | 61 if (currentUser != null) { |