Merge pull request #11952 from K0bin/no-per-game-driver

Android: Remove GPU driver from per-game settings
This commit is contained in:
JosJuice 2023-06-25 19:00:01 +02:00 committed by GitHub
commit ac53ab184c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -65,7 +65,12 @@ class SettingsFragmentPresenter(
controllerNumber = menuTag.subType
} else if (menuTag.isSerialPort1Menu) {
serialPort1Type = extras.getInt(ARG_SERIALPORT1_TYPE)
} else if (menuTag == MenuTag.GRAPHICS) {
} else if (
menuTag == MenuTag.GRAPHICS
&& this.gameId.isNullOrEmpty()
&& !NativeLibrary.IsRunning()
&& GpuDriverHelper.supportsCustomDriverLoading()
) {
this.gpuDriver =
GpuDriverHelper.getInstalledDriverMetadata() ?: GpuDriverHelper.getSystemDriverMetadata(
context.applicationContext
@ -1265,7 +1270,11 @@ class SettingsFragmentPresenter(
)
)
if (GpuDriverHelper.supportsCustomDriverLoading() && this.gpuDriver != null) {
if (
this.gpuDriver != null && this.gameId.isNullOrEmpty()
&& !NativeLibrary.IsRunning()
&& GpuDriverHelper.supportsCustomDriverLoading()
) {
sl.add(
SubmenuSetting(
context,