Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Dec 26, 2009, 11:18:13 AM (15 years ago)
Author:
rgrieder
Message:

Uniform code-styling per file. As if I didn't know what to do

Location:
code/trunk/src/libraries/core/input
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • code/trunk/src/libraries/core/input/InputManager.cc

    r6417 r6422  
    404404                {
    405405                    // Get smallest possible priority between 1 and maxStateStackSize_s
    406                     for(std::map<int, InputState*>::reverse_iterator rit = activeStates_.rbegin();
     406                    for (std::map<int, InputState*>::reverse_iterator rit = activeStates_.rbegin();
    407407                        rit != activeStates_.rend(); ++rit)
    408408                    {
  • code/trunk/src/libraries/core/input/KeyBinder.cc

    r6417 r6422  
    291291        std::vector<std::string>& oldKeynames = this->allCommands_[button->bindingString_];
    292292        std::vector<std::string>::iterator it = std::find(oldKeynames.begin(), oldKeynames.end(), stream.str());
    293         if(it != oldKeynames.end())
    294         {
     293        if (it != oldKeynames.end())
    295294            oldKeynames.erase(it);
    296         }
    297295
    298296        if (!command.empty())
    299297        {
    300298            std::vector<std::string>& keynames = this->allCommands_[command];
    301             if( std::find(keynames.begin(), keynames.end(), stream.str()) == keynames.end())
    302             {
     299            if (std::find(keynames.begin(), keynames.end(), stream.str()) == keynames.end())
    303300                this->allCommands_[command].push_back(stream.str());
    304             }
    305301        }
    306302     }
     
    312308    const std::string& KeyBinder::getBinding(const std::string& commandName)
    313309    {
    314         if( this->allCommands_.find(commandName) != this->allCommands_.end())
     310        if (this->allCommands_.find(commandName) != this->allCommands_.end())
    315311        {
    316312            std::vector<std::string>& keynames = this->allCommands_[commandName];
     
    331327    const std::string& KeyBinder::getBinding(const std::string& commandName, unsigned int index)
    332328    {
    333         if( this->allCommands_.find(commandName) != this->allCommands_.end())
     329        if (this->allCommands_.find(commandName) != this->allCommands_.end())
    334330        {
    335331            std::vector<std::string>& keynames = this->allCommands_[commandName];
    336             if(index < keynames.size())
    337             {
     332            if (index < keynames.size())
    338333                return keynames[index];
    339             }
    340334
    341335            return BLANKSTRING;
     
    353347    unsigned int KeyBinder::getNumberOfBindings(const std::string& commandName)
    354348    {
    355         if( this->allCommands_.find(commandName) != this->allCommands_.end())
     349        if (this->allCommands_.find(commandName) != this->allCommands_.end())
    356350        {
    357351            std::vector<std::string>& keynames = this->allCommands_[commandName];
  • code/trunk/src/libraries/core/input/Keyboard.cc

    r6417 r6422  
    3636    {
    3737        // update modifiers
    38         if(arg.key == OIS::KC_RMENU    || arg.key == OIS::KC_LMENU)
     38        if (arg.key == OIS::KC_RMENU    || arg.key == OIS::KC_LMENU)
    3939            modifiers_ |= KeyboardModifier::Alt;   // alt key
    40         if(arg.key == OIS::KC_RCONTROL || arg.key == OIS::KC_LCONTROL)
     40        if (arg.key == OIS::KC_RCONTROL || arg.key == OIS::KC_LCONTROL)
    4141            modifiers_ |= KeyboardModifier::Ctrl;  // ctrl key
    42         if(arg.key == OIS::KC_RSHIFT   || arg.key == OIS::KC_LSHIFT)
     42        if (arg.key == OIS::KC_RSHIFT   || arg.key == OIS::KC_LSHIFT)
    4343            modifiers_ |= KeyboardModifier::Shift; // shift key
    4444
     
    5656    {
    5757        // update modifiers
    58         if(arg.key == OIS::KC_RMENU    || arg.key == OIS::KC_LMENU)
     58        if (arg.key == OIS::KC_RMENU    || arg.key == OIS::KC_LMENU)
    5959            modifiers_ &= ~KeyboardModifier::Alt;   // alt key
    60         if(arg.key == OIS::KC_RCONTROL || arg.key == OIS::KC_LCONTROL)
     60        if (arg.key == OIS::KC_RCONTROL || arg.key == OIS::KC_LCONTROL)
    6161            modifiers_ &= ~KeyboardModifier::Ctrl;  // ctrl key
    62         if(arg.key == OIS::KC_RSHIFT   || arg.key == OIS::KC_LSHIFT)
     62        if (arg.key == OIS::KC_RSHIFT   || arg.key == OIS::KC_LSHIFT)
    6363            modifiers_ &= ~KeyboardModifier::Shift; // shift key
    6464
Note: See TracChangeset for help on using the changeset viewer.