From 4af2e4097662c116c4365d0750f7bc0539d43c8f Mon Sep 17 00:00:00 2001 From: lizzie Date: Thu, 2 Oct 2025 18:27:58 +0000 Subject: [PATCH 1/5] [android] allow use of mouse and keyboard on motion events Signed-off-by: lizzie --- .../org/yuzu/yuzu_emu/activities/EmulationActivity.kt | 8 ++++++-- .../yuzu_emu/features/settings/ui/InputDialogFragment.kt | 8 ++++++-- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/src/android/app/src/main/java/org/yuzu/yuzu_emu/activities/EmulationActivity.kt b/src/android/app/src/main/java/org/yuzu/yuzu_emu/activities/EmulationActivity.kt index da40453497..ba60aeace2 100644 --- a/src/android/app/src/main/java/org/yuzu/yuzu_emu/activities/EmulationActivity.kt +++ b/src/android/app/src/main/java/org/yuzu/yuzu_emu/activities/EmulationActivity.kt @@ -230,7 +230,9 @@ class EmulationActivity : AppCompatActivity(), SensorEventListener { override fun dispatchKeyEvent(event: KeyEvent): Boolean { if (event.source and InputDevice.SOURCE_JOYSTICK != InputDevice.SOURCE_JOYSTICK && - event.source and InputDevice.SOURCE_GAMEPAD != InputDevice.SOURCE_GAMEPAD + event.source and InputDevice.SOURCE_GAMEPAD != InputDevice.SOURCE_GAMEPAD && + event.source and InputDevice.SOURCE_KEYBOARD != InputDevice.SOURCE_KEYBOARD && + event.source and InputDevice.SOURCE_MOUSE != InputDevice.SOURCE_MOUSE ) { return super.dispatchKeyEvent(event) } @@ -244,7 +246,9 @@ class EmulationActivity : AppCompatActivity(), SensorEventListener { override fun dispatchGenericMotionEvent(event: MotionEvent): Boolean { if (event.source and InputDevice.SOURCE_JOYSTICK != InputDevice.SOURCE_JOYSTICK && - event.source and InputDevice.SOURCE_GAMEPAD != InputDevice.SOURCE_GAMEPAD + event.source and InputDevice.SOURCE_GAMEPAD != InputDevice.SOURCE_GAMEPAD && + event.source and InputDevice.SOURCE_KEYBOARD != InputDevice.SOURCE_KEYBOARD && + event.source and InputDevice.SOURCE_MOUSE != InputDevice.SOURCE_MOUSE ) { return super.dispatchGenericMotionEvent(event) } diff --git a/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/ui/InputDialogFragment.kt b/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/ui/InputDialogFragment.kt index 16a1d05044..bc54fddc09 100644 --- a/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/ui/InputDialogFragment.kt +++ b/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/ui/InputDialogFragment.kt @@ -149,7 +149,9 @@ class InputDialogFragment : DialogFragment() { private fun onKeyEvent(event: KeyEvent): Boolean { if (event.source and InputDevice.SOURCE_JOYSTICK != InputDevice.SOURCE_JOYSTICK && - event.source and InputDevice.SOURCE_GAMEPAD != InputDevice.SOURCE_GAMEPAD + event.source and InputDevice.SOURCE_GAMEPAD != InputDevice.SOURCE_GAMEPAD && + event.source and InputDevice.SOURCE_KEYBOARD != InputDevice.SOURCE_KEYBOARD && + event.source and InputDevice.SOURCE_MOUSE != InputDevice.SOURCE_MOUSE ) { return false } @@ -173,7 +175,9 @@ class InputDialogFragment : DialogFragment() { private fun onMotionEvent(event: MotionEvent): Boolean { if (event.source and InputDevice.SOURCE_JOYSTICK != InputDevice.SOURCE_JOYSTICK && - event.source and InputDevice.SOURCE_GAMEPAD != InputDevice.SOURCE_GAMEPAD + event.source and InputDevice.SOURCE_GAMEPAD != InputDevice.SOURCE_GAMEPAD && + event.source and InputDevice.SOURCE_KEYBOARD != InputDevice.SOURCE_KEYBOARD && + event.source and InputDevice.SOURCE_MOUSE != InputDevice.SOURCE_MOUSE ) { return false } From 5ebcda288f35a25f2a9836e1048911fb862c405b Mon Sep 17 00:00:00 2001 From: lizzie Date: Thu, 2 Oct 2025 21:22:19 +0000 Subject: [PATCH 2/5] fix license Signed-off-by: lizzie --- .../yuzu/yuzu_emu/features/settings/ui/InputDialogFragment.kt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/ui/InputDialogFragment.kt b/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/ui/InputDialogFragment.kt index bc54fddc09..d07a6e6aea 100644 --- a/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/ui/InputDialogFragment.kt +++ b/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/ui/InputDialogFragment.kt @@ -1,3 +1,6 @@ +// SPDX-FileCopyrightText: Copyright 2025 Eden Emulator Project +// SPDX-License-Identifier: GPL-3.0-or-later + // SPDX-FileCopyrightText: 2024 yuzu Emulator Project // SPDX-License-Identifier: GPL-2.0-or-later From 1a13e79c3d8619ff302d9c77eacf1a35c2210b66 Mon Sep 17 00:00:00 2001 From: crueter Date: Sun, 5 Oct 2025 00:00:52 +0200 Subject: [PATCH 3/5] [cmake] fix video_core and tests comp errors on Windows (#2631) did not link to video_core thus did not properly propagate the GPUOpen target thus failed to find vk_mem_alloc also msvc sucks Signed-off-by: crueter Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/2631 Reviewed-by: MaranBr --- src/tests/CMakeLists.txt | 5 ++++- src/video_core/vulkan_common/vma.h | 8 ++++++++ 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/src/tests/CMakeLists.txt b/src/tests/CMakeLists.txt index 1e158f3759..c1fdd374ef 100644 --- a/src/tests/CMakeLists.txt +++ b/src/tests/CMakeLists.txt @@ -1,3 +1,6 @@ +# SPDX-FileCopyrightText: Copyright 2025 Eden Emulator Project +# SPDX-License-Identifier: GPL-3.0-or-later + # SPDX-FileCopyrightText: 2018 yuzu Emulator Project # SPDX-License-Identifier: GPL-2.0-or-later @@ -21,7 +24,7 @@ add_executable(tests create_target_directory_groups(tests) -target_link_libraries(tests PRIVATE common core input_common) +target_link_libraries(tests PRIVATE common core input_common video_core) target_link_libraries(tests PRIVATE ${PLATFORM_LIBRARIES} Catch2::Catch2WithMain Threads::Threads) add_test(NAME tests COMMAND tests) diff --git a/src/video_core/vulkan_common/vma.h b/src/video_core/vulkan_common/vma.h index 911c1114b2..e022b2bf7d 100644 --- a/src/video_core/vulkan_common/vma.h +++ b/src/video_core/vulkan_common/vma.h @@ -10,4 +10,12 @@ #define VMA_STATIC_VULKAN_FUNCTIONS 0 #define VMA_DYNAMIC_VULKAN_FUNCTIONS 1 +#ifdef _MSC_VER +#pragma warning( push ) +#pragma warning( disable : 4189 ) +#endif #include "vk_mem_alloc.h" + +#ifdef _MSC_VER +#pragma warning( pop ) +#endif From 56f72d37d0818de51c51dc3b284bb130718cde99 Mon Sep 17 00:00:00 2001 From: lizzie Date: Thu, 2 Oct 2025 18:27:58 +0000 Subject: [PATCH 4/5] [android] allow use of mouse and keyboard on motion events Signed-off-by: lizzie --- .../org/yuzu/yuzu_emu/activities/EmulationActivity.kt | 8 ++++++-- .../yuzu_emu/features/settings/ui/InputDialogFragment.kt | 8 ++++++-- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/src/android/app/src/main/java/org/yuzu/yuzu_emu/activities/EmulationActivity.kt b/src/android/app/src/main/java/org/yuzu/yuzu_emu/activities/EmulationActivity.kt index da40453497..ba60aeace2 100644 --- a/src/android/app/src/main/java/org/yuzu/yuzu_emu/activities/EmulationActivity.kt +++ b/src/android/app/src/main/java/org/yuzu/yuzu_emu/activities/EmulationActivity.kt @@ -230,7 +230,9 @@ class EmulationActivity : AppCompatActivity(), SensorEventListener { override fun dispatchKeyEvent(event: KeyEvent): Boolean { if (event.source and InputDevice.SOURCE_JOYSTICK != InputDevice.SOURCE_JOYSTICK && - event.source and InputDevice.SOURCE_GAMEPAD != InputDevice.SOURCE_GAMEPAD + event.source and InputDevice.SOURCE_GAMEPAD != InputDevice.SOURCE_GAMEPAD && + event.source and InputDevice.SOURCE_KEYBOARD != InputDevice.SOURCE_KEYBOARD && + event.source and InputDevice.SOURCE_MOUSE != InputDevice.SOURCE_MOUSE ) { return super.dispatchKeyEvent(event) } @@ -244,7 +246,9 @@ class EmulationActivity : AppCompatActivity(), SensorEventListener { override fun dispatchGenericMotionEvent(event: MotionEvent): Boolean { if (event.source and InputDevice.SOURCE_JOYSTICK != InputDevice.SOURCE_JOYSTICK && - event.source and InputDevice.SOURCE_GAMEPAD != InputDevice.SOURCE_GAMEPAD + event.source and InputDevice.SOURCE_GAMEPAD != InputDevice.SOURCE_GAMEPAD && + event.source and InputDevice.SOURCE_KEYBOARD != InputDevice.SOURCE_KEYBOARD && + event.source and InputDevice.SOURCE_MOUSE != InputDevice.SOURCE_MOUSE ) { return super.dispatchGenericMotionEvent(event) } diff --git a/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/ui/InputDialogFragment.kt b/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/ui/InputDialogFragment.kt index 16a1d05044..bc54fddc09 100644 --- a/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/ui/InputDialogFragment.kt +++ b/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/ui/InputDialogFragment.kt @@ -149,7 +149,9 @@ class InputDialogFragment : DialogFragment() { private fun onKeyEvent(event: KeyEvent): Boolean { if (event.source and InputDevice.SOURCE_JOYSTICK != InputDevice.SOURCE_JOYSTICK && - event.source and InputDevice.SOURCE_GAMEPAD != InputDevice.SOURCE_GAMEPAD + event.source and InputDevice.SOURCE_GAMEPAD != InputDevice.SOURCE_GAMEPAD && + event.source and InputDevice.SOURCE_KEYBOARD != InputDevice.SOURCE_KEYBOARD && + event.source and InputDevice.SOURCE_MOUSE != InputDevice.SOURCE_MOUSE ) { return false } @@ -173,7 +175,9 @@ class InputDialogFragment : DialogFragment() { private fun onMotionEvent(event: MotionEvent): Boolean { if (event.source and InputDevice.SOURCE_JOYSTICK != InputDevice.SOURCE_JOYSTICK && - event.source and InputDevice.SOURCE_GAMEPAD != InputDevice.SOURCE_GAMEPAD + event.source and InputDevice.SOURCE_GAMEPAD != InputDevice.SOURCE_GAMEPAD && + event.source and InputDevice.SOURCE_KEYBOARD != InputDevice.SOURCE_KEYBOARD && + event.source and InputDevice.SOURCE_MOUSE != InputDevice.SOURCE_MOUSE ) { return false } From d1460f95497e8bf38260e542b2c67bb6b0a8b44d Mon Sep 17 00:00:00 2001 From: lizzie Date: Thu, 2 Oct 2025 21:22:19 +0000 Subject: [PATCH 5/5] fix license Signed-off-by: lizzie --- .../yuzu/yuzu_emu/features/settings/ui/InputDialogFragment.kt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/ui/InputDialogFragment.kt b/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/ui/InputDialogFragment.kt index bc54fddc09..d07a6e6aea 100644 --- a/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/ui/InputDialogFragment.kt +++ b/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/ui/InputDialogFragment.kt @@ -1,3 +1,6 @@ +// SPDX-FileCopyrightText: Copyright 2025 Eden Emulator Project +// SPDX-License-Identifier: GPL-3.0-or-later + // SPDX-FileCopyrightText: 2024 yuzu Emulator Project // SPDX-License-Identifier: GPL-2.0-or-later