Fix setting libretro device types with a device subclass#155
Open
garbear wants to merge 2 commits intokodi-game:Piersfrom
Open
Fix setting libretro device types with a device subclass#155garbear wants to merge 2 commits intokodi-game:Piersfrom
garbear wants to merge 2 commits intokodi-game:Piersfrom
Conversation
This was referenced Mar 17, 2026
There was a problem hiding this comment.
Pull request overview
Fixes libretro device subclass handling when connecting controllers, and aligns keyboard/mouse port identifiers with the Kodi Game API while reducing noisy error logs for keyboard/mouse “ports”.
Changes:
- Fix incorrect parameter passed to
CLibretroDevice::SetSubclass()when a subclass override is present. - Switch keyboard/mouse port type matching to use Game API constants (
KEYBOARD_PORT_ID,MOUSE_PORT_ID) and remove local duplicates. - Suppress “invalid port address” error logging when
ConnectController()is invoked for keyboard/mouse addresses.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
src/input/InputTranslator.cpp |
Uses Game API keyboard/mouse port ID constants when translating port types. |
src/input/InputManager.h |
Adds helpers to identify keyboard/mouse port addresses. |
src/input/InputManager.cpp |
Fixes subclass override assignment and implements keyboard/mouse address helpers. |
src/input/InputDefinitions.h |
Removes local keyboard/mouse port string macros and relies on Game API definitions. |
src/client.cpp |
Avoids logging invalid-port errors for keyboard/mouse port addresses. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
7 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Was due to a c/p error.
Also improves error logging for keyboard/mouse ports.
Related PRs