1/* This file is part of the KDE project
2 Copyright (C) xxxx KFile Authors
3 Copyright (C) 2002 Anders Lund <anders.lund@lund.tdcadsl.dk>
4 Copyright (C) 2007 Mirko Stocker <me@misto.ch>
5 Copyright (C) 2009 Dominik Haumann <dhaumann kde org>
6
7 This library is free software; you can redistribute it and/or
8 modify it under the terms of the GNU Library General Public
9 License version 2 as published by the Free Software Foundation.
10
11 This library is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 Library General Public License for more details.
15
16 You should have received a copy of the GNU Library General Public License
17 along with this library; see the file COPYING.LIB. If not, write to
18 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
19 Boston, MA 02110-1301, USA.
20*/
21
22#ifndef KATE_BOOKMARK_HANDLER_H
23#define KATE_BOOKMARK_HANDLER_H
24
25#include <kbookmarkmanager.h>
26#include <kbookmarkmenu.h>
27
28class KateFileBrowser;
29
30class KateBookmarkHandler : public QObject, public KBookmarkOwner
31{
32 Q_OBJECT
33
34 public:
35 explicit KateBookmarkHandler( KateFileBrowser *parent, KMenu *kpopupmenu = 0 );
36 ~KateBookmarkHandler();
37
38 // KBookmarkOwner interface:
39 virtual QString currentUrl() const;
40 virtual QString currentTitle() const;
41
42 KMenu *menu() const
43 {
44 return m_menu;
45 }
46 virtual void openBookmark( const KBookmark &, Qt::MouseButtons, Qt::KeyboardModifiers );
47
48 Q_SIGNALS:
49 void openUrl( const QString& url );
50
51 private:
52 KateFileBrowser *mParent;
53 KMenu *m_menu;
54 KBookmarkMenu *m_bookmarkMenu;
55};
56
57#endif // KATE_BOOKMARK_HANDLER_H
58// kate: space-indent on; indent-width 2; replace-tabs on;
59
60