00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef _HISTORYSTRINGITEM_H_
00021 #define _HISTORYSTRINGITEM_H_
00022
00023 #include <tqstring.h>
00024 #include <tqdragobject.h>
00025
00026 #include "historyitem.h"
00027
00031 class HistoryStringItem : public HistoryItem
00032 {
00033 public:
00034 HistoryStringItem( const TQString& data );
00035 virtual ~HistoryStringItem() {}
00036 virtual TQString text() const;
00037 virtual bool operator==( const HistoryItem& rhs) const {
00038 if ( const HistoryStringItem* casted_rhs = dynamic_cast<const HistoryStringItem*>( &rhs ) ) {
00039 return casted_rhs->m_data == m_data;
00040 }
00041 return false;
00042 }
00043 virtual TQMimeSource* mimeSource() const { return new TQTextDrag( m_data ) ; }
00044
00048 virtual void write( TQDataStream& stream ) const;
00049
00050 private:
00051 TQString m_data;
00052 };
00053
00054 inline TQString HistoryStringItem::text() const { return m_data; }
00055
00056
00057 #endif