@@ -15,25 +15,7 @@ namespace xe {
|
||||
namespace hid {
|
||||
namespace xinput {
|
||||
|
||||
void InitializeIfNeeded();
|
||||
void CleanupOnShutdown();
|
||||
|
||||
void InitializeIfNeeded() {
|
||||
static bool has_initialized = false;
|
||||
if (has_initialized) {
|
||||
return;
|
||||
}
|
||||
has_initialized = true;
|
||||
|
||||
//
|
||||
|
||||
atexit(CleanupOnShutdown);
|
||||
}
|
||||
|
||||
void CleanupOnShutdown() {}
|
||||
|
||||
std::unique_ptr<InputDriver> Create(InputSystem* input_system) {
|
||||
InitializeIfNeeded();
|
||||
return std::make_unique<XInputInputDriver>(input_system);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user