2013-06-16 08:17:46 -05:00
|
|
|
//////////////////////////////////////////////////////////////////////////
|
|
|
|
//
|
|
|
|
// pgAdmin 4 - PostgreSQL Tools
|
|
|
|
//
|
|
|
|
// Copyright (C) 2013, The pgAdmin Development Team
|
|
|
|
// This software is released under the PostgreSQL Licence
|
|
|
|
//
|
|
|
|
// BrowserWindow.h - Declaration of the main window class
|
|
|
|
//
|
|
|
|
//////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
#ifndef BROWSERWINDOW_H
|
|
|
|
#define BROWSERWINDOW_H
|
|
|
|
|
2013-06-21 17:21:11 -05:00
|
|
|
#include "pgAdmin4.h"
|
|
|
|
|
2013-06-16 08:17:46 -05:00
|
|
|
#include <QtGlobal>
|
|
|
|
|
|
|
|
#if QT_VERSION >= 0x050000
|
|
|
|
#include <QtWidgets>
|
|
|
|
#include <QtWebKitWidgets>
|
|
|
|
#else
|
|
|
|
#include <QMainWindow>
|
|
|
|
#include <QWebView>
|
|
|
|
#endif
|
|
|
|
|
|
|
|
QT_BEGIN_NAMESPACE
|
|
|
|
class QAction;
|
|
|
|
class QMenu;
|
|
|
|
QT_END_NAMESPACE
|
|
|
|
|
|
|
|
class BrowserWindow : public QMainWindow
|
|
|
|
{
|
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
public:
|
|
|
|
BrowserWindow();
|
|
|
|
|
2013-06-21 18:49:40 -05:00
|
|
|
protected slots:
|
|
|
|
void finishLoading(bool);
|
|
|
|
|
2013-06-16 08:17:46 -05:00
|
|
|
private slots:
|
|
|
|
void openUrl();
|
|
|
|
void about();
|
|
|
|
|
|
|
|
private:
|
|
|
|
QWebView *webView;
|
|
|
|
QMenu *fileMenu;
|
|
|
|
QMenu *helpMenu;
|
|
|
|
QAction *openUrlAction;
|
|
|
|
QAction *exitAction;
|
|
|
|
QAction *aboutAction;
|
|
|
|
|
2013-06-21 18:49:40 -05:00
|
|
|
bool m_initialload;
|
|
|
|
int m_loadattempt;
|
|
|
|
|
2013-06-16 08:17:46 -05:00
|
|
|
void createActions();
|
|
|
|
void createMenus();
|
2013-06-21 18:49:40 -05:00
|
|
|
void pause(int seconds = 1);
|
2013-06-16 08:17:46 -05:00
|
|
|
};
|
|
|
|
|
2013-06-21 17:21:11 -05:00
|
|
|
#endif // BROWSERWINDOW_H
|