mirror of
https://github.com/libretro/RetroArch
synced 2025-02-03 17:54:04 +00:00
[ANDROID] pass phone version to activity
This commit is contained in:
parent
61b42c82e2
commit
d1b9015aef
@ -34,6 +34,7 @@ struct droid
|
||||
unsigned width;
|
||||
unsigned height;
|
||||
struct saved_state state;
|
||||
int version;
|
||||
};
|
||||
|
||||
extern struct droid g_android;
|
||||
|
@ -283,11 +283,15 @@ static void* android_app_entry(void* param)
|
||||
|
||||
char rom_path[512];
|
||||
char libretro_path[512];
|
||||
char android_version[16];
|
||||
|
||||
// Get arguments */
|
||||
android_get_char_argv(rom_path, sizeof(rom_path), "ROM");
|
||||
android_get_char_argv(libretro_path, sizeof(libretro_path), "LIBRETRO");
|
||||
android_get_char_argv(android_version, sizeof(android_version), "ANDROIDVER");
|
||||
g_android.version = atoi(android_version);
|
||||
|
||||
RARCH_LOG("Android version: %d\n", g_android.version);
|
||||
RARCH_LOG("Checking arguments passed...\n");
|
||||
RARCH_LOG("ROM Filename: [%s].\n", rom_path);
|
||||
RARCH_LOG("Libretro path: [%s].\n", libretro_path);
|
||||
|
@ -91,6 +91,7 @@ public class phoenix extends Activity
|
||||
myIntent = new Intent(this, NativeActivity.class);
|
||||
myIntent.putExtra("ROM", data.getStringExtra("PATH"));
|
||||
myIntent.putExtra("LIBRETRO", libretro_path);
|
||||
myIntent.putExtra("ANDROIDVER", Integer.toString(android.os.Build.VERSION.SDK_INT));
|
||||
startActivity(myIntent);
|
||||
}
|
||||
else
|
||||
|
Loading…
x
Reference in New Issue
Block a user