changeset 6354:626af4af74a5

Removed umlaut stripping for image map and renamed 'Saale Thüringen'.
author Raimund Renkert <rrenkert@intevation.de>
date Mon, 17 Jun 2013 17:39:42 +0200
parents f1a3ea7fb3b6
children d6ae01d6a7cb
files gwt-client/src/main/java/org/dive4elements/river/client/client/ui/LinkSelection.java gwt-client/src/main/webapp/images/FLYS_Karte_interactive.html
diffstat 2 files changed, 5 insertions(+), 37 deletions(-) [+]
line wrap: on
line diff
--- a/gwt-client/src/main/java/org/dive4elements/river/client/client/ui/LinkSelection.java	Mon Jun 17 16:18:40 2013 +0200
+++ b/gwt-client/src/main/java/org/dive4elements/river/client/client/ui/LinkSelection.java	Mon Jun 17 17:39:42 2013 +0200
@@ -309,9 +309,6 @@
 
     private static boolean availableRiver(String river) {
         HLayout row = riverList.get(river);
-        if (row == null) {
-            row = riverList.get(unstripRiver(river));
-        }
         return row != null && row.isVisible();
     }
 
@@ -321,41 +318,11 @@
         }
     }
 
-    /**
-     * Replaces some umlauts to ASCII chars. As JavaScript is extremly
-     * nasty with unicode characters we're doing this in Java.
-     * @param name
-     * @return
-     */
-    private String stripRiver(String name) {
-        return name.replace("\u00fc", "ue");
-    }
-
-    /**
-     * Replaces "ue" with the fitting umlaut unicode character.
-     * FIXME: This is a hack to make the "Saale-Thüringen" river hover effect
-     * working.
-     * @param name
-     * @return
-     */
-    private static String unstripRiver(String name) {
-        return name.replace("ue", "\u00fc");
-    }
-
-    private void callHighlightRiver(String name) {
-        GWT.log(stripRiver(name));
-        __callHighlightRiver(stripRiver(name));
-    }
-
-    private void callUnHighlightRiver(String name) {
-        __callUnHighlightRiver(stripRiver(name));
-    }
-
-    private native void __callHighlightRiver(String name) /*-{
+    private native void callHighlightRiver(String name) /*-{
         $wnd.highlight(name);
     }-*/;
 
-    private native void __callUnHighlightRiver(String name) /*-{
+    private native void callUnHighlightRiver(String name) /*-{
         $wnd.unHighlight(name);
     }-*/;
 
--- a/gwt-client/src/main/webapp/images/FLYS_Karte_interactive.html	Mon Jun 17 16:18:40 2013 +0200
+++ b/gwt-client/src/main/webapp/images/FLYS_Karte_interactive.html	Mon Jun 17 17:39:42 2013 +0200
@@ -77,7 +77,7 @@
         <area id="oder_area" shape="poly" onmouseover="highlight('Oder'); highlightList('Oder')" onmouseout="unHighlight('Oder'); unHighlightList('Oder')" onclick="selectRiver('Oder')" coords="572,143,542,155,542,178,529,203,541,238,565,252,583,273,570,307,603,327,641,320,639,286,633,275,614,269,619,246,635,236,637,195,606,160" />
         <area id="rhein_area" shape="poly" onmouseover="highlight('Rhein'); highlightList('Rhein')" onmouseout="unHighlight('Rhein'); unHighlightList('Rhein')" onclick="selectRiver('Rhein')" coords="86,301,138,317,157,334,153,355,177,381,185,407,198,450,197,464,219,471,224,478,240,473,241,492,269,502,273,523,249,539,254,561,260,570,256,597,227,628,229,639,252,653,277,644,279,668,236,670,237,690,265,687,281,696,283,717,248,728,188,737,170,718,167,669,203,569,222,545,213,521,195,521,193,467,171,459,145,444,122,403,49,391,52,352,23,344,4,304" />
         <area id="saale_area" shape="poly" onmouseover="highlight('Saale'); highlightList('Saale')" onmouseout="unHighlight('Saale'); unHighlightList('Saale')" onclick="selectRiver('Saale')" coords="445,314,414,311,366,299,366,342,395,346,404,356,424,358,477,354,463,341" />
