Changeset 1195 in josm for trunk/src/org/openstreetmap/josm/gui/dialogs
- Timestamp:
- 2008-12-31T00:36:58+01:00 (15 years ago)
- Location:
- trunk/src/org/openstreetmap/josm/gui/dialogs
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/gui/dialogs/RelationEditor.java
r1169 r1195 14 14 import java.beans.PropertyChangeListener; 15 15 import java.io.IOException; 16 import java.lang.reflect.Array;17 16 import java.text.Collator; 18 17 import java.util.ArrayList; … … 304 303 upDownPanel.setLayout(new BoxLayout(upDownPanel, BoxLayout.Y_AXIS)); 305 304 306 307 308 upDownPanel.add(createButton(null, "moveup", tr("Move the currently selected member(s) up"), 305 upDownPanel.add(createButton(null, "moveup", tr("Move the currently selected members up"), 309 306 KeyEvent.VK_U, new ActionListener() { 310 307 public void actionPerformed(ActionEvent e) { … … 312 309 } 313 310 })); 314 upDownPanel.add(createButton(null, "movedown", tr("Move the currently selected member (s)down"),311 upDownPanel.add(createButton(null, "movedown", tr("Move the currently selected members down"), 315 312 KeyEvent.VK_N, new ActionListener() { 316 313 public void actionPerformed(ActionEvent e) { -
trunk/src/org/openstreetmap/josm/gui/dialogs/SelectionListDialog.java
r1084 r1195 4 4 import static org.openstreetmap.josm.tools.I18n.marktr; 5 5 import static org.openstreetmap.josm.tools.I18n.tr; 6 import static org.openstreetmap.josm.tools.I18n.trn; 6 7 7 8 import java.awt.BorderLayout; … … 37 38 import org.openstreetmap.josm.data.osm.Node; 38 39 import org.openstreetmap.josm.data.osm.OsmPrimitive; 40 import org.openstreetmap.josm.data.osm.Relation; 39 41 import org.openstreetmap.josm.data.osm.Way; 40 42 import org.openstreetmap.josm.data.osm.visitor.BoundingXYVisitor; … … 286 288 int ways = 0; 287 289 int nodes = 0; 290 int relations = 0; 288 291 for (OsmPrimitive o : sel) { 289 292 if (o instanceof Way) … … 291 294 else if (o instanceof Node) 292 295 nodes++; 293 } 294 setText(String.format(tr("Selection: %d way(s) and %d node(s)"), new Object[] { ways, nodes })); 296 else if (o instanceof Relation) 297 relations++; 298 } 299 String text = ""; 300 if(ways != 0) 301 text += (text.length() > 0 ? ", " : "") 302 + trn("{0} way", "{0} ways", ways, ways); 303 if(nodes != 0) 304 text += (text.length() > 0 ? ", " : "") 305 + trn("{0} node", "{0} nodes", nodes, nodes); 306 if(relations != 0) 307 text += (text.length() > 0 ? ", " : "") 308 + trn("{0} relation", "{0} relations", relations, relations); 309 setText(tr("Selection: {0}", text)); 295 310 addActionListener(this); 296 311 }
Note:
See TracChangeset
for help on using the changeset viewer.