diff --git a/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/adapters/GameAdapter.java b/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/adapters/GameAdapter.java index f83aaeb575..66ddd567fc 100644 --- a/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/adapters/GameAdapter.java +++ b/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/adapters/GameAdapter.java @@ -155,16 +155,6 @@ public final class GameAdapter extends RecyclerView.Adapter impl GameViewHolder holder = (GameViewHolder) view.getTag(); String gameId = holder.gameFile.getGameId(); - if (gameId.isEmpty()) - { - AlertDialog.Builder builder = new AlertDialog.Builder(activity, R.style.DolphinDialogBase); - builder.setTitle("Game Settings"); - builder.setMessage("Files without game IDs don't support game-specific settings."); - - builder.show(); - return true; - } - GamePropertiesDialog fragment = GamePropertiesDialog.newInstance(holder.gameFile); ((FragmentActivity) view.getContext()).getSupportFragmentManager().beginTransaction() .add(fragment, GamePropertiesDialog.TAG).commit(); diff --git a/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/dialogs/GamePropertiesDialog.java b/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/dialogs/GamePropertiesDialog.java index 8ac4990421..8ef63c3d6a 100644 --- a/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/dialogs/GamePropertiesDialog.java +++ b/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/dialogs/GamePropertiesDialog.java @@ -53,10 +53,14 @@ public class GamePropertiesDialog extends DialogFragment final String path = requireArguments().getString(ARG_PATH); final String gameId = requireArguments().getString(ARG_GAMEID); final int revision = requireArguments().getInt(ARG_REVISION); - final boolean isWii = requireArguments().getInt(ARG_PLATFORM) != Platform.GAMECUBE.toInt(); + final int platform = requireArguments().getInt(ARG_PLATFORM); final boolean shouldAllowConversion = requireArguments().getBoolean(ARG_SHOULD_ALLOW_CONVERSION); + final boolean isDisc = platform == Platform.GAMECUBE.toInt() || + platform == Platform.WII.toInt(); + final boolean isWii = platform != Platform.GAMECUBE.toInt(); + AlertDialogItemsBuilder itemsBuilder = new AlertDialogItemsBuilder(requireContext()); itemsBuilder.add(R.string.properties_details, (dialog, i) -> @@ -69,15 +73,18 @@ public class GamePropertiesDialog extends DialogFragment ConvertActivity.launch(getContext(), path)); } - itemsBuilder.add(R.string.properties_set_default_iso, (dialog, i) -> + if (isDisc) { - try (Settings settings = new Settings()) + itemsBuilder.add(R.string.properties_set_default_iso, (dialog, i) -> { - settings.loadSettings(); - StringSetting.MAIN_DEFAULT_ISO.setString(settings, path); - settings.saveSettings(null, getContext()); - } - }); + try (Settings settings = new Settings()) + { + settings.loadSettings(); + StringSetting.MAIN_DEFAULT_ISO.setString(settings, path); + settings.saveSettings(null, getContext()); + } + }); + } itemsBuilder.add(R.string.properties_edit_game_settings, (dialog, i) -> SettingsActivity.launch(getContext(), MenuTag.SETTINGS, gameId, revision, isWii)); diff --git a/Source/Android/app/src/main/res/values/arrays.xml b/Source/Android/app/src/main/res/values/arrays.xml index 0f86b9ba6d..c08a518e5f 100644 --- a/Source/Android/app/src/main/res/values/arrays.xml +++ b/Source/Android/app/src/main/res/values/arrays.xml @@ -322,6 +322,7 @@ Russia Spain Taiwan + World Unknown