better fix for 2208

This commit is contained in:
Ben Fry
2014-07-30 22:07:44 -04:00
parent 828cef7fd1
commit aec46f25cf
@@ -1302,9 +1302,10 @@ public class PGraphicsJava2D extends PGraphics {
if (who.modified) {
if (who.pixels == null) {
// This might be a PGraphics that hasn't been drawn to yet, bail out.
// This might be a PGraphics that hasn't been drawn to yet.
// Can't just bail because the cache has been created above.
// https://github.com/processing/processing/issues/2208
return;
who.pixels = new int[who.width * who.height];
}
cash.update(who, tint, tintColor);
who.modified = false;