Changeset 14186 in josm for trunk/src/org/openstreetmap/josm/plugins/PluginHandler.java
- Timestamp:
- 2018-08-27T20:12:16+02:00 (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/plugins/PluginHandler.java
r14153 r14186 636 636 } 637 637 638 private static void logJavaUpdateRequired(String plugin, int requiredVersion) { 639 Logging.warn( 640 tr("Plugin {0} requires Java version {1}. The current Java version is {2}. " 641 +"You have to update Java in order to use this plugin.", 642 plugin, Integer.toString(requiredVersion), Utils.getJavaVersion() 643 )); 644 } 645 638 646 private static void alertJOSMUpdateRequired(Component parent, String plugin, int requiredVersion) { 639 647 HelpAwareOptionPane.showOptionDialog( … … 651 659 /** 652 660 * Checks whether all preconditions for loading the plugin <code>plugin</code> are met. The 653 * current J OSM versionmust be compatible with the plugin and no other plugins this plugin661 * current Java and JOSM versions must be compatible with the plugin and no other plugins this plugin 654 662 * depends on should be missing. 655 663 * … … 661 669 public static boolean checkLoadPreconditions(Component parent, Collection<PluginInformation> plugins, PluginInformation plugin) { 662 670 671 // make sure the plugin is compatible with the current Java version 672 if (plugin.localminjavaversion > Utils.getJavaVersion()) { 673 // Just log a warning until we switch to Java 11 so that openjfx plugin does not trigger a popup 674 logJavaUpdateRequired(plugin.name, plugin.localminjavaversion); 675 return false; 676 } 677 663 678 // make sure the plugin is compatible with the current JOSM version 664 //665 679 int josmVersion = Version.getInstance().getVersion(); 666 680 if (plugin.localmainversion > josmVersion && josmVersion != Version.JOSM_UNKNOWN_VERSION) {
Note:
See TracChangeset
for help on using the changeset viewer.