Commit 0040611 1 parent 91ac520 commit 0040611 Copy full SHA for 0040611
File tree 2 files changed +15
-0
lines changed
src/main/java/com/vimasig/bozar/ui
2 files changed +15
-0
lines changed Original file line number Diff line number Diff line change @@ -87,4 +87,10 @@ public BozarConfig generateConfig() {
87
87
}
88
88
return bozarConfig ;
89
89
}
90
+
91
+ public void loadDefaultConfig () throws IOException {
92
+ File f = new File ("bozarConfig.json" );
93
+ if (f .exists () && f .isFile ())
94
+ this .loadConfig (f );
95
+ }
90
96
}
Original file line number Diff line number Diff line change 9
9
import javafx .stage .FileChooser ;
10
10
11
11
import java .io .File ;
12
+ import java .io .IOException ;
12
13
import java .io .OutputStream ;
13
14
import java .io .PrintStream ;
14
15
import java .nio .file .Path ;
@@ -135,6 +136,14 @@ public void initialize() {
135
136
libraries .getItems ().remove (index );
136
137
});
137
138
139
+ // Load default config
140
+ try {
141
+ this .configManager .loadDefaultConfig ();
142
+ } catch (IOException e ) {
143
+ e .printStackTrace ();
144
+ this .log ("Cannot load default config" );
145
+ }
146
+
138
147
// Done
139
148
log ("Loaded." );
140
149
}
You can’t perform that action at this time.
0 commit comments