[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    KDE/kdenetwork/kopete/plugins/cryptography
From:       Charles Connell <charles () connells ! org>
Date:       2007-07-19 0:25:35
Message-ID: 1184804735.420540.10363.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 689731 by cconnell:

If signature cannot be verified, show a red pen icon


 M  +2 -0      CMakeLists.txt  
 M  +5 -0      cryptographyplugin.cpp  
 M  +3 -1      gpginterface.cpp  
 M  +1 -1      gpginterface.h  
 A             icons (directory)  
 A             icons/CMakeLists.txt  
 AM            icons/bad-signature.png  
 AM            icons/ox16-action-bad_signature.png  


--- trunk/KDE/kdenetwork/kopete/plugins/cryptography/CMakeLists.txt #689730:689731
@@ -1,3 +1,5 @@
+add_subdirectory ( icons )
+
 include_directories( 
 ${KOPETE_INCLUDES}
 )
--- trunk/KDE/kdenetwork/kopete/plugins/cryptography/cryptographyplugin.cpp \
#689730:689731 @@ -149,10 +149,15 @@
 		if (opState & GpgInterface::GoodSig)
 			body.prepend ( "<img src=\"" + KIconLoader::global()->iconPath ( "signature", \
K3Icon::Small ) + "\">&nbsp;&nbsp;" );  
+		if ( (opState & GpgInterface::ErrorSig) || (opState & GpgInterface::BadSig) )
+			body.prepend ( "<img src=\"" + KIconLoader::global()->iconPath ( "bad_signature", \
K3Icon::Small ) + "\">&nbsp;&nbsp;" ); +		
 		if (opState & GpgInterface::Decrypted)
 			body.prepend ( "<img src=\"" + KIconLoader::global()->iconPath ( "encrypted", \
K3Icon::Small ) + "\">&nbsp;&nbsp;" );  
 		msg.setHtmlBody ( body );
+		kDebug ( 14303) << k_funcinfo << "body is " << body << endl;
+		kDebug ( 14303) << k_funcinfo << "opState is " << opState << endl;
 		msg.addClass ( "cryptography:encrypted" );
 	}
 
--- trunk/KDE/kdenetwork/kopete/plugins/cryptography/gpginterface.cpp #689730:689731
@@ -145,7 +145,9 @@
 
 		if ( status.contains ( "DECRYPTION_OKAY" ) )
 			opState = ( opState | Decrypted );
-
+			
+		kDebug (14303) << k_funcinfo << "status file is: " << status << endl;
+		
 		status.clear();
 		password.clear();
 		gpgcmd.clear();
--- trunk/KDE/kdenetwork/kopete/plugins/cryptography/gpginterface.h #689730:689731
@@ -34,7 +34,7 @@
 		/**
 		* The state of an operation.
 		*/
-		enum OpState { GoodSig = 0x1, BadSig = 0x2, ErrorSig = 0x4, NoSig = 0x8, Decrypted \
= 0x16 }; +		enum OpState { GoodSig = 0x1, BadSig = 0x2, ErrorSig = 0x4, NoSig = 0x8, \
Decrypted = 0x128 };  
 		/**Encrypt text function
 		* @param text QString text to be encrypted.
** trunk/KDE/kdenetwork/kopete/plugins/cryptography/icons/bad-signature.png #property \
svn:mime-type  + application/octet-stream
** trunk/KDE/kdenetwork/kopete/plugins/cryptography/icons/ox16-action-bad_signature.png \
#property svn:mime-type  + application/octet-stream


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic