Browse Source

Remove the `auto` specifier from `i` variable in `for` loops

`auto` is available in C++11+ compilers and this is not the case of a basic RPi setup.
master
Krisjanis Rijnieks 10 years ago
parent
commit
0d0bae9f43
  1. 2
      src/Surfaces/SurfaceManager.cpp
  2. 4
      src/Surfaces/SurfaceManagerGui.cpp

2
src/Surfaces/SurfaceManager.cpp

@ -382,7 +382,7 @@ void SurfaceManager::loadXmlSettings(string fileName) {
}
BaseSurface * SurfaceManager::selectSurface(BaseSurface * surface){
for (auto i = 0; i < surfaces.size(); i++) {
for (int i = 0; i < surfaces.size(); i++) {
if (surfaces[i] == surface){
selectedSurface = surface;
ofSendMessage("surfaceSelected");

4
src/Surfaces/SurfaceManagerGui.cpp

@ -97,7 +97,7 @@ namespace ofx {
bSurfaceSelected = true;
int jointIndex = -1;
for (auto i = 0; i < textureEditor.getJoints().size(); i++) {
for (int i = 0; i < textureEditor.getJoints().size(); i++) {
if (textureEditor.getJoints()[i] == hitJoint) {
jointIndex = i;
break;
@ -138,7 +138,7 @@ namespace ofx {
hitJoint->select();
hitJoint->startDrag();
int jointVertIndex = 0;
for (auto i = 0; i < projectionEditor.getJoints()->size(); i++) {
for (int i = 0; i < projectionEditor.getJoints()->size(); i++) {
if ((*projectionEditor.getJoints())[i] == hitJoint) {
jointVertIndex = i;
break;

Loading…
Cancel
Save