SVN commit 762677 by dakon: remove KeyListView::slotReloadOrphaned() We don't need special handling for orphaned keys anymore. They should be handled by the item model like any other key. M +0 -29 keylistview.cpp M +0 -1 keylistview.h M +0 -2 keysmanager.cpp --- branches/work/kgpg2/keylistview.cpp #762676:762677 @@ -511,35 +511,6 @@ currentItem()->setOpen(keyIsOpen); } -void KeyListView::slotReloadOrphaned() -{ - QStringList issec; - - KgpgInterface *interface = new KgpgInterface(); - KgpgKeyList listkeys, seckeys; - - seckeys = interface->readSecretKeys(); - issec = seckeys; - listkeys = interface->readPublicKeys(true, issec); - for (int i = 0; i < listkeys.size(); ++i) - issec.removeAll(listkeys.at(i).fullId()); - - delete interface; - - QStringList::Iterator it; - QStringList list; - for (it = issec.begin(); it != issec.end(); ++it) - if (findItemByKeyId(*it) == NULL) - list += *it; - - if (list.size() != 0) - insertOrphans(seckeys); - - setSelected(findItemByKeyId(*it), true); - emit statusMessage(statusCountMessage(), 1); - emit statusMessage(i18nc("No operation in progress", "Ready"), 0); -} - void KeyListView::insertOrphans(const KgpgKeyList &keys) { QStringList orphanList; --- branches/work/kgpg2/keylistview.h #762676:762677 @@ -138,7 +138,6 @@ void refreshcurrentkey(const QString &id); void refreshcurrentkey(KeyListViewItem *current); - void slotReloadOrphaned(); void insertOrphans(const KgpgKeyList &keys); void refreshGroups(); --- branches/work/kgpg2/keysmanager.cpp #762676:762677 @@ -2160,7 +2160,6 @@ // import from file KgpgInterface *importKeyProcess = new KgpgInterface(); connect(importKeyProcess, SIGNAL(importKeyFinished(QStringList)), imodel, SLOT(refreshKeys(QStringList))); - connect(importKeyProcess, SIGNAL(importKeyOrphaned()), keysList2, SLOT(slotReloadOrphaned())); importKeyProcess->importKey(KUrl(impname)); } } @@ -2172,7 +2171,6 @@ changeMessage(i18n("Importing..."), 0, true); KgpgInterface *importKeyProcess = new KgpgInterface(); connect(importKeyProcess,SIGNAL(importKeyFinished(QStringList)),keysList2,SLOT(slotReloadKeys(QStringList))); - connect(importKeyProcess,SIGNAL(importKeyOrphaned()),keysList2,SLOT(slotReloadOrphaned())); importKeyProcess->importKey(keystr); } }