diff --git a/src/pandroid/app/src/main/java/com/panda3ds/pandroid/app/game/DrawerFragment.java b/src/pandroid/app/src/main/java/com/panda3ds/pandroid/app/game/DrawerFragment.java
index bd402b52..3506e054 100644
--- a/src/pandroid/app/src/main/java/com/panda3ds/pandroid/app/game/DrawerFragment.java
+++ b/src/pandroid/app/src/main/java/com/panda3ds/pandroid/app/game/DrawerFragment.java
@@ -12,6 +12,8 @@ import androidx.annotation.Nullable;
import androidx.appcompat.widget.AppCompatTextView;
import androidx.drawerlayout.widget.DrawerLayout;
import androidx.fragment.app.Fragment;
+import android.content.pm.ActivityInfo;
+import android.content.res.Configuration;
import com.google.android.material.navigation.NavigationView;
import com.panda3ds.pandroid.AlberDriver;
@@ -47,7 +49,6 @@ public class DrawerFragment extends Fragment implements DrawerLayout.DrawerListe
((AppCompatTextView)view.findViewById(R.id.game_publisher)).setText(game.getPublisher());
((NavigationView)view.findViewById(R.id.action_navigation)).setNavigationItemSelectedListener(this);
- ((NavigationView)view.findViewById(R.id.others_navigation)).setNavigationItemSelectedListener(this);
}
@Override
@@ -80,6 +81,17 @@ public class DrawerFragment extends Fragment implements DrawerLayout.DrawerListe
}
}
+ private void changeScreenOrientation() {
+ int currentOrientation = getResources().getConfiguration().orientation;
+
+ // Change the orientation
+ if (currentOrientation == Configuration.ORIENTATION_LANDSCAPE) {
+ requireActivity().setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_PORTRAIT);
+ } else {
+ requireActivity().setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_LANDSCAPE);
+ }
+}
+
@Override
public void onDrawerSlide(@NonNull View drawerView, float slideOffset) {}
@@ -106,6 +118,8 @@ public class DrawerFragment extends Fragment implements DrawerLayout.DrawerListe
requireActivity().finish();
} else if (id == R.id.lua_script){
new LuaDialogFragment().show(getParentFragmentManager(), null);
+ } else if (id == R.id.change_orientation) {
+ changeScreenOrientation();
}
return false;
diff --git a/src/pandroid/app/src/main/java/com/panda3ds/pandroid/app/game/LuaDialogFragment.java b/src/pandroid/app/src/main/java/com/panda3ds/pandroid/app/game/LuaDialogFragment.java
index 1db9f9c7..e7da87bf 100644
--- a/src/pandroid/app/src/main/java/com/panda3ds/pandroid/app/game/LuaDialogFragment.java
+++ b/src/pandroid/app/src/main/java/com/panda3ds/pandroid/app/game/LuaDialogFragment.java
@@ -12,6 +12,7 @@ import androidx.activity.result.contract.ActivityResultContracts;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.recyclerview.widget.RecyclerView;
+import com.google.android.material.button.MaterialButton;
import com.panda3ds.pandroid.AlberDriver;
import com.panda3ds.pandroid.R;
@@ -182,4 +183,4 @@ public class LuaDialogFragment extends BottomDialogFragment {
return FileUtils.getLastModified(absolutePath());
}
}
-}
\ No newline at end of file
+}
diff --git a/src/pandroid/app/src/main/res/drawable/rounded_selectable_item_background.xml b/src/pandroid/app/src/main/res/drawable/rounded_selectable_item_background.xml
new file mode 100644
index 00000000..fad2fe96
--- /dev/null
+++ b/src/pandroid/app/src/main/res/drawable/rounded_selectable_item_background.xml
@@ -0,0 +1,9 @@
+
+ -
+
+
+
+
+
+
diff --git a/src/pandroid/app/src/main/res/layout/activity_main.xml b/src/pandroid/app/src/main/res/layout/activity_main.xml
index 27da16a9..c0d0efd7 100644
--- a/src/pandroid/app/src/main/res/layout/activity_main.xml
+++ b/src/pandroid/app/src/main/res/layout/activity_main.xml
@@ -8,6 +8,14 @@
tools:context=".app.MainActivity"
android:background="?colorSurface">
+
+
-
\ No newline at end of file
+
diff --git a/src/pandroid/app/src/main/res/layout/dialog_lua_scripts.xml b/src/pandroid/app/src/main/res/layout/dialog_lua_scripts.xml
index 69a9d0a4..b0484879 100644
--- a/src/pandroid/app/src/main/res/layout/dialog_lua_scripts.xml
+++ b/src/pandroid/app/src/main/res/layout/dialog_lua_scripts.xml
@@ -1,9 +1,9 @@
-
@@ -12,7 +12,6 @@
android:layout_width="match_parent"
android:layout_height="match_parent">
-
-
-
-
-
+
-
\ No newline at end of file
+
diff --git a/src/pandroid/app/src/main/res/layout/fragment_game_drawer.xml b/src/pandroid/app/src/main/res/layout/fragment_game_drawer.xml
index fa81a503..c4a698ea 100644
--- a/src/pandroid/app/src/main/res/layout/fragment_game_drawer.xml
+++ b/src/pandroid/app/src/main/res/layout/fragment_game_drawer.xml
@@ -1,105 +1,97 @@
-
-
-
+
+ android:layout_height="match_parent"
+ android:orientation="vertical">
-
-
-
-
-
-
-
+
+ android:paddingLeft="10dp"
+ android:paddingRight="10dp"
+ android:minHeight="190dp"
+ android:background="?colorSurfaceVariant">
-
+
+
+
+
+
+
+ android:layout_marginBottom="20dp">
-
+
-
+
-
+
-
+
+
+
+
+
+ android:orientation="vertical"
+ android:gravity="start"
+ android:layout_marginTop="195dp">
-
+ app:menu="@menu/game_drawer_settings"
+ android:background="?colorSurface"
+ android:theme="@style/Widget.App.NavigationView"
+ app:subheaderTextAppearance="@style/TextAppearanceGameDrawerSubTitle"/>
-
+
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
+
diff --git a/src/pandroid/app/src/main/res/layout/fragment_games.xml b/src/pandroid/app/src/main/res/layout/fragment_games.xml
index ee69fdc8..0538aeb6 100644
--- a/src/pandroid/app/src/main/res/layout/fragment_games.xml
+++ b/src/pandroid/app/src/main/res/layout/fragment_games.xml
@@ -1,6 +1,9 @@
-
+ android:gravity="center"
+ app:rippleColor="?colorOnSurfaceVariant"
+ app:backgroundTint="?colorPrimary"
+ tools:ignore="PrivateResource"/>
-
\ No newline at end of file
+
diff --git a/src/pandroid/app/src/main/res/layout/fragment_search.xml b/src/pandroid/app/src/main/res/layout/fragment_search.xml
index 367b0f1d..3d987ff9 100644
--- a/src/pandroid/app/src/main/res/layout/fragment_search.xml
+++ b/src/pandroid/app/src/main/res/layout/fragment_search.xml
@@ -9,16 +9,17 @@
+ android:paddingHorizontal="20dp"
+ android:background="?colorSurfaceVariant">
-
@@ -46,4 +47,4 @@
-
\ No newline at end of file
+
diff --git a/src/pandroid/app/src/main/res/layout/holder_game.xml b/src/pandroid/app/src/main/res/layout/holder_game.xml
index b2d46d1b..fd14573f 100644
--- a/src/pandroid/app/src/main/res/layout/holder_game.xml
+++ b/src/pandroid/app/src/main/res/layout/holder_game.xml
@@ -4,13 +4,17 @@
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="wrap_content"
+ android:foreground="@drawable/rounded_selectable_item_background"
+ android:focusable="true"
android:orientation="vertical"
android:padding="15dp">
-
+ android:layout_margin="10dp"
+ app:shapeAppearance="?attr/shapeAppearanceCornerLarge">
-
+
-
\ No newline at end of file
+
diff --git a/src/pandroid/app/src/main/res/layout/holder_lua_script.xml b/src/pandroid/app/src/main/res/layout/holder_lua_script.xml
index a1865c3f..071d3c8c 100644
--- a/src/pandroid/app/src/main/res/layout/holder_lua_script.xml
+++ b/src/pandroid/app/src/main/res/layout/holder_lua_script.xml
@@ -1,43 +1,50 @@
-
+ app:cardBackgroundColor="?attr/colorSurfaceVariant"
+ app:cardCornerRadius="8dp"
+ android:layout_gravity="center"
+ android:layout_margin="10dp">
-
-
-
+ android:orientation="vertical"
+ android:gravity="center"
+ android:padding="10dp">
-
+
+
-
+
+
+
-
-
\ No newline at end of file
+
diff --git a/src/pandroid/app/src/main/res/layout/preference_simple_about.xml b/src/pandroid/app/src/main/res/layout/preference_simple_about.xml
index 9364de36..cf6370b9 100644
--- a/src/pandroid/app/src/main/res/layout/preference_simple_about.xml
+++ b/src/pandroid/app/src/main/res/layout/preference_simple_about.xml
@@ -2,6 +2,7 @@
@@ -26,4 +27,4 @@
android:alpha="0.5"
android:textColor="?colorOnSurface"/>
-
\ No newline at end of file
+
diff --git a/src/pandroid/app/src/main/res/menu/game_drawer_actions.xml b/src/pandroid/app/src/main/res/menu/game_drawer_actions.xml
deleted file mode 100644
index 9fd3264a..00000000
--- a/src/pandroid/app/src/main/res/menu/game_drawer_actions.xml
+++ /dev/null
@@ -1,11 +0,0 @@
-
-
\ No newline at end of file
diff --git a/src/pandroid/app/src/main/res/menu/game_drawer_others.xml b/src/pandroid/app/src/main/res/menu/game_drawer_others.xml
deleted file mode 100644
index b6dd4897..00000000
--- a/src/pandroid/app/src/main/res/menu/game_drawer_others.xml
+++ /dev/null
@@ -1,7 +0,0 @@
-
-
\ No newline at end of file
diff --git a/src/pandroid/app/src/main/res/menu/game_drawer_settings.xml b/src/pandroid/app/src/main/res/menu/game_drawer_settings.xml
new file mode 100644
index 00000000..12fa6d47
--- /dev/null
+++ b/src/pandroid/app/src/main/res/menu/game_drawer_settings.xml
@@ -0,0 +1,35 @@
+
diff --git a/src/pandroid/app/src/main/res/values/themes.xml b/src/pandroid/app/src/main/res/values/themes.xml
index 422299a4..79ecdd60 100644
--- a/src/pandroid/app/src/main/res/values/themes.xml
+++ b/src/pandroid/app/src/main/res/values/themes.xml
@@ -42,6 +42,10 @@
+
+