mirror of
https://github.com/libretro/RetroArch
synced 2025-02-13 21:40:27 +00:00
(Android) Standardize overlays and shaders directories for Android - now uses
the same named directories as iOS/Blackberry ports - lower-case folders (overlays and shaders_glsl)
This commit is contained in:
parent
7b0a77e6f2
commit
b33d4d29d2
@ -30,4 +30,11 @@
|
||||
<nature>com.android.ide.eclipse.adt.AndroidNature</nature>
|
||||
<nature>org.eclipse.jdt.core.javanature</nature>
|
||||
</natures>
|
||||
<linkedResources>
|
||||
<link>
|
||||
<name>assets/overlays</name>
|
||||
<type>2</type>
|
||||
<locationURI>PARENT-2-PROJECT_LOC/media/overlays</locationURI>
|
||||
</link>
|
||||
</linkedResources>
|
||||
</projectDescription>
|
||||
|
@ -7,7 +7,7 @@ import android.os.Bundle;
|
||||
public class OverlayActivity extends DirectoryActivity {
|
||||
@Override
|
||||
public void onCreate(Bundle savedInstanceState) {
|
||||
File overlayDir = new File(getBaseContext().getApplicationInfo().dataDir, "Overlays");
|
||||
File overlayDir = new File(getBaseContext().getApplicationInfo().dataDir, "overlays");
|
||||
if (overlayDir.exists())
|
||||
super.setStartDirectory(overlayDir.getAbsolutePath());
|
||||
|
||||
|
@ -188,14 +188,14 @@ public class RetroArch extends Activity implements
|
||||
//extractAssets(assets, cacheDir, "", 0);
|
||||
Log.i("ASSETS", "Extracting shader assets now ...");
|
||||
try {
|
||||
extractAssets(assets, dataDir, "Shaders", 1);
|
||||
extractAssets(assets, dataDir, "shaders_glsl", 1);
|
||||
} catch (IOException e) {
|
||||
Log.i("ASSETS", "Failed to extract shaders ...");
|
||||
}
|
||||
|
||||
Log.i("ASSETS", "Extracting overlay assets now ...");
|
||||
try {
|
||||
extractAssets(assets, dataDir, "Overlays", 1);
|
||||
extractAssets(assets, dataDir, "overlays", 1);
|
||||
} catch (IOException e) {
|
||||
Log.i("ASSETS", "Failed to extract overlays ...");
|
||||
}
|
||||
@ -496,7 +496,7 @@ public class RetroArch extends Activity implements
|
||||
|
||||
boolean useOverlay = prefs.getBoolean("input_overlay_enable", true);
|
||||
if (useOverlay) {
|
||||
String overlayPath = prefs.getString("input_overlay", getDataDir() + "/Overlays/snes-landscape.cfg");
|
||||
String overlayPath = prefs.getString("input_overlay", getDataDir() + "/overlays/snes-landscape.cfg");
|
||||
config.setString("input_overlay", overlayPath);
|
||||
config.setDouble("input_overlay_opacity", prefs.getFloat("input_overlay_opacity", 1.0f));
|
||||
} else {
|
||||
|
@ -7,7 +7,7 @@ import android.os.Bundle;
|
||||
public class ShaderActivity extends DirectoryActivity {
|
||||
@Override
|
||||
public void onCreate(Bundle savedInstanceState) {
|
||||
File shaderDir = new File(getBaseContext().getApplicationInfo().dataDir, "Shaders");
|
||||
File shaderDir = new File(getBaseContext().getApplicationInfo().dataDir, "shaders_glsl");
|
||||
if (shaderDir.exists())
|
||||
super.setStartDirectory(shaderDir.getAbsolutePath());
|
||||
|
||||
|
@ -304,7 +304,7 @@ void config_set_defaults(void)
|
||||
#elif defined(IOS)
|
||||
strlcpy(g_extern.overlay_dir, "/Applications/RetroArch.app/overlays/", sizeof(g_extern.overlay_dir));
|
||||
#elif defined(ANDROID)
|
||||
strlcpy(g_extern.overlay_dir, "/data/data/org.retroarch/Overlays/", sizeof(g_extern.overlay_dir));
|
||||
strlcpy(g_extern.overlay_dir, "/data/data/org.retroarch/overlays/", sizeof(g_extern.overlay_dir));
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -314,7 +314,7 @@ void config_set_defaults(void)
|
||||
#elif defined(IOS)
|
||||
strlcpy(g_settings.video.shader_dir, "/Applications/RetroArch.app/shaders_glsl/", sizeof(g_settings.video.shader_dir));
|
||||
#elif defined(ANDROID)
|
||||
strlcpy(g_settings.video.shader_dir, "/data/data/org.retroarch/Shaders/", sizeof(g_settings.video.shader_dir));
|
||||
strlcpy(g_settings.video.shader_dir, "/data/data/org.retroarch/shaders_glsl/", sizeof(g_settings.video.shader_dir));
|
||||
#endif
|
||||
#endif
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user