| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -29,6 +29,7 @@ | |||
| 29 | 29 | import java.io.UnsupportedEncodingException; | |
| 30 | 30 | ||
| 31 | 31 | import processing.app.Base; | |
| 32 | + import processing.app.Platform; | ||
| 32 | 33 | import processing.app.Preferences; | |
| 33 | 34 | import processing.app.RunnerListener; | |
| 34 | 35 | import processing.app.Sketch; | |
@@ -77,7 +78,7 @@ static public void main(String[] args) { | |||
| 77 | 78 | // Do this early so that error messages go to the console | |
| 78 | 79 | Base.setCommandLine(); | |
| 79 | 80 | // init the platform so that prefs and other native code is ready to go | |
| 80 | - Base.initPlatform(); | ||
| 81 | + Platform.init(); | ||
| 81 | 82 | // make sure a full JDK is installed | |
| 82 | 83 | //Base.initRequirements(); | |
| 83 | 84 | ||
@@ -145,7 +146,7 @@ public Commander(String[] args) { | |||
| 145 | 146 | } else if (arg.startsWith(platformArg)) { | |
| 146 | 147 | // complainAndQuit("The --platform option has been removed from Processing 2.1.", false); | |
| 147 | 148 | String platformStr = arg.substring(platformArg.length()); | |
| 148 | - platform = Base.getPlatformIndex(platformStr); | ||
| 149 | + platform = Platform.getIndex(platformStr); | ||
| 149 | 150 | if (platform == -1) { | |
| 150 | 151 | complainAndQuit(platformStr + " should instead be " + | |
| 151 | 152 | "'windows', 'macosx', or 'linux'.", true); | |
@@ -249,7 +250,7 @@ public Commander(String[] args) { | |||
| 249 | 250 | // JavaMode javaMode = | |
| 250 | 251 | // new JavaMode(null, Base.getContentFile("modes/java")); | |
| 251 | 252 | JavaMode javaMode = (JavaMode) | |
| 252 | - ModeContribution.load(null, Base.getContentFile("modes/java"), | ||
| 253 | + ModeContribution.load(null, Platform.getContentFile("modes/java"), | ||
| 253 | 254 | "processing.mode.java.JavaMode").getMode(); | |
| 254 | 255 | try { | |
| 255 | 256 | sketch = new Sketch(pdePath, javaMode); | |
@@ -280,8 +281,7 @@ public Commander(String[] args) { | |||
| 280 | 281 | JavaBuild build = new JavaBuild(sketch); | |
| 281 | 282 | build.build(true); | |
| 282 | 283 | if (build != null) { | |
| 283 | - | ||
| 284 | - String variant = Base.getVariant(); | ||
| 284 | + String variant = Platform.getVariant(); | ||
| 285 | 285 | success = build.exportApplication(outputFolder, platform, variant, embedJava); | |
| 286 | 286 | } | |
| 287 | 287 | } | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -786,7 +786,7 @@ protected boolean exportApplication() throws IOException, SketchException { | |||
| 786 | 786 | ||
| 787 | 787 | File folder = null; | |
| 788 | 788 | for (String platformName : PConstants.platformNames) { | |
| 789 | - int platform = Base.getPlatformIndex(platformName); | ||
| 789 | + int platform = Platform.getIndex(platformName); | ||
| 790 | 790 | ||
| 791 | 791 | // Can only embed Java on the native platform | |
| 792 | 792 | boolean embedJava = (platform == PApplet.platform) && | |
@@ -796,18 +796,18 @@ protected boolean exportApplication() throws IOException, SketchException { | |||
| 796 | 796 | if (Library.hasMultipleArch(platform, importedLibraries)) { | |
| 797 | 797 | // export the 32-bit version | |
| 798 | 798 | folder = new File(sketch.getFolder(), "application." + platformName + "32"); | |
| 799 | - if (!exportApplication(folder, platform, "32", embedJava && Base.getNativeBits() == 32 && "x86".equals(Base.getNativeArch()))) { | ||
| 799 | + if (!exportApplication(folder, platform, "32", embedJava && Platform.getNativeBits() == 32 && "x86".equals(Platform.getNativeArch()))) { | ||
| 800 | 800 | return false; | |
| 801 | 801 | } | |
| 802 | 802 | // export the 64-bit version | |
| 803 | 803 | folder = new File(sketch.getFolder(), "application." + platformName + "64"); | |
| 804 | - if (!exportApplication(folder, platform, "64", embedJava && Base.getNativeBits() == 64 && "x86".equals(Base.getNativeArch()))) { | ||
| 804 | + if (!exportApplication(folder, platform, "64", embedJava && Platform.getNativeBits() == 64 && "x86".equals(Platform.getNativeArch()))) { | ||
| 805 | 805 | return false; | |
| 806 | 806 | } | |
| 807 | 807 | if (platform == PConstants.LINUX) { | |
| 808 | 808 | // export the armv6hf version as well | |
| 809 | 809 | folder = new File(sketch.getFolder(), "application.linux-armv6hf"); | |
| 810 | - if (!exportApplication(folder, platform, "armv6hf", embedJava && Base.getNativeBits() == 32 && "arm".equals(Base.getNativeArch()))) { | ||
| 810 | + if (!exportApplication(folder, platform, "armv6hf", embedJava && Platform.getNativeBits() == 32 && "arm".equals(Platform.getNativeArch()))) { | ||
| 811 | 811 | return false; | |
| 812 | 812 | } | |
| 813 | 813 | } | |
@@ -891,10 +891,10 @@ protected boolean exportApplication(File destFolder, | |||
| 891 | 891 | if (exportPlatform == PConstants.MACOSX) { | |
| 892 | 892 | dotAppFolder = new File(destFolder, sketch.getName() + ".app"); | |
| 893 | 893 | ||
| 894 | - File contentsOrig = new File(Base.getJavaHome(), "../../../../.."); | ||
| 894 | + File contentsOrig = new File(Platform.getJavaHome(), "../../../../.."); | ||
| 895 | 895 | ||
| 896 | 896 | if (embedJava) { | |
| 897 | - File jdkFolder = new File(Base.getJavaHome(), "../../.."); | ||
| 897 | + File jdkFolder = new File(Platform.getJavaHome(), "../../.."); | ||
| 898 | 898 | String jdkFolderName = jdkFolder.getCanonicalFile().getName(); | |
| 899 | 899 | jvmRuntime = "<key>JVMRuntime</key>\n <string>" + jdkFolderName + "</string>"; | |
| 900 | 900 | jdkPath = new File(dotAppFolder, "Contents/PlugIns/" + jdkFolderName).getAbsolutePath(); | |
@@ -958,12 +958,12 @@ protected boolean exportApplication(File destFolder, | |||
| 958 | 958 | */ | |
| 959 | 959 | } else if (exportPlatform == PConstants.LINUX) { | |
| 960 | 960 | if (embedJava) { | |
| 961 | - Util.copyDirNative(Base.getJavaHome(), new File(destFolder, "java")); | ||
| 961 | + Util.copyDirNative(Platform.getJavaHome(), new File(destFolder, "java")); | ||
| 962 | 962 | } | |
| 963 | 963 | ||
| 964 | 964 | } else if (exportPlatform == PConstants.WINDOWS) { | |
| 965 | 965 | if (embedJava) { | |
| 966 | - Util.copyDir(Base.getJavaHome(), new File(destFolder, "java")); | ||
| 966 | + Util.copyDir(Platform.getJavaHome(), new File(destFolder, "java")); | ||
| 967 | 967 | } | |
| 968 | 968 | } | |
| 969 | 969 | ||
@@ -1183,7 +1183,7 @@ protected boolean exportApplication(File destFolder, | |||
| 1183 | 1183 | pw.close(); | |
| 1184 | 1184 | ||
| 1185 | 1185 | // attempt to code sign if the Xcode tools appear to be installed | |
| 1186 | - if (Base.isMacOS() && new File("/usr/bin/codesign_allocate").exists()) { | ||
| 1186 | + if (Platform.isMacOS() && new File("/usr/bin/codesign_allocate").exists()) { | ||
| 1187 | 1187 | if (embedJava) { | |
| 1188 | 1188 | ProcessHelper.ffs("codesign", "--force", "--sign", "-", jdkPath); | |
| 1189 | 1189 | } | |
@@ -1297,7 +1297,7 @@ protected boolean exportApplication(File destFolder, | |||
| 1297 | 1297 | ||
| 1298 | 1298 | String shellPath = shellScript.getAbsolutePath(); | |
| 1299 | 1299 | // will work on osx or *nix, but just dies on windows, oh well.. | |
| 1300 | - if (!Base.isWindows()) { | ||
| 1300 | + if (!Platform.isWindows()) { | ||
| 1301 | 1301 | Runtime.getRuntime().exec(new String[] { "chmod", "+x", shellPath }); | |
| 1302 | 1302 | } | |
| 1303 | 1303 | } | |
@@ -1439,7 +1439,7 @@ protected void addDataFolder(ZipOutputStream zos) throws IOException { | |||
| 1439 | 1439 | String[] dataFiles = Util.listFiles(sketch.getDataFolder(), false); | |
| 1440 | 1440 | int offset = sketch.getFolder().getAbsolutePath().length() + 1; | |
| 1441 | 1441 | for (String path : dataFiles) { | |
| 1442 | - if (Base.isWindows()) { | ||
| 1442 | + if (Platform.isWindows()) { | ||
| 1443 | 1443 | path = path.replace('\\', '/'); | |
| 1444 | 1444 | } | |
| 1445 | 1445 | //File dataFile = new File(dataFiles[i]); | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -344,7 +344,7 @@ public JMenu buildHelpMenu() { | |||
| 344 | 344 | JMenuItem item; | |
| 345 | 345 | ||
| 346 | 346 | // macosx already has its own about menu | |
| 347 | - if (!Base.isMacOS()) { | ||
| 347 | + if (!Platform.isMacOS()) { | ||
| 348 | 348 | item = new JMenuItem(Language.text("menu.help.about")); | |
| 349 | 349 | item.addActionListener(new ActionListener() { | |
| 350 | 350 | public void actionPerformed(ActionEvent e) { | |
@@ -497,39 +497,39 @@ public void menuCanceled(MenuEvent e) { | |||
| 497 | 497 | item = new JMenuItem(Language.text("menu.help.getting_started")); | |
| 498 | 498 | item.addActionListener(new ActionListener() { | |
| 499 | 499 | public void actionPerformed(ActionEvent e) { | |
| 500 | - Base.openURL(Language.text("menu.help.getting_started.url")); | ||
| 500 | + Platform.openURL(Language.text("menu.help.getting_started.url")); | ||
| 501 | 501 | } | |
| 502 | 502 | }); | |
| 503 | 503 | menu.add(item); | |
| 504 | 504 | ||
| 505 | 505 | item = new JMenuItem(Language.text("menu.help.troubleshooting")); | |
| 506 | 506 | item.addActionListener(new ActionListener() { | |
| 507 | 507 | public void actionPerformed(ActionEvent e) { | |
| 508 | - Base.openURL(Language.text("menu.help.troubleshooting.url")); | ||
| 508 | + Platform.openURL(Language.text("menu.help.troubleshooting.url")); | ||
| 509 | 509 | } | |
| 510 | 510 | }); | |
| 511 | 511 | menu.add(item); | |
| 512 | 512 | ||
| 513 | 513 | item = new JMenuItem(Language.text("menu.help.faq")); | |
| 514 | 514 | item.addActionListener(new ActionListener() { | |
| 515 | 515 | public void actionPerformed(ActionEvent e) { | |
| 516 | - Base.openURL(Language.text("menu.help.faq.url")); | ||
| 516 | + Platform.openURL(Language.text("menu.help.faq.url")); | ||
| 517 | 517 | } | |
| 518 | 518 | }); | |
| 519 | 519 | menu.add(item); | |
| 520 | 520 | ||
| 521 | 521 | item = new JMenuItem(Language.text("menu.help.foundation")); | |
| 522 | 522 | item.addActionListener(new ActionListener() { | |
| 523 | 523 | public void actionPerformed(ActionEvent e) { | |
| 524 | - Base.openURL(Language.text("menu.help.foundation.url")); | ||
| 524 | + Platform.openURL(Language.text("menu.help.foundation.url")); | ||
| 525 | 525 | } | |
| 526 | 526 | }); | |
| 527 | 527 | menu.add(item); | |
| 528 | 528 | ||
| 529 | 529 | item = new JMenuItem(Language.text("menu.help.visit")); | |
| 530 | 530 | item.addActionListener(new ActionListener() { | |
| 531 | 531 | public void actionPerformed(ActionEvent e) { | |
| 532 | - Base.openURL(Language.text("menu.help.visit.url")); | ||
| 532 | + Platform.openURL(Language.text("menu.help.visit.url")); | ||
| 533 | 533 | } | |
| 534 | 534 | }); | |
| 535 | 535 | menu.add(item); | |
@@ -664,7 +664,7 @@ public void handleExportApplication() { | |||
| 664 | 664 | statusNotice(Language.text("export.notice.exporting")); | |
| 665 | 665 | try { | |
| 666 | 666 | if (exportApplicationPrompt()) { | |
| 667 | - Base.openFolder(sketch.getFolder()); | ||
| 667 | + Platform.openFolder(sketch.getFolder()); | ||
| 668 | 668 | statusNotice(Language.text("export.notice.exporting.done")); | |
| 669 | 669 | } else { | |
| 670 | 670 | // error message will already be visible | |
@@ -738,7 +738,7 @@ public void itemStateChanged(ItemEvent e) { | |||
| 738 | 738 | }); | |
| 739 | 739 | ||
| 740 | 740 | // Only possible to export OS X applications on OS X | |
| 741 | - if (!Base.isMacOS()) { | ||
| 741 | + if (!Platform.isMacOS()) { | ||
| 742 | 742 | // Make sure they don't have a previous 'true' setting for this | |
| 743 | 743 | Preferences.setBoolean(EXPORT_MACOSX, false); | |
| 744 | 744 | } | |
@@ -749,7 +749,7 @@ public void itemStateChanged(ItemEvent e) { | |||
| 749 | 749 | updateExportButton(); | |
| 750 | 750 | } | |
| 751 | 751 | }); | |
| 752 | - if (!Base.isMacOS()) { | ||
| 752 | + if (!Platform.isMacOS()) { | ||
| 753 | 753 | macosxButton.setEnabled(false); | |
| 754 | 754 | macosxButton.setToolTipText(Language.text("export.tooltip.macosx")); | |
| 755 | 755 | } | |
@@ -866,12 +866,12 @@ public void paintComponent(Graphics g) { | |||
| 866 | 866 | embedPanel.setLayout(new BoxLayout(embedPanel, BoxLayout.Y_AXIS)); | |
| 867 | 867 | ||
| 868 | 868 | String platformName = null; | |
| 869 | - if (Base.isMacOS()) { | ||
| 869 | + if (Platform.isMacOS()) { | ||
| 870 | 870 | platformName = "Mac OS X"; | |
| 871 | - } else if (Base.isWindows()) { | ||
| 872 | - platformName = "Windows (" + Base.getNativeBits() + "-bit)"; | ||
| 873 | - } else if (Base.isLinux()) { | ||
| 874 | - platformName = "Linux (" + Base.getNativeBits() + "-bit)"; | ||
| 871 | + } else if (Platform.isWindows()) { | ||
| 872 | + platformName = "Windows (" + Platform.getNativeBits() + "-bit)"; | ||
| 873 | + } else if (Platform.isLinux()) { | ||
| 874 | + platformName = "Linux (" + Platform.getNativeBits() + "-bit)"; | ||
| 875 | 875 | } | |
| 876 | 876 | ||
| 877 | 877 | boolean embed = Preferences.getBoolean("export.application.embed_java"); | |
@@ -893,7 +893,7 @@ public void paintComponent(Graphics g) { | |||
| 893 | 893 | final JLabel warningLabel = new JLabel(embed ? embedWarning : nopeWarning); | |
| 894 | 894 | warningLabel.addMouseListener(new MouseAdapter() { | |
| 895 | 895 | public void mousePressed(MouseEvent event) { | |
| 896 | - Base.openURL("http://java.com/download"); | ||
| 896 | + Platform.openURL("http://java.com/download"); | ||
| 897 | 897 | } | |
| 898 | 898 | }); | |
| 899 | 899 | warningLabel.setBorder(new EmptyBorder(3, 13 + indent, 3, 13)); | |
@@ -921,7 +921,7 @@ public void itemStateChanged(ItemEvent e) { | |||
| 921 | 921 | ||
| 922 | 922 | // | |
| 923 | 923 | ||
| 924 | - if (Base.isMacOS()) { | ||
| 924 | + if (Platform.isMacOS()) { | ||
| 925 | 925 | JPanel signPanel = new JPanel(); | |
| 926 | 926 | signPanel.setLayout(new BoxLayout(signPanel, BoxLayout.Y_AXIS)); | |
| 927 | 927 | signPanel.setBorder(new TitledBorder(Language.text("export.code_signing"))); | |
@@ -972,7 +972,7 @@ public void itemStateChanged(ItemEvent e) { | |||
| 972 | 972 | ||
| 973 | 973 | area.addMouseListener(new MouseAdapter() { | |
| 974 | 974 | public void mousePressed(MouseEvent event) { | |
| 975 | - Base.openURL("https://developer.apple.com/developer-id/"); | ||
| 975 | + Platform.openURL("https://developer.apple.com/developer-id/"); | ||
| 976 | 976 | } | |
| 977 | 977 | }); | |
| 978 | 978 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -107,7 +107,7 @@ public String[] getIgnorable() { | |||
| 107 | 107 | ||
| 108 | 108 | public Library getCoreLibrary() { | |
| 109 | 109 | if (coreLibrary == null) { | |
| 110 | - File coreFolder = Base.getContentFile("core"); | ||
| 110 | + File coreFolder = Platform.getContentFile("core"); | ||
| 111 | 111 | coreLibrary = new Library(coreFolder); | |
| 112 | 112 | // try { | |
| 113 | 113 | // coreLibrary = getLibrary("processing.core"); | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -108,6 +108,7 @@ | |||
| 108 | 108 | ||
| 109 | 109 | import processing.app.Base; | |
| 110 | 110 | import processing.app.Library; | |
| 111 | + import processing.app.Platform; | ||
| 111 | 112 | import processing.app.SketchCode; | |
| 112 | 113 | import processing.app.Util; | |
| 113 | 114 | import processing.app.syntax.JEditTextArea; | |
@@ -326,7 +327,7 @@ protected void loadJars() { | |||
| 326 | 327 | classPath = factory.createFromPath(tehPath.toString()); | |
| 327 | 328 | log("Classpath created " + (classPath != null)); | |
| 328 | 329 | log("Sketch classpath jars loaded."); | |
| 329 | - if (Base.isMacOS()) { | ||
| 330 | + if (Platform.isMacOS()) { | ||
| 330 | 331 | File f = new File(System.getProperty("java.home") + File.separator + "bundle" | |
| 331 | 332 | + File.separator + "Classes" + File.separator + "classes.jar"); | |
| 332 | 333 | log(f.getAbsolutePath() + " | classes.jar found?" | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -37,6 +37,7 @@ | |||
| 37 | 37 | ||
| 38 | 38 | import processing.app.Base; | |
| 39 | 39 | import processing.app.Mode; | |
| 40 | + import processing.app.Platform; | ||
| 40 | 41 | import processing.app.syntax.JEditTextArea; | |
| 41 | 42 | import processing.app.syntax.PdeTextAreaDefaults; | |
| 42 | 43 | import processing.app.syntax.TextAreaDefaults; | |
@@ -234,7 +235,7 @@ public void processKeyEvent(KeyEvent evt) { | |||
| 234 | 235 | if (evt.getID() == KeyEvent.KEY_TYPED) { | |
| 235 | 236 | processCompletionKeys(evt); | |
| 236 | 237 | ||
| 237 | - } else if (Base.isMacOS() && evt.getID() == KeyEvent.KEY_RELEASED) { | ||
| 238 | + } else if (Platform.isMacOS() && evt.getID() == KeyEvent.KEY_RELEASED) { | ||
| 238 | 239 | processControlSpace(evt); | |
| 239 | 240 | } | |
| 240 | 241 | } | |
@@ -279,7 +280,7 @@ private void processCompletionKeys(final KeyEvent event) { | |||
| 279 | 280 | Base.log("Typing: " + fetchPhrase(event)); | |
| 280 | 281 | } | |
| 281 | 282 | } else if (keyChar == ' ') { // Trigger on Ctrl-Space | |
| 282 | - if (!Base.isMacOS() && JavaMode.codeCompletionsEnabled && | ||
| 283 | + if (!Platform.isMacOS() && JavaMode.codeCompletionsEnabled && | ||
| 283 | 284 | (event.isControlDown() || event.isMetaDown())) { | |
| 284 | 285 | SwingWorker<Object, Object> worker = new SwingWorker<Object, Object>() { | |
| 285 | 286 | protected Object doInBackground() throws Exception { | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -48,6 +48,7 @@ | |||
| 48 | 48 | import javax.swing.text.Utilities; | |
| 49 | 49 | ||
| 50 | 50 | import processing.app.Base; | |
| 51 | + import processing.app.Platform; | ||
| 51 | 52 | import processing.app.SketchCode; | |
| 52 | 53 | import processing.app.syntax.SyntaxDocument; | |
| 53 | 54 | import processing.app.syntax.TextAreaDefaults; | |
@@ -102,7 +103,7 @@ public JavaTextAreaPainter(JavaTextArea textArea, TextAreaDefaults defaults) { | |||
| 102 | 103 | public void mouseClicked(MouseEvent evt) { | |
| 103 | 104 | if (!getEditor().hasJavaTabs()) { // Ctrl + Click disabled for java tabs | |
| 104 | 105 | if (evt.getButton() == MouseEvent.BUTTON1) { | |
| 105 | - if ((evt.isControlDown() && !Base.isMacOS()) || evt.isMetaDown()) { | ||
| 106 | + if ((evt.isControlDown() && !Platform.isMacOS()) || evt.isMetaDown()) { | ||
| 106 | 107 | handleCtrlClick(evt); | |
| 107 | 108 | } | |
| 108 | 109 | } | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -89,14 +89,14 @@ public Runner(JavaBuild build, RunnerListener listener) throws SketchException { | |||
| 89 | 89 | } | |
| 90 | 90 | ||
| 91 | 91 | // Make sure all the imported libraries will actually run with this setup. | |
| 92 | - int bits = Base.getNativeBits(); | ||
| 93 | - String variant = Base.getVariant(); | ||
| 92 | + int bits = Platform.getNativeBits(); | ||
| 93 | + String variant = Platform.getVariant(); | ||
| 94 | 94 | ||
| 95 | 95 | for (Library library : build.getImportedLibraries()) { | |
| 96 | 96 | if (!library.supportsArch(PApplet.platform, variant)) { | |
| 97 | 97 | sketchErr.println(library.getName() + " does not run on this architecture: " + variant); | |
| 98 | 98 | int opposite = (bits == 32) ? 64 : 32; | |
| 99 | - if (Base.isMacOS()) { | ||
| 99 | + if (Platform.isMacOS()) { | ||
| 100 | 100 | //if (library.supportsArch(PConstants.MACOSX, opposite)) { // should always be true | |
| 101 | 101 | throw new SketchException("To use " + library.getName() + ", " + | |
| 102 | 102 | "switch to " + opposite + "-bit mode in Preferences."); | |
@@ -167,7 +167,7 @@ public boolean launchVirtualMachine(boolean presenting) { | |||
| 167 | 167 | String jdwpArg = "-agentlib:jdwp=transport=dt_socket,address=" + portStr + ",server=y,suspend=y"; | |
| 168 | 168 | ||
| 169 | 169 | // Everyone works the same under Java 7 (also on OS X) | |
| 170 | - String[] commandArgs = new String[] { Base.getJavaPath(), jdwpArg }; | ||
| 170 | + String[] commandArgs = new String[] { Platform.getJavaPath(), jdwpArg }; | ||
| 171 | 171 | ||
| 172 | 172 | commandArgs = PApplet.concat(commandArgs, vmParams); | |
| 173 | 173 | commandArgs = PApplet.concat(commandArgs, sketchParams); | |
@@ -256,7 +256,7 @@ protected String[] getMachineParams() { | |||
| 256 | 256 | params.add("-Xmx" + Preferences.get("run.options.memory.maximum") + "m"); | |
| 257 | 257 | } | |
| 258 | 258 | ||
| 259 | - if (Base.isMacOS()) { | ||
| 259 | + if (Platform.isMacOS()) { | ||
| 260 | 260 | params.add("-Xdock:name=" + build.getSketchClassName()); | |
| 261 | 261 | // params.add("-Dcom.apple.mrj.application.apple.menu.about.name=" + | |
| 262 | 262 | // sketch.getMainClassName()); | |
@@ -670,7 +670,7 @@ public static boolean handleCommonErrors(final String exceptionClass, | |||
| 670 | 670 | listener.statusError("A library used by this sketch is not installed properly."); | |
| 671 | 671 | err.println("A library relies on native code that's not available."); | |
| 672 | 672 | err.println("Or only works properly when the sketch is run as a " + | |
| 673 | - ((Base.getNativeBits() == 32) ? "64-bit" : "32-bit") + " application."); | ||
| 673 | + ((Platform.getNativeBits() == 32) ? "64-bit" : "32-bit") + " application."); | ||
| 674 | 674 | ||
| 675 | 675 | } else if (exceptionClass.equals("java.lang.StackOverflowError")) { | |
| 676 | 676 | listener.statusError("StackOverflowError: This sketch is attempting too much recursion."); | |
| Back | FazBrowse Home | New Git URL |
0 commit comments