Deprecated qSort => std::sort

This change gets rid of some GCC's -Wdeprecated-declarations warnings.
This commit is contained in:
Igor Kushnir
2021-02-05 17:38:08 +02:00
committed by Felix Kauselmann
parent 70287994dd
commit 3c9ed6ef8f
6 changed files with 18 additions and 14 deletions

View File

@ -17,6 +17,7 @@
#include <QSettings>
#include <QHeaderView>
#include <algorithm>
#include <iterator>
#include <typeinfo>
#include <thread>
@ -2494,7 +2495,7 @@ QModelIndexList LibraryWindow::getSelectedComics()
//avoid selection.count()==0 forcing selection in comicsView
QModelIndexList selection = comicsViewsManager->comicsView->selectionModel()->selectedRows();
QLOG_TRACE() << "selection count " << selection.length();
qSort(selection.begin(), selection.end(), lessThanModelIndexRow);
std::sort(selection.begin(), selection.end(), lessThanModelIndexRow);
if (selection.count() == 0) {
comicsViewsManager->comicsView->selectIndex(0);