Ignore:
Timestamp:
2018-08-12T02:21:19+02:00 (6 years ago)
Author:
Don-vip
Message:

see #15229 - deprecate Main.platform and related methods - new class PlatformManager

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/io/CachedFile.java

    r14119 r14138  
    3434import org.openstreetmap.josm.tools.Logging;
    3535import org.openstreetmap.josm.tools.Pair;
     36import org.openstreetmap.josm.tools.PlatformManager;
    3637import org.openstreetmap.josm.tools.Utils;
    3738
     
    521522            activeConnection = null;
    522523            localFile = new File(destDir, localPath);
    523             if (Main.platform.rename(destDirFile, localFile)) {
     524            if (PlatformManager.getPlatform().rename(destDirFile, localFile)) {
    524525                Config.getPref().putList(prefKey,
    525526                        Arrays.asList(Long.toString(System.currentTimeMillis()), localFile.toString()));
     
    549550            // Windows doesn't support paths longer than 260, leave 5 chars as safe buffer, 4 will be used by ".tmp"
    550551            // TODO: what about filename size on other systems? 255?
    551             if (directory.length() > 191 && Main.isPlatformWindows()) {
     552            if (directory.length() > 191 && PlatformManager.isPlatformWindows()) {
    552553                // digest length + name prefix == 64
    553554                // 255 - 64 = 191
Note: See TracChangeset for help on using the changeset viewer.