File tree 1 file changed +8
-5
lines changed
1 file changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -574,16 +574,19 @@ protected void storeSketches() {
574
574
if (path .startsWith (untitledPath ) && !sketch .isModified ()) {
575
575
continue ;
576
576
}
577
- PreferencesData .set ("last.sketch" + index + ".path" , path );
578
-
579
- int [] placement = editor .getPlacement ();
580
- String location = PApplet .join (PApplet .str (placement ), "," );
581
- PreferencesData .set ("last.sketch" + index + ".location" , location );
577
+ storeSketchLocation (editor , "" + index );
582
578
index ++;
583
579
}
584
580
PreferencesData .setInteger ("last.sketch.count" , index );
585
581
}
586
582
583
+ private void storeSketchLocation (Editor editor , String index ) {
584
+ String path = editor .getSketch ().getMainFilePath ();
585
+ String loc = StringUtils .join (editor .getPlacement (), ',' );
586
+ PreferencesData .set ("last.sketch" + index + ".path" , path );
587
+ PreferencesData .set ("last.sketch" + index + ".location" , loc );
588
+ }
589
+
587
590
protected void storeRecentSketches (Sketch sketch ) {
588
591
if (sketch .isUntitled ()) {
589
592
return ;
You can’t perform that action at this time.
0 commit comments