diff --git a/android/native/jni/input_android.c b/android/native/jni/input_android.c
index 880785398c..a7457f7f9f 100644
--- a/android/native/jni/input_android.c
+++ b/android/native/jni/input_android.c
@@ -722,6 +722,7 @@ static void android_input_set_keybinds(void *data, unsigned device,
sizeof(g_settings.input.device_names[port]));
g_settings.input.dpad_emulation[port] = ANALOG_DPAD_DUALANALOG;
+ keycode_lut[AKEYCODE_BUTTON_MODE] |= ((RARCH_MENU_TOGGLE + 1) << shift);
keycode_lut[AKEYCODE_BACK] |= ((RETRO_DEVICE_ID_JOYPAD_SELECT+1) << shift);
keycode_lut[AKEYCODE_BUTTON_SELECT] |= ((RETRO_DEVICE_ID_JOYPAD_SELECT+1) << shift);
keycode_lut[AKEYCODE_BUTTON_START] |= ((RETRO_DEVICE_ID_JOYPAD_START+1) << shift);
diff --git a/android/phoenix/AndroidManifest.xml b/android/phoenix/AndroidManifest.xml
index 1b0d909718..d0dc0587b0 100644
--- a/android/phoenix/AndroidManifest.xml
+++ b/android/phoenix/AndroidManifest.xml
@@ -29,6 +29,7 @@
+
diff --git a/android/phoenix/src/org/retroarch/browser/DirectoryActivity.java b/android/phoenix/src/org/retroarch/browser/DirectoryActivity.java
index 96bdfb0b36..5199054ff1 100644
--- a/android/phoenix/src/org/retroarch/browser/DirectoryActivity.java
+++ b/android/phoenix/src/org/retroarch/browser/DirectoryActivity.java
@@ -12,75 +12,7 @@ import android.os.*;
import android.preference.PreferenceManager;
import android.widget.*;
import android.view.*;
-import android.graphics.drawable.*;
-class FileWrapper implements IconAdapterItem {
- public final File file;
- public final boolean parentItem;
- public final boolean dirSelectItem;
-
- protected final boolean enabled;
-
- public static final int DIRSELECT = 0;
- public static final int PARENT = 1;
- public static final int FILE = 2;
-
- protected final int typeIndex;
-
- public FileWrapper(File aFile, int type, boolean aIsEnabled) {
- file = aFile;
-
- parentItem = type == PARENT;
- dirSelectItem = type == DIRSELECT;
- typeIndex = type == FILE ? (FILE + (file.isDirectory() ? 0 : 1)) : type;
-
- enabled = parentItem || dirSelectItem || aIsEnabled;
- }
-
- @Override
- public boolean isEnabled() {
- return enabled;
- }
-
- @Override
- public String getText() {
- if (dirSelectItem)
- return "[[Use this directory]]";
- else if (parentItem)
- return "[Parent Directory]";
- else
- return file.getName();
- }
-
- @Override
- public int getIconResourceId() {
- if (!parentItem && !dirSelectItem) {
- return file.isFile() ? R.drawable.ic_file : R.drawable.ic_dir;
- } else {
- return R.drawable.ic_dir;
- }
- }
-
- @Override
- public Drawable getIconDrawable() {
- return null;
- }
-
- public int compareTo(FileWrapper aOther) {
- if (aOther != null) {
- // Who says ternary is hard to follow
- if (isEnabled() == aOther.isEnabled()) {
- return (typeIndex == aOther.typeIndex) ? file
- .compareTo(aOther.file)
- : ((typeIndex < aOther.typeIndex) ? -1 : 1);
- } else {
- return isEnabled() ? -1 : 1;
- }
- }
-
- return -1;
- }
-}
public class DirectoryActivity extends Activity implements
AdapterView.OnItemClickListener {
diff --git a/android/phoenix/src/org/retroarch/browser/FileWrapper.java b/android/phoenix/src/org/retroarch/browser/FileWrapper.java
new file mode 100644
index 0000000000..8af274db16
--- /dev/null
+++ b/android/phoenix/src/org/retroarch/browser/FileWrapper.java
@@ -0,0 +1,75 @@
+package org.retroarch.browser;
+
+import java.io.File;
+
+import org.retroarch.R;
+
+import android.graphics.drawable.Drawable;
+
+class FileWrapper implements IconAdapterItem {
+ public final File file;
+ public final boolean parentItem;
+ public final boolean dirSelectItem;
+
+ protected final boolean enabled;
+
+ public static final int DIRSELECT = 0;
+ public static final int PARENT = 1;
+ public static final int FILE = 2;
+
+ protected final int typeIndex;
+
+ public FileWrapper(File aFile, int type, boolean aIsEnabled) {
+ file = aFile;
+
+ parentItem = type == PARENT;
+ dirSelectItem = type == DIRSELECT;
+ typeIndex = type == FILE ? (FILE + (file.isDirectory() ? 0 : 1)) : type;
+
+ enabled = parentItem || dirSelectItem || aIsEnabled;
+ }
+
+ @Override
+ public boolean isEnabled() {
+ return enabled;
+ }
+
+ @Override
+ public String getText() {
+ if (dirSelectItem)
+ return "[[Use this directory]]";
+ else if (parentItem)
+ return "[Parent Directory]";
+ else
+ return file.getName();
+ }
+
+ @Override
+ public int getIconResourceId() {
+ if (!parentItem && !dirSelectItem) {
+ return file.isFile() ? R.drawable.ic_file : R.drawable.ic_dir;
+ } else {
+ return R.drawable.ic_dir;
+ }
+ }
+
+ @Override
+ public Drawable getIconDrawable() {
+ return null;
+ }
+
+ public int compareTo(FileWrapper aOther) {
+ if (aOther != null) {
+ // Who says ternary is hard to follow
+ if (isEnabled() == aOther.isEnabled()) {
+ return (typeIndex == aOther.typeIndex) ? file
+ .compareTo(aOther.file)
+ : ((typeIndex < aOther.typeIndex) ? -1 : 1);
+ } else {
+ return isEnabled() ? -1 : 1;
+ }
+ }
+
+ return -1;
+ }
+}