From 9e08044e7c503cd8f79f4fb86fa2751652a2637b Mon Sep 17 00:00:00 2001 From: nils Date: Thu, 8 Sep 2011 17:16:07 +0000 Subject: only use private keys to sign and print adequate message, if no private key is checked. removed hideImportAction and added parameter to showImportAction. git-svn-id: http://cpunk.de/svn/src/gpg4usb/trunk@527 34ebc366-c3a9-4b3c-9f84-69acf7962910 --- gpgwin.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'gpgwin.cpp') diff --git a/gpgwin.cpp b/gpgwin.cpp index 2213ca8..c031d37 100644 --- a/gpgwin.cpp +++ b/gpgwin.cpp @@ -601,11 +601,13 @@ void GpgWin::importKeyFromClipboard() QClipboard *cb = QApplication::clipboard(); mCtx->importKey(cb->text(QClipboard::Clipboard).toAscii()); } + void GpgWin::importKeyFromKeyServer() { importDialog = new KeyServerImportDialog(mCtx, this); importDialog->show(); } + void GpgWin::importKeyFromFile() { QFile file; @@ -651,7 +653,7 @@ void GpgWin::encrypt() void GpgWin::sign() { - QStringList *uidList = mKeyList->getChecked(); + QStringList *uidList = mKeyList->getPrivateChecked(); QByteArray *tmp = new QByteArray(); // TODO: toUtf8() here? @@ -793,9 +795,9 @@ void GpgWin::verify() // If an unknown key is found, enable the importfromkeyserveraction if (unknownKeyFound) { - vn->showImportAction(); + vn->showImportAction(true); } else { - vn->hideImportAction(); + vn->showImportAction(false); } // Remove the last linebreak -- cgit v1.2.3