Revision 10937 branches/v10/extensions/extCAD/src/com/iver/cit/gvsig/gui/cad/MyFinishAction.java
MyFinishAction.java | ||
---|---|---|
72 | 72 |
if (actionComand.equals("SHP")) |
73 | 73 |
{ |
74 | 74 |
FileBasedPanel shpPanel = (FileBasedPanel) myWizardComponents.getWizardPanel(2); |
75 |
File newFile = new File(shpPanel.getPath()); |
|
75 |
String path=shpPanel.getPath(); |
|
76 |
if (!path.toLowerCase().endsWith(".shp")){ |
|
77 |
path+=".shp"; |
|
78 |
} |
|
79 |
File newFile = new File(path); |
|
76 | 80 |
if( newFile.exists()){ |
77 | 81 |
int resp = JOptionPane.showConfirmDialog( |
78 | 82 |
(Component) PluginServices.getMainFrame(),PluginServices.getText(this,"fichero_ya_existe_seguro_desea_guardarlo"), |
... | ... | |
113 | 117 |
else if (actionComand.equals("DXF")) |
114 | 118 |
{ |
115 | 119 |
FileBasedPanel dxfPanel = (FileBasedPanel) myWizardComponents.getWizardPanel(0); |
116 |
File newFile = new File(dxfPanel.getPath()); |
|
120 |
String path=dxfPanel.getPath(); |
|
121 |
if (!path.toLowerCase().endsWith(".dxf")){ |
|
122 |
path+=".dxf"; |
|
123 |
} |
|
124 |
File newFile = new File(path); |
|
117 | 125 |
if( newFile.exists()){ |
118 | 126 |
int resp = JOptionPane.showConfirmDialog( |
119 | 127 |
(Component) PluginServices.getMainFrame(),PluginServices.getText(this,"fichero_ya_existe_seguro_desea_guardarlo"), |
Also available in: Unified diff