Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Nov 8, 2015, 3:12:17 PM (8 years ago)
Author:
landauf
Message:

use range-based-for-loop instead of BOOST_FOREACH

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/cpp11_v2/src/libraries/core/input/JoyStick.cc

    r10624 r10778  
    3131#include <climits>
    3232#include <ois/OISJoyStick.h>
    33 #include <boost/foreach.hpp>
    3433
    3534#include "util/StringUtils.h"
     
    7372        //deviceName_ += multi_cast<std::string>(oisDevice_->getNumberOfComponents(OIS::OIS_Vector3));
    7473
    75         BOOST_FOREACH(std::string& idString, deviceNames_s)
     74        for (const std::string& idString : deviceNames_s)
    7675        {
    7776            if (deviceName_ == idString)
     
    128127    {
    129128        // Set initial values
    130         BOOST_FOREACH(int& minVal, configMinValues_)
     129        for (int& minVal : configMinValues_)
    131130            minVal = INT_MAX;
    132         BOOST_FOREACH(int& minVal, configMaxValues_)
     131        for (int& minVal : configMaxValues_)
    133132            minVal = INT_MIN;
    134         BOOST_FOREACH(int& zeroVal, configZeroValues_)
     133        for (int& zeroVal : configZeroValues_)
    135134            zeroVal = 0;
    136135    }
     
    209208                fValue *= negativeCoeffs_[axis];
    210209
    211             BOOST_FOREACH(InputState* state, inputStates_)
     210            for (InputState* state : inputStates_)
    212211                state->joyStickAxisMoved(this->getDeviceID(), axis, fValue);
    213212        }
Note: See TracChangeset for help on using the changeset viewer.