Gui: Use auto and range-based for (#7481)
* On lines where the variable type is obvious from inspection, avoid repeating the type using auto. * When possible use a ranged for loop instead of begin() and end() iterators
This commit is contained in:
@@ -63,7 +63,7 @@ PyObject* AxisOriginPy::getElementPicked(PyObject* args)
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
SoPickedPoint *pp = static_cast<SoPickedPoint*>(ptr);
|
||||
auto pp = static_cast<SoPickedPoint*>(ptr);
|
||||
std::string name;
|
||||
if (!getAxisOriginPtr()->getElementPicked(pp,name))
|
||||
Py_Return;
|
||||
@@ -85,7 +85,7 @@ PyObject* AxisOriginPy::getDetailPath(PyObject* args)
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
SoPath *pPath = static_cast<SoPath*>(ptr);
|
||||
auto pPath = static_cast<SoPath*>(ptr);
|
||||
SoDetail *det = nullptr;
|
||||
if (!getAxisOriginPtr()->getDetailPath(sub, static_cast<SoFullPath*>(pPath), det)) {
|
||||
delete det;
|
||||
|
||||
Reference in New Issue
Block a user