mirror of
https://github.com/processing/processing4.git
synced 2026-02-15 11:25:38 +01:00
additional workaround for Canvas-only code
This commit is contained in:
@@ -831,9 +831,13 @@ public class PSurfaceAWT implements PSurface {
|
||||
|
||||
// canvas.setSize(wide, high);
|
||||
// frame.setSize(wide, high);
|
||||
setFrameSize(); //wide, high);
|
||||
if (frame != null) { // canvas only
|
||||
setFrameSize(); //wide, high);
|
||||
}
|
||||
setCanvasSize();
|
||||
frame.setLocationRelativeTo(null);
|
||||
if (frame != null) {
|
||||
frame.setLocationRelativeTo(null);
|
||||
}
|
||||
|
||||
GraphicsConfiguration gc = canvas.getGraphicsConfiguration();
|
||||
// If not realized (off-screen, i.e the Color Selector Tool), gc will be null.
|
||||
|
||||
Reference in New Issue
Block a user