Changeset 32164 in osm for applications/editors/josm/plugins/cadastre-fr
- Timestamp:
- 2016-05-11T21:01:05+02:00 (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/cadastre-fr/src/cadastre_fr/CadastrePlugin.java
r32060 r32164 35 35 import org.openstreetmap.josm.gui.preferences.map.MapPreference; 36 36 import org.openstreetmap.josm.gui.preferences.projection.ProjectionPreference; 37 import org.openstreetmap.josm.gui.util.GuiHelper; 37 38 import org.openstreetmap.josm.plugins.Plugin; 38 39 import org.openstreetmap.josm.plugins.PluginInformation; … … 485 486 } 486 487 488 /** 489 * Ask to change projection if current one is not suitable for French cadastre. 490 */ 487 491 public static void askToChangeProjection() { 488 if (JOptionPane.showConfirmDialog(Main.parent, 489 tr("To enable the cadastre WMS plugin, change\n" 490 + "the current projection to one of the cadastre\n" 491 + "projections and retry"), 492 tr("Change the current projection"), JOptionPane.OK_CANCEL_OPTION) 493 == JOptionPane.OK_OPTION) { 494 PreferenceDialog p = new PreferenceDialog(Main.parent); 495 p.selectPreferencesTabByClass(MapPreference.class); 496 p.getTabbedPane().getSetting(ProjectionPreference.class).selectProjection(ProjectionPreference.lambert_cc9); 497 p.setVisible(true); 498 } 492 GuiHelper.runInEDTAndWait(new Runnable() { 493 @Override 494 public void run() { 495 if (JOptionPane.showConfirmDialog(Main.parent, 496 tr("To enable the cadastre WMS plugin, change\n" 497 + "the current projection to one of the cadastre\n" 498 + "projections and retry"), 499 tr("Change the current projection"), JOptionPane.OK_CANCEL_OPTION) 500 == JOptionPane.OK_OPTION) { 501 PreferenceDialog p = new PreferenceDialog(Main.parent); 502 p.selectPreferencesTabByClass(MapPreference.class); 503 p.getTabbedPane().getSetting(ProjectionPreference.class).selectProjection(ProjectionPreference.lambert_cc9); 504 p.setVisible(true); 505 } 506 } 507 }); 499 508 } 500 509 }
Note:
See TracChangeset
for help on using the changeset viewer.