# HG changeset patch # User Felix Wolfsteller # Date 1319453619 0 # Node ID 9da7fdfbb80e95b3842ea4f708fb620fdc039882 # Parent 670fd067bd801c8a31e633153cf1e4bcf3e85673 Fix flys/issue390 (W-Diff: Icon zum Löschen anpassen). flys-client/trunk@3061 c6561f87-3c4e-4783-a992-168aeb5c3f6f diff -r 670fd067bd80 -r 9da7fdfbb80e flys-client/src/main/java/de/intevation/flys/client/client/ui/DatacageTwinPanel.java --- a/flys-client/src/main/java/de/intevation/flys/client/client/ui/DatacageTwinPanel.java Mon Oct 24 10:48:11 2011 +0000 +++ b/flys-client/src/main/java/de/intevation/flys/client/client/ui/DatacageTwinPanel.java Mon Oct 24 10:53:39 2011 +0000 @@ -137,14 +137,13 @@ // Split this string. // Create according recommendations and display strings. String[] recs = from.split("#"); - // TODO real name if (recs.length % 2 != 0) return; for (int i = 0; i < recs.length; i+=2) { Recommendation minuend = createRecommendationFromString(recs[i+0]); Recommendation subtrahend = createRecommendationFromString(recs[i+1]); - //minuend.setDisplayName("hum"); subtrahend.setDisplayName("wim"); + RecommendationPairRecord pr = new RecommendationPairRecord( minuend, subtrahend); // This Recommendation Pair comes from the data string and was thus @@ -235,9 +234,7 @@ final ListGridField removeField = new ListGridField("_removeRecord", "Remove Record"){{ setType(ListGridFieldType.ICON); - // TODO evaluate which icon to use (and how). - //setIcon("images/removeFeature.png"); - setIcon("[SKIN]/actions/remove.png"); + setIcon(GWT.getHostPageBaseURL() + MSG.removeFeature()); setCanEdit(false); setCanFilter(false); setCanSort(false); @@ -306,7 +303,7 @@ // TODO differentiate and merge: new clones, new, old. Recommendation firstR = r.getFirst(); if(firstR.getIDs() != null) { - GWT.log("First IDs: " + firstR.getIDs()); + GWT.log("First IDs: " + firstR.getIDs() + " factory: " + firstR.getFactory()); } // TODO resolve this hack, fix datacage/recommendation for this case. if(firstR.getIDs() != null && @@ -320,7 +317,7 @@ } Recommendation secondR = r.getSecond(); if(secondR.getIDs() != null) { - GWT.log("Second IDs: " + secondR.getIDs()); + GWT.log("Second IDs: " + secondR.getIDs() + " factory: " + secondR.getFactory()); } if(secondR.getIDs() != null && secondR.getIDs().startsWith("flood_protection")) @@ -457,6 +454,8 @@ /** * Creates part of the String that encodes minuend or subtrahend. + * @param artifact Artifacts UUID. + * @param recommendation Recommendation to wrap in string. */ protected String createDataString( String artifact, @@ -478,11 +477,18 @@ } } - // Hell get the creepy name inside. - return "[" + artifact + ";" + f.getName() + ";" + f.getIndex() + ";" + recommendation.getDisplayName() + "]"; + return "[" + artifact + ";" + + f.getName() + + ";" + + f.getIndex() + + ";" + + recommendation.getDisplayName() + "]"; } else { - return "[" + artifact + ";staticwkms;0;" + recommendation.getDisplayName() + "]"; + return "[" + + artifact + + ";staticwkms;0;" + + recommendation.getDisplayName() + "]"; } } }