aboutsummaryrefslogtreecommitdiffstats
path: root/src/ui/dialog/ADSKsPicker.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/ui/dialog/ADSKsPicker.cpp')
-rw-r--r--src/ui/dialog/ADSKsPicker.cpp11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/ui/dialog/ADSKsPicker.cpp b/src/ui/dialog/ADSKsPicker.cpp
index a3589a91..f10a936a 100644
--- a/src/ui/dialog/ADSKsPicker.cpp
+++ b/src/ui/dialog/ADSKsPicker.cpp
@@ -34,15 +34,14 @@
namespace GpgFrontend::UI {
ADSKsPicker::ADSKsPicker(int channel,
- const GpgKeyTreeModel::Detector& enable_detector,
+ const GpgKeyTreeProxyModel::KeyFilter& filter,
QWidget* parent)
: GeneralDialog(typeid(ADSKsPicker).name(), parent),
tree_view_(new KeyTreeView(
channel, [](GpgAbstractKey* k) { return k->IsSubKey(); },
- [=](GpgAbstractKey* k) {
- return (!k->IsSubKey() || (k->IsSubKey() && !k->IsPrimaryKey() &&
- k->IsHasEncrCap())) &&
- enable_detector(k);
+ [=](const GpgAbstractKey* k) {
+ return (!k->IsSubKey() || (k->IsSubKey() && k->IsHasEncrCap())) &&
+ filter(k);
})) {
auto* confirm_button = new QPushButton(tr("Confirm"));
auto* cancel_button = new QPushButton(tr("Cancel"));
@@ -77,7 +76,7 @@ ADSKsPicker::ADSKsPicker(int channel,
this->setWindowTitle(tr("ADSKs Picker"));
movePosition2CenterOfParent();
-
+
this->show();
this->raise();
this->activateWindow();