Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Apr 16, 2010, 1:42:28 PM (15 years ago)
Author:
rgrieder
Message:

Branch now compiling with GCC as well: Added an removed a few typenames and other stuff

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/gamestates2/src/libraries/core/input/InputHandler.h

    r6662 r6745  
    118118        template<class T> void buttonEvent(unsigned int device, T button, ButtonEvent::THold)
    119119            { this->buttonHeld(button); }
    120         template<> void buttonEvent<JoyStickButtonCode::ByEnum>(unsigned int device, JoyStickButtonCode::ByEnum button, ButtonEvent::TPress)
    121             { this->buttonPressed(device - InputDeviceEnumerator::FirstJoyStick, button); }
    122         template<> void buttonEvent<JoyStickButtonCode::ByEnum>(unsigned int device, JoyStickButtonCode::ByEnum button, ButtonEvent::TRelease)
    123             { this->buttonReleased(device - InputDeviceEnumerator::FirstJoyStick, button); }
    124         template<> void buttonEvent<JoyStickButtonCode::ByEnum>(unsigned int device, JoyStickButtonCode::ByEnum button, ButtonEvent::THold)
    125             { this->buttonHeld(device - InputDeviceEnumerator::FirstJoyStick, button); }
    126120
    127121        virtual void buttonPressed (const KeyEvent& evt) { }
     
    149143        static InputHandler EMPTY;
    150144    };
     145
     146    template<> inline void InputHandler::buttonEvent<JoyStickButtonCode::ByEnum>(unsigned int device, JoyStickButtonCode::ByEnum button, ButtonEvent::TPress)
     147        { this->buttonPressed(device - InputDeviceEnumerator::FirstJoyStick, button); }
     148    template<> inline void InputHandler::buttonEvent<JoyStickButtonCode::ByEnum>(unsigned int device, JoyStickButtonCode::ByEnum button, ButtonEvent::TRelease)
     149        { this->buttonReleased(device - InputDeviceEnumerator::FirstJoyStick, button); }
     150    template<> inline void InputHandler::buttonEvent<JoyStickButtonCode::ByEnum>(unsigned int device, JoyStickButtonCode::ByEnum button, ButtonEvent::THold)
     151        { this->buttonHeld(device - InputDeviceEnumerator::FirstJoyStick, button); }
    151152}
    152153
Note: See TracChangeset for help on using the changeset viewer.