Host: Add GetTopLevelWindowInfo()

And use it for screensaver inhibiting on Linux.
This commit is contained in:
Connor McLaughlin
2022-11-18 18:14:39 +10:00
parent 3d4d2336a9
commit 8d7aea5e19
25 changed files with 133 additions and 126 deletions

View File

@ -9,6 +9,7 @@
#include "common/settings_interface.h"
#include "common/types.h"
#include "common/window_info.h"
/// Class, or source of an input event.
enum class InputSourceType : u32
@ -308,6 +309,9 @@ std::vector<std::string> GetInputProfileNames();
} // namespace InputManager
namespace Host {
/// Return the current window handle. Needed for DInput.
std::optional<WindowInfo> GetTopLevelWindowInfo();
/// Called when a new input device is connected.
void OnInputDeviceConnected(const std::string_view& identifier, const std::string_view& device_name);