kio Library API Documentation

kbookmarkbar.h

00001 // -*- c-basic-offset:4; indent-tabs-mode:nil -*- 00002 // vim: set ts=4 sts=4 sw=4 et: 00003 /* This file is part of the KDE project 00004 Copyright (C) 1999 Kurt Granroth <granroth@kde.org> 00005 00006 This library is free software; you can redistribute it and/or 00007 modify it under the terms of the GNU Library General Public 00008 License as published by the Free Software Foundation; either 00009 version 2 of the License, or (at your option) any later version. 00010 00011 This library is distributed in the hope that it will be useful, 00012 but WITHOUT ANY WARRANTY; without even the implied warranty of 00013 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00014 Library General Public License for more details. 00015 00016 You should have received a copy of the GNU Library General Public License 00017 along with this library; see the file COPYING.LIB. If not, write to 00018 the Free Software Foundation, Inc., 59 Temple Place - Suite 330, 00019 Boston, MA 02111-1307, USA. 00020 */ 00021 #ifndef KBOOKMARKBAR_H 00022 #define KBOOKMARKBAR_H 00023 00024 #include <qobject.h> 00025 #include <qguardedptr.h> 00026 #include <qptrlist.h> 00027 #include <kbookmark.h> 00028 #include <kaction.h> 00029 00030 class KToolBar; 00031 class KBookmarkMenu; 00032 class KBookmarkOwner; 00033 class KActionCollection; 00034 class KAction; 00035 class QPopupMenu; 00036 00042 class KIO_EXPORT KBookmarkBar : public QObject 00043 { 00044 Q_OBJECT 00045 friend class RMB; 00046 public: 00059 KBookmarkBar( KBookmarkManager* manager, 00060 KBookmarkOwner *owner, KToolBar *toolBar, 00061 KActionCollection *, 00062 QObject *parent = 0L, const char *name = 0L); 00063 00064 virtual ~KBookmarkBar(); 00065 00069 bool isReadOnly() const; 00070 00074 void setReadOnly(bool); 00075 00079 QString parentAddress(); 00080 00081 signals: 00085 void aboutToShowContextMenu( const KBookmark &, QPopupMenu * ); 00089 void openBookmark( const QString& url, Qt::ButtonState state ); 00090 00091 public slots: 00092 void clear(); 00093 00094 void slotBookmarksChanged( const QString & ); 00095 void slotBookmarkSelected(); 00096 00100 void slotBookmarkSelected( KAction::ActivationReason reason, Qt::ButtonState state ); 00101 00103 void slotRMBActionRemove( int ); 00105 void slotRMBActionInsert( int ); 00107 void slotRMBActionCopyLocation( int ); 00109 void slotRMBActionEditAt( int ); 00111 void slotRMBActionProperties( int ); 00112 00113 protected: 00114 void fillBookmarkBar( KBookmarkGroup & parent ); 00115 virtual bool eventFilter( QObject *o, QEvent *e ); 00116 00117 private: 00118 KBookmarkGroup getToolbar(); 00119 00120 KBookmarkOwner *m_pOwner; 00121 QGuardedPtr<KToolBar> m_toolBar; 00122 KActionCollection *m_actionCollection; 00123 KBookmarkManager *m_pManager; 00124 QPtrList<KBookmarkMenu> m_lstSubMenus; 00125 00126 private: 00127 class KBookmarkBarPrivate* dptr() const; 00128 }; 00129 00130 #endif // KBOOKMARKBAR_H
KDE Logo
This file is part of the documentation for kio Library Version 3.4.0.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Thu Apr 14 00:20:21 2005 by doxygen 1.3.7 written by Dimitri van Heesch, © 1997-2003