File tree Expand file tree Collapse file tree 1 file changed +2
-13
lines changed Expand file tree Collapse file tree 1 file changed +2
-13
lines changed Original file line number Diff line number Diff line change @@ -338,8 +338,6 @@ public class PApplet extends Object implements ActivityAPI, PConstants {
338
338
// https://github.com/processing/processing/issues/2297
339
339
int windowColor = 0xffDDDDDD ;
340
340
341
- PStyle savedStyle ;
342
-
343
341
///////////////////////////////////////////////////////////////
344
342
// Error messages
345
343
@@ -535,12 +533,8 @@ public void onResume() {
535
533
setFullScreenVisibility ();
536
534
}
537
535
538
- // TODO need to bring back app state here!
539
- // At least we restore the current style.
540
- if (savedStyle != null && g != null ) {
536
+ if (g != null ) {
541
537
g .restoreState ();
542
- g .style (savedStyle );
543
- savedStyle = null ;
544
538
}
545
539
546
540
handleMethods ("resume" );
@@ -566,12 +560,7 @@ public void onPause() {
566
560
// Make sure that the keyboard is not left open after leaving the app
567
561
closeKeyboard ();
568
562
569
- // TODO need to save all application state here!
570
- // At least we save the current style (once we had at least drawn one
571
- // frame, otherwise we might be saving a "null" style with all zeroes).
572
- if (g != null && 0 < frameCount ) {
573
- savedStyle = new PStyle ();
574
- g .getStyle (savedStyle );
563
+ if (g != null ) {
575
564
g .saveState ();
576
565
}
577
566
You can’t perform that action at this time.
0 commit comments