2012-01-21 20:24:36 +01:00
|
|
|
/* ============================================================
|
|
|
|
* QupZilla - WebKit based browser
|
2014-01-11 16:11:42 +01:00
|
|
|
* Copyright (C) 2010-2014 David Rosca <nowrep@gmail.com>
|
2012-01-21 20:24:36 +01:00
|
|
|
*
|
|
|
|
* This program is free software: you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License as published by
|
|
|
|
* the Free Software Foundation, either version 3 of the License, or
|
|
|
|
* (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
* ============================================================ */
|
|
|
|
#ifndef POPUPWINDOW_H
|
|
|
|
#define POPUPWINDOW_H
|
|
|
|
|
|
|
|
#include <QWidget>
|
2013-01-25 19:52:30 +01:00
|
|
|
#include <QPointer>
|
2012-02-29 18:33:50 +01:00
|
|
|
|
|
|
|
#include "qz_namespace.h"
|
|
|
|
|
|
|
|
class QVBoxLayout;
|
|
|
|
class QStatusBar;
|
2013-01-25 19:52:30 +01:00
|
|
|
class QMenuBar;
|
|
|
|
class QMenu;
|
2012-01-21 20:24:36 +01:00
|
|
|
|
|
|
|
class PopupWebView;
|
|
|
|
class PopupWebPage;
|
2012-03-04 14:25:52 +01:00
|
|
|
class PopupStatusBarMessage;
|
2012-01-21 20:24:36 +01:00
|
|
|
class PopupLocationBar;
|
2012-03-04 14:25:52 +01:00
|
|
|
class ProgressBar;
|
2013-01-25 19:52:30 +01:00
|
|
|
class SearchToolBar;
|
2012-02-29 18:33:50 +01:00
|
|
|
|
|
|
|
class QT_QUPZILLA_EXPORT PopupWindow : public QWidget
|
2012-01-21 20:24:36 +01:00
|
|
|
{
|
|
|
|
Q_OBJECT
|
|
|
|
public:
|
2013-01-25 19:52:30 +01:00
|
|
|
explicit PopupWindow(PopupWebView* view);
|
2012-03-04 14:25:52 +01:00
|
|
|
|
|
|
|
QStatusBar* statusBar();
|
|
|
|
PopupWebView* webView();
|
2012-01-21 20:24:36 +01:00
|
|
|
|
|
|
|
public slots:
|
2013-01-25 19:52:30 +01:00
|
|
|
void setWindowGeometry(QRect newRect);
|
2012-01-21 20:24:36 +01:00
|
|
|
void setStatusBarVisibility(bool visible);
|
|
|
|
void setMenuBarVisibility(bool visible);
|
|
|
|
void setToolBarVisibility(bool visible);
|
|
|
|
|
|
|
|
private slots:
|
|
|
|
void titleChanged();
|
|
|
|
void showNotification(QWidget* notif);
|
2012-03-04 14:25:52 +01:00
|
|
|
void showStatusBarMessage(const QString &message);
|
|
|
|
|
|
|
|
void loadStarted();
|
|
|
|
void loadProgress(int value);
|
|
|
|
void loadFinished();
|
2012-01-21 20:24:36 +01:00
|
|
|
|
2013-01-25 19:52:30 +01:00
|
|
|
void editUndo();
|
|
|
|
void editRedo();
|
|
|
|
void editCut();
|
|
|
|
void editCopy();
|
|
|
|
void editPaste();
|
|
|
|
void editSelectAll();
|
|
|
|
|
|
|
|
void aboutToShowEditMenu();
|
2013-02-10 11:17:44 +01:00
|
|
|
void aboutToHideEditMenu();
|
2013-01-25 19:52:30 +01:00
|
|
|
|
|
|
|
void savePageScreen();
|
|
|
|
void searchOnPage();
|
|
|
|
|
2012-01-21 20:24:36 +01:00
|
|
|
private:
|
|
|
|
void closeEvent(QCloseEvent* event);
|
2012-03-04 14:25:52 +01:00
|
|
|
|
2012-01-21 20:24:36 +01:00
|
|
|
PopupWebView* m_view;
|
|
|
|
PopupWebPage* m_page;
|
|
|
|
PopupLocationBar* m_locationBar;
|
2012-03-04 14:25:52 +01:00
|
|
|
PopupStatusBarMessage* m_statusBarMessage;
|
|
|
|
ProgressBar* m_progressBar;
|
2012-01-21 20:24:36 +01:00
|
|
|
|
|
|
|
QVBoxLayout* m_layout;
|
|
|
|
QStatusBar* m_statusBar;
|
2013-01-25 19:52:30 +01:00
|
|
|
QMenuBar* m_menuBar;
|
|
|
|
QMenu* m_menuEdit;
|
|
|
|
QMenu* m_menuView;
|
|
|
|
QAction* m_actionReload;
|
|
|
|
QAction* m_actionStop;
|
|
|
|
QPointer<SearchToolBar> m_search;
|
2012-01-21 20:24:36 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif // POPUPWINDOW_H
|