Go to the documentation of this file.
25 #ifndef __KSUBSCRIPTION
26 #define __KSUBSCRIPTION
28 #include <tqlistview.h>
29 #include <tqcheckbox.h>
31 #include <kdialogbase.h>
32 #include <tdepimmacros.h>
33 #include "kfoldertree.h"
45 class KDE_EXPORT KGroupInfo
55 KGroupInfo( const TQString &name, const TQString &description = TQString(),
56 bool newGroup = false, bool subscribed = false,
57 Status status = unknown, TQString path = TQString() );
59 TQString name, description;
60 bool newGroup, subscribed;
64 bool operator== ( const KGroupInfo &gi2);
65 bool operator< ( const KGroupInfo &gi2);
76 bool isCheckItem = false );
78 bool isCheckItem = false );
83 KGroupInfo info() { return mInfo; }
84 void setInfo( KGroupInfo info );
90 void setOriginalParent( TQListViewItem* parent ) { mOriginalParent = parent; }
96 void setLastOpenState( bool last ) { mLastOpenState = last; }
102 virtual void setDescription();
113 void setIgnoreStateChange( bool ignore ) { mIgnoreStateChange = ignore; }
119 virtual void setOn( bool on );
125 virtual void stateChange( bool on );
131 void setVisible( bool b );
137 virtual void paintCell( TQPainter * p, const TQColorGroup & cg,
138 int column, int width, int align );
144 virtual void paintFocus( TQPainter *, const TQColorGroup & cg,
151 virtual int width( const TQFontMetrics&, const TQListView*, int column) const;
157 virtual void setup();
160 virtual int rtti () const { return 15689; }
165 TQListViewItem* mOriginalParent;
171 bool mIgnoreStateChange;
202 KSubscription( TQWidget *parent, const TQString &caption, KAccount* acct,
203 int buttons = 0, const TQString &user1 = TQString(),
204 bool descriptionColumn = true );
212 void setAccount( KAccount * acct ) { mAcct = acct; }
227 void setStartItem( const KGroupInfo &info );
232 void removeListItem( TQListView *view, const KGroupInfo &gi );
238 TQListViewItem* getListItem( TQListView *view, const KGroupInfo &gi );
243 bool itemInListView( TQListView *view, const KGroupInfo &gi );
249 void changeItemState( GroupItem* item, bool on );
255 void setDirectionButton1( Direction dir );
261 void setDirectionButton2( Direction dir );
283 void filterChanged( TQListViewItem* item = 0,
284 const TQString & text = TQString() );
289 uint activeItemCount();
294 void restoreOriginalParent();
299 void saveOpenStates();
304 void restoreOpenStates();
311 void slotLoadingComplete();
316 void slotChangeButtonState( TQListViewItem* );
327 void slotUpdateStatusLabel();
332 void slotLoadFolders();
338 void slotCBToggled();
343 void slotFilterTextChanged( const TQString & text );
359 TQListView *groupView;
360 TQListView *subView, *unsubView;
361 KLineEdit *filterEdit;
362 TQCheckBox *noTreeCB, *subCB, *newCB;
363 TQPushButton *arrowBtn1, *arrowBtn2;
364 TQIconSet pmRight, pmLeft;
366 TQLabel *leftLabel, *rightLabel;
372 Direction mDirButton1;
373 Direction mDirButton2;
|