1
mirror of https://invent.kde.org/network/falkon.git synced 2024-12-20 02:36:34 +01:00

Correct the sorting for cookies white- and black- lists

The previous solution has no effect on entries which already exist in the lists.
As a result the lists are not sorted. It is only functional when the lists were
initially empty, which is a sub-optimal case.

Test plan: open Cookies Manager, switch to Cookie Filtering tab, see the items being alphabetically sorted
This commit is contained in:
Mikalai Ahnioŭ 2020-04-17 17:26:06 +03:00
parent c725b5dd6a
commit c3d0fc0e0e

View File

@ -85,8 +85,8 @@ CookieManager::CookieManager(QWidget *parent)
ui->cookieTree->header()->setDefaultSectionSize(220);
ui->cookieTree->setFocus();
ui->whiteList->setSortingEnabled(true);
ui->blackList->setSortingEnabled(true);
ui->whiteList->sortItems(Qt::AscendingOrder);
ui->blackList->sortItems(Qt::AscendingOrder);
QShortcut* removeShortcut = new QShortcut(QKeySequence("Del"), this);
connect(removeShortcut, &QShortcut::activated, this, &CookieManager::deletePressed);