Commit fb665cfc authored by Alain Laporte's avatar Alain Laporte
Browse files

Rename variable it to idx

* because it's an index not an iterator
* and it will shadows other variable in the method
parent aba9082f
Pipeline #232700 canceled with stage
in 23 seconds
......@@ -1365,14 +1365,14 @@ QString KateViewManager::saveSplitterConfig(KateSplitter *s, KConfigBase *config
// special case: root splitter might have only one child (just for info)
QStringList childList;
const auto sizes = s->sizes();
for (int it = 0; it < s->count(); ++it) {
for (int idx = 0; idx < s->count(); ++idx) {
// skip empty sized invisible ones, if not last one, we need one thing at least
if ((sizes[it] == 0) && ((it + 1 < s->count()) || !childList.empty())) {
if ((sizes[idx] == 0) && ((idx + 1 < s->count()) || !childList.empty())) {
continue;
}
// For KateViewSpaces, ask them to save the file list.
auto obj = s->widget(it);
auto obj = s->widget(idx);
if (auto kvs = qobject_cast<KateViewSpace *>(obj)) {
auto it = std::find(m_viewSpaceList.begin(), m_viewSpaceList.end(), kvs);
int idx = (int)std::distance(m_viewSpaceList.begin(), it);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment