1
0
Fork 0
mirror of https://github.com/PabloMK7/citra.git synced 2025-07-04 06:25:15 +00:00

Android: replace company in the game card with titleId.

TitleId is more useful for users than companies
because it can help them find game saves and the cheat file.
This commit is contained in:
kongfl888 2024-08-06 08:29:16 +08:00
parent e55e619328
commit 316b4348ea
2 changed files with 6 additions and 6 deletions
src/android/app/src/main
java/org/citra/citra_emu/adapters
res/layout

View file

@ -148,14 +148,14 @@ class GameAdapter(private val activity: AppCompatActivity) :
} else { } else {
View.VISIBLE View.VISIBLE
} }
binding.textCompany.visibility = if (game.company.isEmpty()) { binding.textGameId.visibility = if (game.titleId == 0L) {
View.GONE View.GONE
} else { } else {
View.VISIBLE View.VISIBLE
} }
binding.textGameTitle.text = game.title binding.textGameTitle.text = game.title
binding.textCompany.text = game.company binding.textGameId.text = String.format("ID: %016X", game.titleId)
binding.textFilename.text = game.filename binding.textFilename.text = game.filename
val backgroundColorId = val backgroundColorId =
@ -178,8 +178,8 @@ class GameAdapter(private val activity: AppCompatActivity) :
binding.textGameTitle.ellipsize = TextUtils.TruncateAt.MARQUEE binding.textGameTitle.ellipsize = TextUtils.TruncateAt.MARQUEE
binding.textGameTitle.isSelected = true binding.textGameTitle.isSelected = true
binding.textCompany.ellipsize = TextUtils.TruncateAt.MARQUEE binding.textGameId.ellipsize = TextUtils.TruncateAt.MARQUEE
binding.textCompany.isSelected = true binding.textGameId.isSelected = true
binding.textFilename.ellipsize = TextUtils.TruncateAt.MARQUEE binding.textFilename.ellipsize = TextUtils.TruncateAt.MARQUEE
binding.textFilename.isSelected = true binding.textFilename.isSelected = true

View file

@ -52,7 +52,7 @@
tools:text="The Legend of Zelda\nOcarina of Time 3D" /> tools:text="The Legend of Zelda\nOcarina of Time 3D" />
<TextView <TextView
android:id="@+id/text_company" android:id="@+id/text_game_id"
style="@style/TextAppearance.Material3.BodySmall" style="@style/TextAppearance.Material3.BodySmall"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
@ -61,7 +61,7 @@
android:marqueeRepeatLimit="marquee_forever" android:marqueeRepeatLimit="marquee_forever"
android:ellipsize="none" android:ellipsize="none"
android:requiresFadingEdge="horizontal" android:requiresFadingEdge="horizontal"
tools:text="Nintendo" /> tools:text="0004000000033400" />
<TextView <TextView
android:id="@+id/text_filename" android:id="@+id/text_filename"