renamejob.h
00001 00028 #ifndef RENAMEJOB_H 00029 #define RENAMEJOB_H 00030 00031 #include "folderjob.h" 00032 00033 class FolderStorage; 00034 class KMFolderDir; 00035 class KMFolder; 00036 class KMCommand; 00037 00038 namespace KIO { 00039 class Job; 00040 } 00041 00042 namespace KMail { 00043 00049 class RenameJob : public FolderJob 00050 { 00051 Q_OBJECT 00052 public: 00059 RenameJob( FolderStorage* storage, const QString& newName, 00060 KMFolderDir* newParent = 0 ); 00061 00062 virtual ~RenameJob(); 00063 00064 virtual void execute(); 00065 00066 protected slots: 00068 void slotRenameResult( KIO::Job* job ); 00069 00071 void slotMoveMessages(); 00072 00074 void slotMoveCompleted( KMCommand *command ); 00075 00076 signals: 00078 void renameDone( QString newName, bool success ); 00079 00080 protected: 00081 FolderStorage* mStorage; 00082 KMFolderDir* mNewParent; 00083 QString mNewName; 00084 QString mNewImapPath; 00085 QString mOldName; 00086 QString mOldImapPath; 00087 KMFolder* mNewFolder; 00088 }; 00089 00090 } // namespace KMail 00091 00092 #endif /* RENAMEJOB_H */ 00093