mirror of
https://github.com/PrismLauncher/PrismLauncher.git
synced 2026-07-05 21:06:58 +03:00
refactor!!!: migrate from shared pointers
Signed-off-by: Octol1ttle <l1ttleofficial@outlook.com>
(cherry picked from commit 549405ab2f)
This commit is contained in:
parent
7755e0def9
commit
e89ce1124a
199 changed files with 742 additions and 710 deletions
|
|
@ -40,7 +40,7 @@ IconPickerDialog::IconPickerDialog(QWidget* parent) : QDialog(parent), ui(new Ui
|
|||
ui->verticalLayout->insertWidget(0, searchBar);
|
||||
|
||||
proxyModel = new QSortFilterProxyModel(this);
|
||||
proxyModel->setSourceModel(APPLICATION->icons().get());
|
||||
proxyModel->setSourceModel(APPLICATION->icons());
|
||||
proxyModel->setFilterCaseSensitivity(Qt::CaseInsensitive);
|
||||
ui->iconView->setModel(proxyModel);
|
||||
|
||||
|
|
@ -88,7 +88,7 @@ IconPickerDialog::IconPickerDialog(QWidget* parent) : QDialog(parent), ui(new Ui
|
|||
connect(buttonFolder, &QPushButton::clicked, this, &IconPickerDialog::openFolder);
|
||||
connect(searchBar, &QLineEdit::textChanged, this, &IconPickerDialog::filterIcons);
|
||||
// Prevent incorrect indices from e.g. filesystem changes
|
||||
connect(APPLICATION->icons().get(), &IconList::iconUpdated, this, [this]() { proxyModel->invalidate(); });
|
||||
connect(APPLICATION->icons(), &IconList::iconUpdated, this, [this]() { proxyModel->invalidate(); });
|
||||
}
|
||||
|
||||
bool IconPickerDialog::eventFilter(QObject* obj, QEvent* evt)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue