@@ -142,18 +142,6 @@ struct HotkeyInfo
142142 const char * display_name;
143143 void (*handler)(s32 pressed);
144144};
145- #define DECLARE_HOTKEY_LIST (name ) extern const HotkeyInfo name[]
146- #define BEGIN_HOTKEY_LIST (name ) const HotkeyInfo name[] = {
147- #define DEFINE_HOTKEY (name, category, display_name, handler ) {(name), (category), (display_name), (handler)},
148- #define END_HOTKEY_LIST () \
149- { \
150- nullptr , nullptr , nullptr , nullptr \
151- } \
152- } \
153- ;
154-
155- DECLARE_HOTKEY_LIST (g_common_hotkeys);
156- DECLARE_HOTKEY_LIST (g_host_hotkeys);
157145
158146// / Generic input bindings. These roughly match a DualShock 4 or XBox One controller.
159147// / They are used for automatic binding to PS2 controller types, and for big picture mode navigation.
@@ -269,9 +257,6 @@ SmallString ConvertInputBindingKeysToString(InputBindingInfo::Type binding_type,
269257using BindingIconMappingFunction = std::string_view (*)(std::string_view);
270258bool PrettifyInputBinding (SmallStringBase& binding, BindingIconMappingFunction mapper = nullptr );
271259
272- // / Returns a list of all hotkeys.
273- std::vector<const HotkeyInfo*> GetHotkeyList ();
274-
275260// / Enumerates available devices. Returns a pair of the prefix (e.g. SDL-0) and the device name.
276261using DeviceList = std::vector<std::tuple<InputBindingKey, std::string, std::string>>;
277262DeviceList EnumerateDevices ();
@@ -414,9 +399,18 @@ void OnInputDeviceDisconnected(InputBindingKey key, std::string_view identifier)
414399
415400// / Creates a force feedback device interface for the specified source and device.
416401std::unique_ptr<ForceFeedbackDevice> CreateForceFeedbackDevice (const std::string_view device, Error* error = nullptr );
402+
417403} // namespace InputManager
418404
405+ namespace Core {
406+
407+ // / Returns a list of all hotkeys.
408+ std::span<const HotkeyInfo> GetHotkeyList ();
409+
410+ } // namespace Core
411+
419412namespace Host {
413+
420414// / Adds any fixed bindings from the host.
421415void AddFixedInputBindings (const SettingsInterface& si);
422416
@@ -428,4 +422,5 @@ void OnInputDeviceDisconnected(InputBindingKey key, std::string_view identifier)
428422
429423// / Enables "relative" mouse mode, locking the cursor position and returning relative coordinates.
430424void SetMouseMode (bool relative, bool hide_cursor);
425+
431426} // namespace Host
0 commit comments