forked from qt-creator/qt-creator
Reinvent deprecated qSort as Utils::sort
Change-Id: I4f6011cc2b6127037249aabc2426a88ad7108ebf Reviewed-by: Orgad Shaneh <orgads@gmail.com> Reviewed-by: Daniel Teske <daniel.teske@digia.com> Reviewed-by: hjk <hjk121@nokiamail.com>
This commit is contained in:
@@ -36,6 +36,7 @@
|
||||
#include <texteditor/storagesettings.h>
|
||||
#include <texteditor/behaviorsettings.h>
|
||||
#include <texteditor/extraencodingsettings.h>
|
||||
#include <utils/algorithm.h>
|
||||
|
||||
#include <QList>
|
||||
#include <QString>
|
||||
@@ -43,7 +44,6 @@
|
||||
#include <QTextCodec>
|
||||
#include <QTextStream>
|
||||
|
||||
#include <algorithm>
|
||||
#include <functional>
|
||||
|
||||
namespace TextEditor {
|
||||
@@ -61,7 +61,7 @@ BehaviorSettingsWidget::BehaviorSettingsWidget(QWidget *parent)
|
||||
d->m_ui.setupUi(this);
|
||||
|
||||
QList<int> mibs = QTextCodec::availableMibs();
|
||||
qSort(mibs);
|
||||
Utils::sort(mibs);
|
||||
QList<int>::iterator firstNonNegative =
|
||||
std::find_if(mibs.begin(), mibs.end(), std::bind2nd(std::greater_equal<int>(), 0));
|
||||
if (firstNonNegative != mibs.end())
|
||||
|
||||
Reference in New Issue
Block a user