-        <area id="saale_thueringen_area" shape="poly" onmouseover="highlight('Saale-Thueringen'); highlightList('Saale-Thueringen')" onmouseout="unHighlight('Saale-Thueringen'); unHighlightList('Saale-Thueringen')" onclick="selectRiver('Saale-Thueringen')" coords="424,358,476,354,490,384,430,461,375,444,387,415,402,408,420,387,435,383" />
+        <area id="saale_thueringen_area" shape="poly" onmouseover="highlight('Saale-Thüringen'); highlightList('Saale-Thüringen')" onmouseout="unHighlight('Saale-Thüringen'); unHighlightList('Saale-Thüringen')" onclick="selectRiver('Saale-Thüringen')" coords="424,358,476,354,490,384,430,461,375,444,387,415,402,408,420,387,435,383" />
         <area id="saar_area" shape="poly" onmouseover="highlight('Saar'); highlightList('Saar')" onmouseout="unHighlight('Saar'); unHighlightList('Saar')" onclick="selectRiver('Saar')" coords="150,539,129,544,139,564,155,588,181,593,187,565,201,536,195,526,195,512,154,516" />
         <area id="saar_wiltingerbogen_area" shape="poly" onmouseover="highlight('Saar (Wiltinger Bogen)'); highlightList('Saar (Wiltinger Bogen)')" onmouseout="unHighlight('Saar (Wiltinger Bogen)'); unHighlightList('Saar (Wiltinger Bogen)')" onclick="selectRiver('Saar (Wiltinger Bogen)')" coords="139,518,155,516,149,540,130,542" />
         <area id="werra_sommer_area" shape="poly" onmouseover="highlight('Werra (Sommer)'); highlightList('Werra (Sommer)')" onmouseout="unHighlight('Werra (Sommer)'); unHighlightList('Werra (Sommer)')" onclick="selectRiver('Werra (Sommer)')" coords="316,361,334,351,360,342,387,345,398,354,384,372,381,389,371,400,350,390,345,382,336,378,334,372,329,368" />
@@ -120,7 +120,7 @@
       <img src="images/FLYS_Oder.png" style="position: absolute; left: 8px; top: 8px; visibility: hidden; z-index: 50;" id="Oder" >
       <img src="images/FLYS_Rhein.png" style="position: absolute; left: 8px; top: 8px; visibility: hidden; z-index: 50;" id="Rhein" >
       <img src="images/FLYS_Saale.png" style="position: absolute; left: 8px; top: 8px; visibility: hidden; z-index: 50;" id="Saale" >
-      <img src="images/FLYS_Saale_Thueringen.png" style="position: absolute; left: 8px; top: 8px; visibility: hidden; z-index: 50;" id="Saale-Thueringen" >
+      <img src="images/FLYS_Saale_Thueringen.png" style="position: absolute; left: 8px; top: 8px; visibility: hidden; z-index: 50;" id="Saale-Thüringen" >
       <img src="images/FLYS_Saar.png" style="position: absolute; left: 8px; top: 8px; visibility: hidden; z-index: 50;" id="Saar" >
       <img src="images/FLYS_Saar_WiltingerBogen.png" style="position: absolute; left: 8px; top: 8px; visibility: hidden; z-index: 50;" id="Saar (Wiltinger Bogen)" >
       <img src="images/FLYS_Werra_Sommer.png" style="position: absolute; left: 8px; top: 8px; visibility: hidden; z-index: 50;" id="Werra (Sommer)" >
@@ -157,6 +157,7 @@
       <img src="images/FLYS_Neckar_inactive.png" style="position: absolute; left: 8px; top: 8px; visibility: hidden; z-index: 50;" id="Neckar_inactive" >
       <img src="images/FLYS_Neckar_inactive.png" style="position: absolute; left: 8px; top: 8px; visibility: hidden; z-index: 50;" id="Neckar (über Wehrarme)_inactive" >
       <img src="images/FLYS_Saale_inactive.png" style="position: absolute; left: 8px; top: 8px; visibility: hidden; z-index: 50;" id="Saale_inactive" >
+      <img src="images/FLYS_Saale_Thueringen_inactive.png" style="position: absolute; left: 8px; top: 8px; visibility: hidden; z-index: 50;" id="Saale-Thüringen_inactive" >
       <img src="images/FLYS_Saar_inactive.png" style="position: absolute; left: 8px; top: 8px; visibility: hidden; z-index: 50;" id="Saar_inactive" >
       <img src="images/FLYS_Werra_inactive.png" style="position: absolute; left: 8px; top: 8px; visibility: hidden; z-index: 50;" id="Werra (Sommer)_inactive" >
       <img src="images/FLYS_Werra_inactive.png" style="position: absolute; left: 8px; top: 8px; visibility: hidden; z-index: 50;" id="Werra (Winter)_inactive" >

http://dive4elements.wald.intevation.org