void InputControlSystem::addMouseButtonBinding(Control* control, unsigned int button, Control::ControlChangingDirection direction) { ICS_LOG("\tAdding MouseButtonBinder [button=" + ToString<int>(button) + ", direction=" + ToString<int>(direction) + "]"); ControlButtonBinderItem controlMouseButtonBinderItem; controlMouseButtonBinderItem.direction = direction; controlMouseButtonBinderItem.control = control; mControlsMouseButtonBinderMap[ button ] = controlMouseButtonBinderItem; }
void InputControlSystem::addKeyBinding(Control* control, SDL_Keycode key, Control::ControlChangingDirection direction) { ICS_LOG("\tAdding KeyBinder [key=" + keyCodeToString(key) + ", direction=" + ToString<int>(direction) + "]"); ControlKeyBinderItem controlKeyBinderItem; controlKeyBinderItem.control = control; controlKeyBinderItem.direction = direction; mControlsKeyBinderMap[ key ] = controlKeyBinderItem; }
/*protected*/ void InputControlSystem::addMouseAxisBinding_(Control* control, int axis, Control::ControlChangingDirection direction) { ICS_LOG("\tAdding AxisBinder [axis=" + ToString<int>(axis) + ", direction=" + ToString<int>(direction) + "]"); ControlAxisBinderItem controlAxisBinderItem; controlAxisBinderItem.control = control; controlAxisBinderItem.direction = direction; mControlsMouseAxisBinderMap[ axis ] = controlAxisBinderItem; }