aboutsummaryrefslogtreecommitdiffstats
path: root/src/ui/dialog/import_export/KeyServerImportDialog.cpp
diff options
context:
space:
mode:
authorsaturneric <[email protected]>2024-12-13 15:22:33 +0000
committersaturneric <[email protected]>2024-12-13 15:22:33 +0000
commitf7a00c58d2824f49ecaafc0152fc0b8213772e46 (patch)
treed012e5fac4ff9f48cd10381a0b79de0294d28d18 /src/ui/dialog/import_export/KeyServerImportDialog.cpp
parentdoc: update SECURITY.md (diff)
downloadGpgFrontend-f7a00c58d2824f49ecaafc0152fc0b8213772e46.tar.gz
GpgFrontend-f7a00c58d2824f49ecaafc0152fc0b8213772e46.zip
refactor: using qt containers instead of std containers
Diffstat (limited to 'src/ui/dialog/import_export/KeyServerImportDialog.cpp')
-rw-r--r--src/ui/dialog/import_export/KeyServerImportDialog.cpp15
1 files changed, 7 insertions, 8 deletions
diff --git a/src/ui/dialog/import_export/KeyServerImportDialog.cpp b/src/ui/dialog/import_export/KeyServerImportDialog.cpp
index e81cc2e8..c15df158 100644
--- a/src/ui/dialog/import_export/KeyServerImportDialog.cpp
+++ b/src/ui/dialog/import_export/KeyServerImportDialog.cpp
@@ -360,7 +360,7 @@ void KeyServerImportDialog::slot_search_finished(
}
void KeyServerImportDialog::slot_import() {
- std::vector<QString> key_ids;
+ KeyIdArgsList key_ids;
const int row_count = keys_table_->rowCount();
for (int i = 0; i < row_count; ++i) {
if (keys_table_->item(i, 2)->isSelected()) {
@@ -377,7 +377,7 @@ void KeyServerImportDialog::slot_import() {
}
}
-void KeyServerImportDialog::SlotImport(const KeyIdArgsListPtr& keys) {
+void KeyServerImportDialog::SlotImport(const KeyIdArgsList& keys) {
// keyserver host url
QString target_keyserver;
@@ -388,18 +388,17 @@ void KeyServerImportDialog::SlotImport(const KeyIdArgsListPtr& keys) {
KeyServerSO key_server(SettingsObject("key_server"));
target_keyserver = key_server.GetTargetServer();
}
- std::vector<QString> key_ids;
- for (const auto& key_id : *keys) {
+ KeyIdArgsList key_ids;
+ for (const auto& key_id : keys) {
key_ids.push_back(key_id);
}
SlotImport(key_ids, target_keyserver);
}
-void KeyServerImportDialog::SlotImport(std::vector<QString> key_ids,
+void KeyServerImportDialog::SlotImport(QStringList key_ids,
QString keyserver_url) {
- auto* task =
- new KeyServerImportTask(std::move(keyserver_url),
- current_gpg_context_channel_, std::move(key_ids));
+ auto* task = new KeyServerImportTask(keyserver_url,
+ current_gpg_context_channel_, key_ids);
connect(task, &KeyServerImportTask::SignalKeyServerImportResult, this,
&KeyServerImportDialog::slot_import_finished);