Remove the bRomWriteable=FALSE, because saving in the port 2 with HP49/50 actually works in custom folder.

This commit is contained in:
dgis 2019-04-15 14:36:01 +02:00
parent df463a872f
commit 4b12c7a697
2 changed files with 17 additions and 11 deletions

View file

@ -292,7 +292,7 @@ JNIEXPORT void JNICALL Java_org_emulator_forty_eight_NativeLib_start(JNIEnv *env
// read emulator settings // read emulator settings
GetCurrentDirectory(ARRAYSIZEOF(szCurrentDirectory),szCurrentDirectory); GetCurrentDirectory(ARRAYSIZEOF(szCurrentDirectory),szCurrentDirectory);
//ReadSettings(); //ReadSettings();
bRomWriteable = FALSE; //bRomWriteable = FALSE;
_tcscpy(szCurrentDirectory, ""); _tcscpy(szCurrentDirectory, "");
_tcscpy(szEmuDirectory, "assets/calculators/"); _tcscpy(szEmuDirectory, "assets/calculators/");

View file

@ -610,19 +610,25 @@ public class MainActivity extends AppCompatActivity implements NavigationView.On
intent.addCategory(Intent.CATEGORY_OPENABLE); intent.addCategory(Intent.CATEGORY_OPENABLE);
intent.setType("*/*"); intent.setType("*/*");
int model = NativeLib.getCurrentModel(); int model = NativeLib.getCurrentModel();
String extension = "e48"; // HP48SX/GX // model 'S' 'G' String extension = "e48";
switch (model) { switch (model) {
case '6': case 'S': //HP48SX
case 'A': case 'G': //HP48GX
extension = "e38"; // HP38G extension = "e48";
case '6': //HP38G 64K RAM
case 'A': //HP38G 32K RAM
extension = "e38";
break; break;
case 'E': case 'E': // HP39G/(HP39G+/HP39GS)/HP40G/HP40GS
extension = "e39"; // HP39/40G extension = "e39";
break; break;
case '2': case 'P': // HP39G+/HP39GS
case 'Q': extension = "e39";
case 'X': break;
extension = "e49"; // HP49G case '2': // HP48GII
case 'Q': // HP49G+/HP50G
case 'X': // HP49G
extension = "e49";
break; break;
} }
intent.putExtra(Intent.EXTRA_TITLE, "emu48-state." + extension); intent.putExtra(Intent.EXTRA_TITLE, "emu48-state." + extension);