Replace Qsort with std::sort
Change-Id: Ia3741e7b3542524370ac69f731db072d19a44616 Reviewed-on: https://code.wireshark.org/review/32044 Petri-Dish: Anders Broman <a.broman58@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Peter Wu <peter@lekensteyn.nl>
This commit is contained in:
parent
e6904308d3
commit
97d34eb1bd
|
@ -189,7 +189,7 @@ void ColoringRulesDialog::updateHint()
|
|||
QList<QModelIndex> keys = errors_.keys();
|
||||
|
||||
//list is not guaranteed to be sorted, so force it
|
||||
qSort(keys.begin(), keys.end());
|
||||
std::sort(keys.begin(), keys.end());
|
||||
const QModelIndex& error_key = keys[0];
|
||||
error_text = QString("%1: %2")
|
||||
.arg(colorRuleModel_.data(colorRuleModel_.index(error_key.row(), ColoringRulesModel::colName), Qt::DisplayRole).toString())
|
||||
|
@ -323,7 +323,7 @@ void ColoringRulesDialog::on_deleteToolButton_clicked()
|
|||
int num_selected = selectedList.count()/colorRuleModel_.columnCount();
|
||||
if (num_selected > 0) {
|
||||
//list is not guaranteed to be sorted, so force it
|
||||
qSort(selectedList.begin(), selectedList.end());
|
||||
std::sort(selectedList.begin(), selectedList.end());
|
||||
|
||||
//walk the list from the back because deleting a value in
|
||||
//the middle will leave the selectedList out of sync and
|
||||
|
|
|
@ -160,7 +160,7 @@ QWidget* DecodeAsDelegate::createEditor(QWidget *parentWidget, const QStyleOptio
|
|||
|
||||
//put the rest of the protocols in the combo box
|
||||
QList<QString> da_list = da_set.toList();
|
||||
qSort(da_list.begin(), da_list.end());
|
||||
std::sort(da_list.begin(), da_list.end());
|
||||
|
||||
foreach (table_ui_name, da_list) {
|
||||
editor->addItem(table_ui_name, table_ui_name);
|
||||
|
|
Loading…
Reference in New Issue