kshowmail.tdevelop: Daten/Documents/programmieren/kshowmail/kshowmail/kshowmail/showrecord.h Source File

- Main Page
- Namespaces
- Classes
- Files
- Directories

- File List
- File Members

# showrecord.h

Go to the documentation of this file.

    00001 /***************************************************************************
    00002                           showrecord.h  -  description
    00003                              -------------------
    00004     begin                : Mon Dec 3 2001
    00005     copyright            : (C) 2001 by Eggert Ehmke
    00006     email                : eggert.ehmke@berlin.de
    00007  ***************************************************************************/
    00008
    00009 /***************************************************************************
    00010  *                                                                         *
    00011  *   This program is free software; you can redistribute it and/or modify  *
    00012  *   it under the terms of the GNU General Public License as published by  *
    00013  *   the Free Software Foundation; either version 2 of the License, or     *
    00014  *   (at your option) any later version.                                   *
    00015  *                                                                         *
    00016  ***************************************************************************/
    00017
    00018 #ifndef SHOWRECORD_H
    00019 #define SHOWRECORD_H
    00020
    00021 //C++ header
    00022 #include <iostream>
    00023
    00024 //TQt headers
    00025 #include <tqdom.h>
    00026 #include <tqptrlist.h>
    00027
    00028 //KDE headers
    00029 #include <tdestandarddirs.h>
    00030 #include <kdebug.h>
    00031
    00032 //KShowmail headers
    00033 #include "kshowmailview.h"
    00034 #include "showrecordelem.h"
    00035 #include "types.h"
    00036 #include "headerfilter.h"
    00037 #include "filterlog.h"
    00038
    00039 using namespace Types;
    00040 using namespace std;
    00041
    00042 //forward class declarations
    00043 class ShowRecordElem;
    00044 class KshowmailView;
    00045
    00056 class ShowRecord: public TQPtrList<ShowRecordElem>
    00057 {
    00058
    00059   public:
    00060
    00065     static const int continueShowHeaders;
    00066
    00071     static const int cancelShowHeaders;
    00072
    00076     ShowRecord();
    00077
    00082     ~ShowRecord();
    00083
    00090     void saveOptions( TQDomDocument& doc, TQDomElement& parent );
    00091
    00098     void readStoredMails( TQDomElement& parent );
    00099
    00108     void applyHeaderFilter( HeaderFilter* filter, TQString account, MailNumberList_Type& deleteList, MailToDownloadMap_Type& downloadList, FilterLog* log = NULL );
    00109
    00110
    00117     bool hasSelectedMails();
    00118
    00123     Types::MailNumberList_Type getSelectedMails();
    00124
    00129     void removeMail( int number );
    00130
    00135     TQStringList getSelectedSubjects() const;
    00136
    00142     TQString getSenderOf( int number ) const;
    00143
    00149     TQString getDateOf( int number ) const;
    00150
    00156     TQString getSizeOf( int number ) const;
    00157
    00163     TQString getSubjectOf( int number ) const;
    00164
    00177     TQString decodeMailBody( TQByteArray body, int number, bool preferHTML ) const;
    00178
    00185     bool hasMail( TQString uid );
    00186
    00193     bool isNew( TQString uid ) const;
    00194
    00201     void appendNewMail( int number, TQString uid, bool isNew );
    00202
    00207     void printMailList();
    00208
    00214     void setSize( int number, long size );
    00215
    00220     Types::MailNumberList_Type getNewMails();
    00221
    00227     void setHeader( int number, TQString header );
    00228
    00233     TQStringList getUIDsOfOldMails();
    00234
    00240     TQString getHeaderOf( TQString uid );
    00241
    00247     void setHeader( TQString uid, TQString header );
    00248
    00253     int getNumberNewMails();
    00254
    00259     int getNumberMails();
    00260
    00265     long getTotalSize();
    00266
    00273     void fillMailListView( KshowmailView* view, TQString& account );
    00274
    00281     int showSelectedHeaders( TQString& account );
    00282
    00290     void writeToMoveLog( FilterLog* log, int number, TQString account, TQString mailbox );
    00291
    00298     void writeToDeleteLog( FilterLog* log, int number, TQString account );
    00299
    00304     void setMarkAtNextViewRefresh( int number );
    00305
    00306
    00307 };
    00308
    00309 #endif