Reformat all the things. Have fun with merge conflicts.

This commit is contained in:
Pierre Bourdon
2016-06-24 10:43:46 +02:00
parent 2115e8a4a6
commit 3570c7f03a
1116 changed files with 187405 additions and 180344 deletions

View File

@ -13,81 +13,79 @@ namespace ciface
{
namespace OSX
{
class Joystick : public ForceFeedback::ForceFeedbackDevice
{
private:
class Button : public Input
{
public:
Button(IOHIDElementRef element, IOHIDDeviceRef device)
: m_element(element), m_device(device) {}
std::string GetName() const override;
ControlState GetState() const override;
private:
const IOHIDElementRef m_element;
const IOHIDDeviceRef m_device;
};
class Button : public Input
{
public:
Button(IOHIDElementRef element, IOHIDDeviceRef device) : m_element(element), m_device(device) {}
std::string GetName() const override;
ControlState GetState() const override;
class Axis : public Input
{
public:
enum direction
{
positive = 0,
negative
};
private:
const IOHIDElementRef m_element;
const IOHIDDeviceRef m_device;
};
Axis(IOHIDElementRef element, IOHIDDeviceRef device, direction dir);
std::string GetName() const override;
ControlState GetState() const override;
class Axis : public Input
{
public:
enum direction
{
positive = 0,
negative
};
private:
const IOHIDElementRef m_element;
const IOHIDDeviceRef m_device;
std::string m_name;
const direction m_direction;
float m_neutral;
float m_scale;
};
Axis(IOHIDElementRef element, IOHIDDeviceRef device, direction dir);
std::string GetName() const override;
ControlState GetState() const override;
class Hat : public Input
{
public:
enum direction
{
up = 0,
right,
down,
left
};
private:
const IOHIDElementRef m_element;
const IOHIDDeviceRef m_device;
std::string m_name;
const direction m_direction;
float m_neutral;
float m_scale;
};
Hat(IOHIDElementRef element, IOHIDDeviceRef device, direction dir);
std::string GetName() const override;
ControlState GetState() const override;
class Hat : public Input
{
public:
enum direction
{
up = 0,
right,
down,
left
};
private:
const IOHIDElementRef m_element;
const IOHIDDeviceRef m_device;
const char* m_name;
const direction m_direction;
};
Hat(IOHIDElementRef element, IOHIDDeviceRef device, direction dir);
std::string GetName() const override;
ControlState GetState() const override;
private:
const IOHIDElementRef m_element;
const IOHIDDeviceRef m_device;
const char* m_name;
const direction m_direction;
};
public:
Joystick(IOHIDDeviceRef device, std::string name, int index);
~Joystick();
Joystick(IOHIDDeviceRef device, std::string name, int index);
~Joystick();
std::string GetName() const override;
std::string GetSource() const override;
int GetId() const override;
std::string GetName() const override;
std::string GetSource() const override;
int GetId() const override;
private:
const IOHIDDeviceRef m_device;
const std::string m_device_name;
const int m_index;
const IOHIDDeviceRef m_device;
const std::string m_device_name;
const int m_index;
ForceFeedback::FFDeviceAdapterReference m_ff_device;
ForceFeedback::FFDeviceAdapterReference m_ff_device;
};
}
}