Changeset 14149 in josm for trunk/scripts


Ignore:
Timestamp:
2018-08-12T17:24:32+02:00 (12 months ago)
Author:
Don-vip
Message:

see #15229 - deprecate Main.pref

Location:
trunk/scripts
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/scripts/SyncEditorLayerIndex.groovy

    r14020 r14149  
    2525import javax.json.JsonValue
    2626
    27 import org.openstreetmap.josm.Main
    2827import org.openstreetmap.josm.data.Preferences
    2928import org.openstreetmap.josm.data.imagery.ImageryInfo
     
    6160        Locale.setDefault(Locale.ROOT)
    6261        parse_command_line_arguments(args)
    63         Main.determinePlatformHook()
    6462        def pref = new Preferences(JosmBaseDirectories.getInstance())
    6563        Config.setPreferencesInstance(pref)
  • trunk/scripts/TagInfoExtract.groovy

    r14120 r14149  
    2121import javax.json.stream.JsonGenerator
    2222
    23 import org.openstreetmap.josm.Main
    2423import org.openstreetmap.josm.actions.DeleteAction
    2524import org.openstreetmap.josm.command.DeleteCommand
     25import org.openstreetmap.josm.data.Preferences
    2626import org.openstreetmap.josm.data.Version
    2727import org.openstreetmap.josm.data.coor.LatLon
     
    413413     */
    414414    def init() {
    415         Main.determinePlatformHook()
    416415        Logging.setLogLevel(Logging.LEVEL_INFO)
    417         Main.pref.enableSaveOnPut(false)
    418         Config.setPreferencesInstance(Main.pref)
     416        Preferences.main().enableSaveOnPut(false)
     417        Config.setPreferencesInstance(Preferences.main())
    419418        Config.setBaseDirectoriesProvider(JosmBaseDirectories.getInstance())
    420419        Config.setUrlsProvider(JosmUrls.getInstance())
Note: See TracChangeset for help on using the changeset viewer.