mirror of
https://github.com/izzy2lost/Starship.git
synced 2026-07-05 15:19:42 -07:00
oh boy. this rabbit hole
This commit is contained in:
@@ -176,7 +176,6 @@ protected void onCreate(Bundle savedInstanceState) {
|
||||
|
||||
super.onCreate(savedInstanceState);
|
||||
|
||||
try { nativeSetAppDirs(getSaveDir()); } catch (Throwable t) { Log.w(TAG, "nativeSetAppDirs failed", t); }
|
||||
setupControllerOverlay();
|
||||
attachController();
|
||||
|
||||
@@ -209,7 +208,6 @@ setupControllerOverlay();
|
||||
out.getFD().sync();
|
||||
Log.i(TAG, "sf64.o2r copied from user folder to internal storage");
|
||||
|
||||
try { nativeSetAppDirs(getSaveDir()); } catch (Throwable t) { Log.w(TAG, "nativeSetAppDirs failed", t); }
|
||||
} catch (IOException e) {
|
||||
Log.e(TAG, "Failed to copy sf64.o2r from user folder", e);
|
||||
}
|
||||
@@ -517,7 +515,6 @@ private void handleFolderSelection(Uri treeUri, int returnedFlags) {
|
||||
Log.i(TAG, "sf64.o2r copied from user folder to internal storage during folder selection");
|
||||
|
||||
|
||||
try { nativeSetAppDirs(getSaveDir()); } catch (Throwable t) { Log.w(TAG, "nativeSetAppDirs failed", t); }
|
||||
// Also sync mods
|
||||
syncModsFromUserFolder();
|
||||
|
||||
@@ -635,7 +632,6 @@ private void handleRomFileSelection(Uri selectedFileUri) {
|
||||
Log.i(TAG, "sf64.o2r copied to internal (" + total + " bytes): " + dest.getAbsolutePath());
|
||||
|
||||
|
||||
try { nativeSetAppDirs(getSaveDir()); } catch (Throwable t) { Log.w(TAG, "nativeSetAppDirs failed", t); }
|
||||
runOnUiThread(() -> showPortraitDialog("sf64.o2r ready",
|
||||
"sf64.o2r copied. Restart to load the game.",
|
||||
DialogActivity.DIALOG_TYPE_FILE_READY));
|
||||
|
||||
+2
-8
@@ -114,8 +114,6 @@ GameEngine::GameEngine() {
|
||||
{
|
||||
const char* sdlInternal = SDL_AndroidGetInternalStoragePath();
|
||||
if (sdlInternal && *sdlInternal) {
|
||||
pm->SetAppDirectoryPath(sdlInternal);
|
||||
pm->SetUserDirectoryPath(sdlInternal);
|
||||
SPDLOG_INFO("Android app/user dir set to: {}", sdlInternal);
|
||||
} else {
|
||||
SPDLOG_WARN("SDL_AndroidGetInternalStoragePath() returned null; using defaults");
|
||||
@@ -903,10 +901,6 @@ extern "C" void GameEngine_Free(void* ptr) {
|
||||
#ifdef __ANDROID__
|
||||
extern "C" JNIEXPORT void JNICALL
|
||||
Java_com_starship_android_MainActivity_nativeSetAppDirs(JNIEnv* env, jclass, jstring jpath) {
|
||||
// No-op: paths resolved via SDL_AndroidGetInternalStoragePath in GameEngine::GameEngine
|
||||
}", p);
|
||||
env->ReleaseStringUTFChars(jpath, p);
|
||||
}
|
||||
// No-op: paths resolved via SDL_AndroidGetInternalStoragePath in GameEngine::GameEngine()
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user