mirror of
https://github.com/processing/processing4.git
synced 2026-02-11 01:29:17 +01:00
dh 1 X save last-used serial to sketch.properties on quit
This commit is contained in:
@@ -381,6 +381,11 @@ public class PdeEditor extends JPanel {
|
||||
skNew();
|
||||
}
|
||||
|
||||
String serialPort = skprops.getProperty("serial.port");
|
||||
if(serialPort != null) {
|
||||
PdeBase.properties.put("serial.port", serialPort);
|
||||
}
|
||||
|
||||
boolean ee = new Boolean(skprops.getProperty("editor.external", "false")).booleanValue();
|
||||
setExternalEditor(ee);
|
||||
|
||||
@@ -1702,6 +1707,8 @@ afterwards, some of these steps need a cleanup function
|
||||
|
||||
skprops.put("editor.external", externalEditor ? "true" : "false");
|
||||
|
||||
skprops.put("serial.port", PdeBase.get("serial.port", "unspecified"));
|
||||
|
||||
skprops.save(output, "auto-generated by pde, please don't touch");
|
||||
|
||||
} catch (IOException e) {
|
||||
|
||||
Reference in New Issue
Block a user