- Timestamp:
- 2016-03-30T02:55:55+02:00 (9 years ago)
- Location:
- trunk/src/org/openstreetmap/josm/gui
- Files:
-
- 1 deleted
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/gui/tagging/TagTable.java
r10070 r10082 38 38 import org.openstreetmap.josm.data.osm.Relation; 39 39 import org.openstreetmap.josm.data.osm.Tag; 40 import org.openstreetmap.josm.gui.dialogs.relation.RunnableAction;41 40 import org.openstreetmap.josm.gui.tagging.ac.AutoCompletionList; 42 41 import org.openstreetmap.josm.gui.tagging.ac.AutoCompletionManager; … … 162 161 * 163 162 */ 164 class DeleteAction extends RunnableAction implements ListSelectionListener {163 class DeleteAction extends AbstractAction implements ListSelectionListener { 165 164 166 165 DeleteAction() { … … 197 196 198 197 @Override 199 public void run() {198 public void actionPerformed(ActionEvent e) { 200 199 if (!isEnabled()) 201 200 return; … … 251 250 * 252 251 */ 253 class AddAction extends RunnableAction implements PropertyChangeListener {252 class AddAction extends AbstractAction implements PropertyChangeListener { 254 253 AddAction() { 255 254 putValue(SMALL_ICON, ImageProvider.get("dialogs", "add")); … … 260 259 261 260 @Override 262 public void run() {261 public void actionPerformed(ActionEvent e) { 263 262 CellEditor editor = getCellEditor(); 264 263 if (editor != null) { … … 285 284 * Action to be run when the user wants to paste tags from buffer 286 285 */ 287 class PasteAction extends RunnableAction implements PropertyChangeListener {286 class PasteAction extends AbstractAction implements PropertyChangeListener { 288 287 PasteAction() { 289 288 putValue(SMALL_ICON, ImageProvider.get("", "pastetags")); … … 294 293 295 294 @Override 296 public void run() {295 public void actionPerformed(ActionEvent e) { 297 296 Relation relation = new Relation(); 298 297 model.applyToPrimitive(relation); … … 333 332 334 333 /** the delete action */ 335 private RunnableAction deleteAction;334 private DeleteAction deleteAction; 336 335 337 336 /** the add action */ 338 private RunnableAction addAction;337 private AddAction addAction; 339 338 340 339 /** the tag paste action */ 341 private RunnableAction pasteAction;342 343 /** 344 * 340 private PasteAction pasteAction; 341 342 /** 343 * Returns the delete action. 345 344 * @return the delete action used by this table 346 345 */ 347 public RunnableAction getDeleteAction() {346 public DeleteAction getDeleteAction() { 348 347 return deleteAction; 349 348 } 350 349 351 public RunnableAction getAddAction() { 350 /** 351 * Returns the add action. 352 * @return the add action used by this table 353 */ 354 public AddAction getAddAction() { 352 355 return addAction; 353 356 } 354 357 355 public RunnableAction getPasteAction() { 358 /** 359 * Returns the paste action. 360 * @return the paste action used by this table 361 */ 362 public PasteAction getPasteAction() { 356 363 return pasteAction; 357 364 } … … 429 436 // 430 437 return super.processKeyBinding(ks, e, condition, pressed); 431 getDeleteAction(). run();438 getDeleteAction().actionPerformed(null); 432 439 } 433 440 return super.processKeyBinding(ks, e, condition, pressed);
Note:
See TracChangeset
for help on using the changeset viewer.