source: josm/trunk/src/org/openstreetmap/josm/actions/SaveAsAction.java@ 729

Last change on this file since 729 was 693, checked in by stoecker, 16 years ago

Save dialog now distinguish between OSM and GPX. Saving OSM layer as GPX is still possible. Closes #836

  • Property svn:eol-style set to native
File size: 774 bytes
Line 
1// License: GPL. Copyright 2007 by Immanuel Scholz and others
2package org.openstreetmap.josm.actions;
3
4import static org.openstreetmap.josm.tools.I18n.tr;
5
6import java.awt.event.InputEvent;
7import java.awt.event.KeyEvent;
8import java.io.File;
9
10import org.openstreetmap.josm.gui.layer.Layer;
11
12/**
13 * Export the data.
14 *
15 * @author imi
16 */
17public class SaveAsAction extends SaveActionBase {
18
19 /**
20 * Construct the action with "Save" as label.
21 * @param layer Save this layer.
22 */
23 public SaveAsAction(Layer layer) {
24 super(tr("Save as ..."), "save_as", tr("Save the current data to a new file."), KeyEvent.VK_S, InputEvent.CTRL_DOWN_MASK | InputEvent.SHIFT_DOWN_MASK, layer);
25 }
26
27 @Override protected File getFile(Layer layer) {
28 return openFileDialog(layer);
29 }
30}
Note: See TracBrowser for help on using the repository browser.