Changeset 17488 in josm for trunk


Ignore:
Timestamp:
2021-02-08T21:57:55+01:00 (4 years ago)
Author:
GerdP
Message:

see #20257:macOS build process fixes and improvements

  • ​fix checkstyle issues
Location:
trunk/src/org/openstreetmap/josm
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/MainApplication.java

    r17487 r17488  
    10431043                Logging.log(Logging.LEVEL_ERROR, null, e);
    10441044            }
    1045         }
    1046         // Workaround for JDK-8251377: JTabPanel active tab is unreadable in Big Sur, see #20075
    1047         // os.version will return 10.16, or 11.0 depending on environment variable
    1048         // https://twitter.com/BriceDutheil/status/1330926649269956612
    1049         else {
     1045        } else {
     1046            // Workaround for JDK-8251377: JTabPanel active tab is unreadable in Big Sur, see #20075
     1047            // os.version will return 10.16, or 11.0 depending on environment variable
     1048            // https://twitter.com/BriceDutheil/status/1330926649269956612
    10501049            final String laf = UIManager.getLookAndFeel().getID();
    10511050            final String macOSVersion = getSystemProperty("os.version");
    1052             if(PlatformManager.isPlatformOsx() && (laf.contains("Mac") || laf.contains("Aqua")) && (macOSVersion.startsWith("10.16") || macOSVersion.startsWith("11"))){
     1051            if (PlatformManager.isPlatformOsx() && (laf.contains("Mac") || laf.contains("Aqua"))
     1052                    && (macOSVersion.startsWith("10.16") || macOSVersion.startsWith("11"))) {
    10531053                UIManager.put("TabbedPane.foreground", Color.BLACK);
    10541054            }
  • trunk/src/org/openstreetmap/josm/tools/PlatformHookOsx.java

    r17487 r17488  
    3434import org.openstreetmap.josm.spi.preferences.Config;
    3535
    36 
    3736/**
    3837 * {@code PlatformHook} implementation for Apple macOS (formerly Mac OS X) systems.
     
    8483            }
    8584            // setup the dock icon. It is automatically set with application bundle and Web start but we need
    86             // to do it manually if run with `java -jar``. 
     85            // to do it manually if run with `java -jar``.
    8786            eawtApplication.getDeclaredMethod("setDockIconImage", Image.class).invoke(
    88                 appli, 
     87                appli,
    8988                Optional.ofNullable(
    90                     new ImageProvider(Config.getUrls().getJOSMWebsite()+"/logo-macos.png").setOptional(true).get()
    91                 ).orElse( // Fall back to default icon
     89                    new ImageProvider(Config.getUrls().getJOSMWebsite()+"/logo-macos.png").setOptional(true).get())
     90                .orElse(// Fall back to default icon
    9291                    ImageProvider.get("logo")).getImage()
    9392            );
    94        
     93
    9594            // enable full screen
    9695            enableOSXFullscreen(MainApplication.getMainFrame());
Note: See TracChangeset for help on using the changeset viewer.