From 748d331f8584eca3a5e8df3d054fb1e64bef6af7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Laureano=20L=C3=B3pez?= Date: Thu, 12 Sep 2013 15:12:27 -0300 Subject: [PATCH] setBackground for (JFrame)frame frame.setBackground >> ((JFrame)frame).getContentPane().setBackground --- core/src/processing/core/PApplet.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/core/src/processing/core/PApplet.java b/core/src/processing/core/PApplet.java index 46838ec3c..dd06ff605 100755 --- a/core/src/processing/core/PApplet.java +++ b/core/src/processing/core/PApplet.java @@ -10445,7 +10445,7 @@ public class PApplet extends Applet Frame frame = new JFrame(displayDevice.getDefaultConfiguration()); // Default Processing gray, which will be replaced below if another // color is specified on the command line (i.e. in the prefs). - frame.setBackground(new Color(0xCC, 0xCC, 0xCC)); + ((JFrame)frame).getContentPane().setBackground(new Color(0xCC, 0xCC, 0xCC)); // Cannot call setResizable(false) until later due to OS X (issue #467) final PApplet applet; @@ -10557,7 +10557,7 @@ public class PApplet extends Applet //frame.setExtendedState(Frame.MAXIMIZED_BOTH); frame.setUndecorated(true); if (backgroundColor != null) { - frame.setBackground(backgroundColor); + ((JFrame)frame).getContentPane().setBackground(backgroundColor); } // if (exclusive) { // displayDevice.setFullScreenWindow(frame); @@ -10714,7 +10714,7 @@ public class PApplet extends Applet // // this means no bg color unless specified // backgroundColor = SystemColor.control; // } - frame.setBackground(backgroundColor); + ((JFrame)frame).getContentPane().setBackground(backgroundColor); } // int usableWindowH = windowH - insets.top - insets.bottom;