kmail
kmmsgpartdlg.h00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef kmmsgpartdlg_h
00021 #define kmmsgpartdlg_h
00022
00023 #include <kdialogbase.h>
00024 #include <kio/global.h>
00025
00026 class KMMessagePart;
00027 class TQPushButton;
00028 class KComboBox;
00029 class TQComboBox;
00030 class TQCheckBox;
00031 class TQLabel;
00032 class TQLineEdit;
00033
00034 #undef None
00035
00039 class KMMsgPartDialog: public KDialogBase
00040 {
00041 Q_OBJECT
00042 TQ_OBJECT
00043
00044 public:
00045 KMMsgPartDialog( const TQString & caption=TQString(),
00046 TQWidget * parent=0, const char * name=0 );
00047 virtual ~KMMsgPartDialog();
00048
00050 TQString mimeType() const;
00052 void setMimeType( const TQString & type, const TQString & subtype );
00058 void setMimeType( const TQString & mimeType );
00061 void setMimeTypeList( const TQStringList & mimeTypes );
00062
00066 void setSize( KIO::filesize_t size, bool estimated=false );
00067
00071 TQString fileName() const;
00075 void setFileName( const TQString & fileName );
00076
00079 TQString description() const;
00082 void setDescription( const TQString & description );
00083
00085 enum Encoding {
00086 None = 0x00,
00087 SevenBit = 0x01,
00088 EightBit = 0x02,
00089 QuotedPrintable = 0x04,
00090 Base64 = 0x08
00091 };
00092
00094 Encoding encoding() const;
00096 void setEncoding( Encoding encoding );
00099 void setShownEncodings( int encodings );
00100
00103 bool isInline() const;
00106 void setInline( bool inlined );
00107
00109 bool isEncrypted() const;
00111 void setEncrypted( bool encrypted );
00113 void setCanEncrypt( bool enable );
00114
00116 bool isSigned() const;
00118 void setSigned( bool sign );
00120 void setCanSign( bool enable );
00121
00122 protected slots:
00123 void slotMimeTypeChanged( const TQString & mimeType );
00124
00125 protected:
00126 KComboBox *mMimeType;
00127 TQLabel *mIcon;
00128 TQLabel *mSize;
00129 TQLineEdit *mFileName;
00130 TQLineEdit *mDescription;
00131 TQComboBox *mEncoding;
00132 TQCheckBox *mInline;
00133 TQCheckBox *mEncrypted;
00134 TQCheckBox *mSigned;
00135 TQStringList mI18nizedEncodings;
00136 };
00137
00141 class KMMsgPartDialogCompat : public KMMsgPartDialog {
00142 Q_OBJECT
00143 TQ_OBJECT
00144 public:
00145 KMMsgPartDialogCompat( TQWidget * parent=0, const char * caption=0, bool=FALSE );
00146 virtual ~KMMsgPartDialogCompat();
00147
00149 void setMsgPart(KMMessagePart* msgPart);
00150
00152 KMMessagePart* msgPart(void) const { return mMsgPart; }
00153
00154 protected slots:
00155 void slotOk();
00156
00157 protected:
00160 void applyChanges(void);
00161
00162 KMMessagePart *mMsgPart;
00163 };
00164
00165 #endif
|