- Timestamp:
- 2013-12-11T00:51:08+01:00 (10 years ago)
- Location:
- trunk/src/org/openstreetmap/josm
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/Main.java
r6453 r6471 18 18 import java.net.URI; 19 19 import java.net.URISyntaxException; 20 import java.net.URL; 20 21 import java.text.MessageFormat; 21 22 import java.util.ArrayList; … … 54 55 import org.openstreetmap.josm.data.Bounds; 55 56 import org.openstreetmap.josm.data.Preferences; 57 import org.openstreetmap.josm.data.ServerSidePreferences; 56 58 import org.openstreetmap.josm.data.UndoRedoHandler; 57 59 import org.openstreetmap.josm.data.coor.CoordinateFormat; … … 335 337 336 338 /** 339 * Initializes {@code Main.pref} in applet context. 340 * @param serverURL The server URL hosting the user preferences. 341 * @since 6471 342 */ 343 public static void initAppletPreferences(URL serverURL) { 344 Main.pref = new ServerSidePreferences(serverURL); 345 } 346 347 /** 348 * Initializes {@code Main.pref} in normal application context. 349 * @since 6471 350 */ 351 public static void initApplicationPreferences() { 352 Main.pref = new Preferences(); 353 } 354 355 /** 337 356 * Set or clear (if passed <code>null</code>) the map. 338 357 * @param map The map to set {@link Main#map} to. Can be null. -
trunk/src/org/openstreetmap/josm/gui/MainApplet.java
r6380 r6471 101 101 Main.platform.preStartupHook(); 102 102 103 Main. pref = new ServerSidePreferences(getCodeBase());103 Main.initAppletPreferences(getCodeBase()); 104 104 105 105 String lang = getParameter("language"); … … 166 166 Main.applet = true; 167 167 MainApplet applet = new MainApplet(); 168 Main. pref = new ServerSidePreferences(applet.getCodeBase());168 Main.initAppletPreferences(applet.getCodeBase()); 169 169 applet.setStub(new AppletStub() { 170 170 @Override -
trunk/src/org/openstreetmap/josm/gui/MainApplication.java
r6453 r6471 273 273 } 274 274 275 Main.pref = newPreferences();275 initApplicationPreferences(); 276 276 277 277 Policy.setPolicy(new Policy() {
Note:
See TracChangeset
for help on using the changeset viewer.