Falkon Develop
Cross-platform Qt-based web browser
historymenu.h
Go to the documentation of this file.
1/* ============================================================
2* Falkon - Qt web browser
3* Copyright (C) 2014-2018 David Rosca <nowrep@gmail.com>
4*
5* This program is free software: you can redistribute it and/or modify
6* it under the terms of the GNU General Public License as published by
7* the Free Software Foundation, either version 3 of the License, or
8* (at your option) any later version.
9*
10* This program is distributed in the hope that it will be useful,
11* but WITHOUT ANY WARRANTY; without even the implied warranty of
12* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13* GNU General Public License for more details.
14*
15* You should have received a copy of the GNU General Public License
16* along with this program. If not, see <http://www.gnu.org/licenses/>.
17* ============================================================ */
18#ifndef HISTORYMENU_H
19#define HISTORYMENU_H
20
21#include <QPointer>
22
23#include "enhancedmenu.h"
24#include "qzcommon.h"
25
26class BrowserWindow;
27
29{
30 Q_OBJECT
31
32public:
33 explicit HistoryMenu(QWidget* parent = nullptr);
34
35 void setMainWindow(BrowserWindow* window);
36
37private Q_SLOTS:
38 void goBack();
39 void goForward();
40 void goHome();
41 void showHistoryManager();
42
43 void aboutToShow();
44 void aboutToHide();
45
46 void aboutToShowMostVisited();
47 void aboutToShowClosedTabs();
48 void aboutToShowClosedWindows();
49
50 void historyEntryActivated();
51 void historyEntryCtrlActivated();
52 void historyEntryShiftActivated();
53
54 void openUrl(const QUrl &url);
55 void openUrlInNewTab(const QUrl &url);
56 void openUrlInNewWindow(const QUrl &url);
57
58private:
59 void init();
60
61 QPointer<BrowserWindow> m_window;
62 Menu* m_menuMostVisited;
63 Menu* m_menuClosedTabs;
64 Menu *m_menuClosedWindows;
65};
66
67#endif // HISTORYMENU_H
#define FALKON_EXPORT
Definition: qzcommon.h:28