Always copy potentially new symbols when booting in debug mode

This commit is contained in:
Aaron Culliney 2015-10-20 20:42:02 -07:00
parent b1b234defc
commit 4abe8a8c08
2 changed files with 9 additions and 1 deletions

View File

@ -146,9 +146,14 @@ public class Apple2Activity extends Activity {
// run first-time initializations
if (!Apple2Preferences.FIRST_TIME_CONFIGURED.booleanValue(this)) {
Apple2DisksMenu.firstTime(this);
Apple2DisksMenu.exposeSymbols(this);
Apple2Preferences.KeypadPreset.IJKM_SPACE.apply(this);
}
Apple2Preferences.FIRST_TIME_CONFIGURED.saveBoolean(this, true);
if (BuildConfig.DEBUG) {
// always copy new symbols while developing/iterating
Apple2DisksMenu.exposeSymbols(this);
}
// get device audio parameters for native OpenSLES
int sampleRate = DevicePropertyCalculator.getRecommendedSampleRate(this);

View File

@ -128,12 +128,15 @@ public class Apple2DisksMenu implements Apple2MenuView {
recursivelyCopyAPKAssets(activity, /*from APK directory:*/"disks", /*to location:*/new File(sDataDir, "disks").getAbsolutePath());
recursivelyCopyAPKAssets(activity, /*from APK directory:*/"keyboards", /*to location:*/new File(sDataDir, "keyboards").getAbsolutePath());
recursivelyCopyAPKAssets(activity, /*from APK directory:*/"shaders", /*to location:*/new File(sDataDir, "shaders").getAbsolutePath());
recursivelyCopyAPKAssets(activity, /*from APK directory:*/"symbols", /*to location:*/new File(sDataDir, "symbols").getAbsolutePath());
// expose keyboards to modding
recursivelyCopyAPKAssets(activity, /*from APK directory:*/"keyboards", /*to location:*/sExternalFilesDir.getAbsolutePath());
}
public static void exposeSymbols(Apple2Activity activity) {
recursivelyCopyAPKAssets(activity, /*from APK directory:*/"symbols", /*to location:*/new File(sDataDir, "symbols").getAbsolutePath());
}
// ------------------------------------------------------------------------
// Apple2MenuView interface methods