Depreciate old OSX Keyboard and Mouse

This commit is contained in:
Nick
2017-08-21 01:44:03 -04:00
parent 5aed9a67ef
commit 0df4f7db4f
5 changed files with 2 additions and 370 deletions

View File

@ -15,7 +15,6 @@
#include "InputCommon/ControllerInterface/ControllerInterface.h"
#include "InputCommon/ControllerInterface/OSX/OSX.h"
#include "InputCommon/ControllerInterface/OSX/OSXJoystick.h"
#include "InputCommon/ControllerInterface/OSX/OSXKeyboard.h"
#include "InputCommon/ControllerInterface/OSX/RunLoopStopper.h"
namespace ciface
@ -155,10 +154,6 @@ static void DeviceRemovalCallback(void* inContext, IOReturn inResult, void* inSe
if (joystick && joystick->IsSameDevice(inIOHIDDeviceRef))
return true;
const Keyboard* keyboard = dynamic_cast<const Keyboard*>(device);
if (keyboard && keyboard->IsSameDevice(inIOHIDDeviceRef))
return true;
return false;
});
g_controller_interface.InvokeHotplugCallbacks();
@ -174,16 +169,8 @@ static void DeviceMatchingCallback(void* inContext, IOReturn inResult, void* inS
// Add a device if it's of a type we want
if (IOHIDDeviceConformsTo(inIOHIDDeviceRef, kHIDPage_GenericDesktop, kHIDUsage_GD_Keyboard))
{
if (g_window)
g_controller_interface.AddDevice(
std::make_shared<Keyboard>(inIOHIDDeviceRef, name, g_window));
}
#if 0
else if (IOHIDDeviceConformsTo(inIOHIDDeviceRef, kHIDPage_GenericDesktop, kHIDUsage_GD_Mouse))
{
g_controller_interface.AddDevice(new Mouse(inIOHIDDeviceRef, name));
}
#endif
else
{
g_controller_interface.AddDevice(std::make_shared<Joystick>(inIOHIDDeviceRef, name));