summaryrefslogtreecommitdiffstats
path: root/src/android/app
diff options
context:
space:
mode:
authorCharles Lombardo <clombardo169@gmail.com>2023-05-31 08:59:11 +0200
committerbunnei <bunneidev@gmail.com>2023-06-03 09:06:05 +0200
commitad9c2356a88418ee14453a79b92a814ebe10a857 (patch)
tree43d32ce44ebb011d13e689a4eb58b1024157c450 /src/android/app
parentandroid: Prevent deleting the settings file while a game is running (diff)
downloadyuzu-ad9c2356a88418ee14453a79b92a814ebe10a857.tar
yuzu-ad9c2356a88418ee14453a79b92a814ebe10a857.tar.gz
yuzu-ad9c2356a88418ee14453a79b92a814ebe10a857.tar.bz2
yuzu-ad9c2356a88418ee14453a79b92a814ebe10a857.tar.lz
yuzu-ad9c2356a88418ee14453a79b92a814ebe10a857.tar.xz
yuzu-ad9c2356a88418ee14453a79b92a814ebe10a857.tar.zst
yuzu-ad9c2356a88418ee14453a79b92a814ebe10a857.zip
Diffstat (limited to 'src/android/app')
-rw-r--r--src/android/app/src/main/java/org/yuzu/yuzu_emu/fragments/EmulationFragment.kt23
-rw-r--r--src/android/app/src/main/res/layout/fragment_emulation.xml4
2 files changed, 20 insertions, 7 deletions
diff --git a/src/android/app/src/main/java/org/yuzu/yuzu_emu/fragments/EmulationFragment.kt b/src/android/app/src/main/java/org/yuzu/yuzu_emu/fragments/EmulationFragment.kt
index ce3f2639a..ea44733c1 100644
--- a/src/android/app/src/main/java/org/yuzu/yuzu_emu/fragments/EmulationFragment.kt
+++ b/src/android/app/src/main/java/org/yuzu/yuzu_emu/fragments/EmulationFragment.kt
@@ -354,12 +354,23 @@ class EmulationFragment : Fragment(), SurfaceHolder.Callback {
v.setPadding(left, cutInsets.top, right, 0)
- binding.showFpsText.setPadding(
- cutInsets.left,
- cutInsets.top,
- cutInsets.right,
- cutInsets.bottom
- )
+ // Ensure FPS text doesn't get cut off by rounded display corners
+ val sidePadding = resources.getDimensionPixelSize(R.dimen.spacing_xtralarge)
+ if (cutInsets.left == 0) {
+ binding.showFpsText.setPadding(
+ sidePadding,
+ cutInsets.top,
+ cutInsets.right,
+ cutInsets.bottom
+ )
+ } else {
+ binding.showFpsText.setPadding(
+ cutInsets.left,
+ cutInsets.top,
+ cutInsets.right,
+ cutInsets.bottom
+ )
+ }
windowInsets
}
}
diff --git a/src/android/app/src/main/res/layout/fragment_emulation.xml b/src/android/app/src/main/res/layout/fragment_emulation.xml
index 648b5aaed..74ec512af 100644
--- a/src/android/app/src/main/res/layout/fragment_emulation.xml
+++ b/src/android/app/src/main/res/layout/fragment_emulation.xml
@@ -32,11 +32,13 @@
android:id="@+id/show_fps_text"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
+ android:layout_gravity="left"
android:clickable="false"
android:focusable="false"
android:shadowColor="@android:color/black"
android:textColor="@android:color/white"
- android:textSize="12sp" />
+ android:textSize="12sp"
+ tools:ignore="RtlHardcoded" />
<Button
style="@style/Widget.Material3.Button.ElevatedButton"