|
|
|
@ -22,6 +22,7 @@ |
|
|
|
#include <QGuiApplication> |
|
|
|
#include <QGuiApplication> |
|
|
|
#include <QTimer> |
|
|
|
#include <QTimer> |
|
|
|
#include <QUrl> |
|
|
|
#include <QUrl> |
|
|
|
|
|
|
|
#include <QVector> |
|
|
|
|
|
|
|
|
|
|
|
#include <numeric> |
|
|
|
#include <numeric> |
|
|
|
|
|
|
|
|
|
|
|
@ -218,13 +219,9 @@ void TasksModel::Private::initModels() |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
const int delta = (end - start) + 1; |
|
|
|
const int delta = (end - start) + 1; |
|
|
|
QMutableListIterator<int> it(sortedPreFilterRows); |
|
|
|
for (auto it = sortedPreFilterRows.begin(); it != sortedPreFilterRows.end(); ++it) { |
|
|
|
|
|
|
|
if ((*it) >= start) { |
|
|
|
while (it.hasNext()) { |
|
|
|
*it += delta; |
|
|
|
it.next(); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (it.value() >= start) { |
|
|
|
|
|
|
|
it.setValue(it.value() + delta); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@ -271,13 +268,9 @@ void TasksModel::Private::initModels() |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
const int delta = (last - first) + 1; |
|
|
|
const int delta = (last - first) + 1; |
|
|
|
QMutableListIterator<int> it(sortedPreFilterRows); |
|
|
|
for (auto it = sortedPreFilterRows.begin(); it != sortedPreFilterRows.end(); ++it) { |
|
|
|
|
|
|
|
if ((*it) > last) { |
|
|
|
while (it.hasNext()) { |
|
|
|
*it -= delta; |
|
|
|
it.next(); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (it.value() > last) { |
|
|
|
|
|
|
|
it.setValue(it.value() - delta); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
|