Changeset 3288 for code/branches/core4/src/core/input/InputState.cc
- Timestamp:
- Jul 13, 2009, 10:43:59 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/core4/src/core/input/InputState.cc
r3274 r3288 32 32 namespace orxonox 33 33 { 34 InputState::InputState( )35 : priority_(0)36 , bAlwaysGetsInput_( false)37 , bTransparent_( false)34 InputState::InputState(const std::string& name, bool bAlwaysGetsInput, bool bTransparent, InputStatePriority priority) 35 : name_(name) 36 , bAlwaysGetsInput_(bAlwaysGetsInput) 37 , bTransparent_(bTransparent) 38 38 , bExpired_(true) 39 39 , handlers_(2) … … 42 42 , leaveFunctor_(0) 43 43 { 44 if (priority >= InputStatePriority::HighPriority || priority == InputStatePriority::Empty) 45 priority_ = priority; 46 else 47 priority_ = 0; 48 49 handlers_.resize(InputDeviceEnumerator::FirstJoyStick + JoyStickQuantityListener::getJoyStickList().size(), NULL); 44 50 } 45 51 … … 52 58 } 53 59 54 void InputState::JoyStickQuantityChanged( unsigned int n)60 void InputState::JoyStickQuantityChanged(const std::vector<JoyStick*>& joyStickList) 55 61 { 56 62 unsigned int oldSize = handlers_.size(); 57 handlers_.resize(InputDeviceEnumerator::FirstJoyStick + n, NULL);63 handlers_.resize(InputDeviceEnumerator::FirstJoyStick + joyStickList.size(), NULL); 58 64 59 65 for (unsigned int i = oldSize; i < handlers_.size(); ++i)
Note: See TracChangeset
for help on using the changeset viewer.