tdeio/bookmarks
kbookmarkbar.h
00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 #ifndef KBOOKMARKBAR_H
00022 #define KBOOKMARKBAR_H
00023
00024 #include <tqobject.h>
00025 #include <tqguardedptr.h>
00026 #include <tqptrlist.h>
00027 #include <kbookmark.h>
00028 #include <tdeaction.h>
00029
00030 class TDEToolBar;
00031 class KBookmarkMenu;
00032 class KBookmarkOwner;
00033 class TDEActionCollection;
00034 class TDEAction;
00035 class TQPopupMenu;
00036
00042 class TDEIO_EXPORT KBookmarkBar : public TQObject
00043 {
00044 Q_OBJECT
00045
00046 friend class RMB;
00047 public:
00060 KBookmarkBar( KBookmarkManager* manager,
00061 KBookmarkOwner *owner, TDEToolBar *toolBar,
00062 TDEActionCollection *,
00063 TQObject *parent = 0L, const char *name = 0L);
00064
00065 virtual ~KBookmarkBar();
00066
00070 bool isReadOnly() const;
00071
00075 void setReadOnly(bool);
00076
00080 TQString parentAddress();
00081
00082 signals:
00086 void aboutToShowContextMenu( const KBookmark &, TQPopupMenu * );
00090 void openBookmark( const TQString& url, TQt::ButtonState state );
00091
00092 public slots:
00093 void clear();
00094
00095 void slotBookmarksChanged( const TQString & );
00096 void slotBookmarkSelected();
00097
00101 void slotBookmarkSelected( TDEAction::ActivationReason reason, TQt::ButtonState state );
00102
00104 void slotRMBActionRemove( int );
00106 void slotRMBActionInsert( int );
00108 void slotRMBActionCopyLocation( int );
00110 void slotRMBActionEditAt( int );
00112 void slotRMBActionProperties( int );
00113
00114 protected:
00115 void fillBookmarkBar( KBookmarkGroup & parent );
00116 virtual bool eventFilter( TQObject *o, TQEvent *e );
00117
00118 private:
00119 KBookmarkGroup getToolbar();
00120
00121 KBookmarkOwner *m_pOwner;
00122 TQGuardedPtr<TDEToolBar> m_toolBar;
00123 TDEActionCollection *m_actionCollection;
00124 KBookmarkManager *m_pManager;
00125 TQPtrList<KBookmarkMenu> m_lstSubMenus;
00126
00127 private:
00128 class KBookmarkBarPrivate* dptr() const;
00129 };
00130
00131 #endif // KBOOKMARKBAR_H