mirror of
https://github.com/processing/processing4.git
synced 2026-02-04 22:29:18 +01:00
changes for optionally building with rxtx instead of just javacomm
This commit is contained in:
@@ -27,6 +27,12 @@ import java.awt.*; // for window
|
||||
import java.awt.event.*; // also for window
|
||||
import java.io.*;
|
||||
|
||||
#ifndef RXTX
|
||||
import javax.comm.*;
|
||||
#else
|
||||
import gnu.io.*;
|
||||
#endif
|
||||
|
||||
|
||||
public class PdeRuntime implements PdeMessageConsumer {
|
||||
|
||||
@@ -83,7 +89,7 @@ public class PdeRuntime implements PdeMessageConsumer {
|
||||
applet.serialProperties(PdeBase.properties);
|
||||
applet.init();
|
||||
if (applet.exception != null) {
|
||||
if (applet.exception instanceof javax.comm.PortInUseException) {
|
||||
if (applet.exception instanceof PortInUseException) {
|
||||
throw new PdeException("Another program is already " +
|
||||
"using the serial port.");
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user