mirror of
https://github.com/processing/processing4.git
synced 2026-06-16 04:26:26 +02:00
Allow JAVA2D to terminate when animation thread dies
When Java2D sketch crashes, closing the window does not stop Event Dispatch Thread. This fix makes PApplet.exit() do the right thing and not wait for surface to finish when the thread is already dead. Fixes #4831
This commit is contained in:
@@ -207,7 +207,7 @@ public class PSurfaceNone implements PSurface {
|
||||
|
||||
|
||||
public boolean isStopped() {
|
||||
return thread == null;
|
||||
return thread == null || !thread.isAlive();
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user