// KDE Frameworks headers.
#include <KConfigDialog>
#include <KToggleFullScreenAction>
+#include <KToolBar>
#include <KXmlGuiWindow>
// Qt toolkit headers.
public:
// The default constructor.
- BrowserWindow(bool firstWindow=true);
+ BrowserWindow(bool firstWindow=true, QString *initialUrlStringPointer = nullptr);
// The public functions.
QSize sizeHint() const override;
void addOrEditDomainSettings() const;
void back() const;
void clearUrlLineEditFocus() const;
+ void decrementZoom();
+ void editBookmarks() const;
void escape() const;
void findNext() const;
void findPrevious() const;
void getZoomFactorFromUser();
void hideFindTextActions() const;
void home() const;
+ void incrementZoom();
void loadUrlFromLineEdit(const QString &url) const;
void newWindow() const;
+ void populateBookmarks();
void refresh() const;
void reloadAndBypassCache() const;
+ void showAddBookmarkDialog() const;
+ void showAddFolderDialog() const;
+ void showBookmarkContextMenu(const QPoint &point);
void showCookiesDialog();
void showDownloadLocationBrowseDialog() const;
void showDomainSettingsDialog() const;
void showFindTextActions() const;
void showProgressBar(const int &progress) const;
void showSettingsDialog();
+ void toggleBookmark();
void toggleDomStorage() const;
void toggleFindCaseSensitive() const;
void toggleJavaScript() const;
void toggleLocalStorage() const;
void toggleFullScreen();
+ void toggleViewBookmarksToolBar();
void toggleViewSource() const;
void toggleViewSourceInNewTab() const;
void updateCookiesAction(const int numberOfCookies) const;
+ void updateDefaultZoomFactor(const double newDefaultZoomFactor);
void updateDomStorageAction(const bool &isEnabled) const;
void updateDomainSettingsIndicator(const bool status);
void updateFindText(const QString &text, const bool findCaseSensitive) const;
void updateLocalStorageAction(const bool &isEnabled);
void updateSearchEngineActions(const QString &searchEngine, const bool &updateCustomSearchEngineStatus);
void updateUserAgentActions(const QString &userAgent, const bool &updateCustomUserAgentStatus);
- void updateZoomFactorAction(const double &zoomFactor);
+ void updateZoomActions(const double &zoomFactor);
void updateSearchEngineLabel(const QString &searchEngineString) const;
void updateUrlLineEdit(const QUrl &newUrl);
void updateUserAgentLabel(const QString &userAgentDatabaseName) const;
+ void updateViewBookmarksToolBarCheckbox(const bool visible);
void updateWindowTitle(const QString &title);
+ void zoomDefault();
private:
// The private variables.
+ QAction *bookmarkedActionPointer;
+ QList<QPair<QMenu *, QAction *> *> bookmarksMenuActionList;
+ QMenu *bookmarksMenuPointer;
+ QList<QPair<QMenu *, QMenu *> *> bookmarksMenuSubmenuList;
+ QList<QAction*> bookmarksToolBarActionList;
+ QList<QPair<QMenu *, const double> *> bookmarksToolBarMenuList;
+ KToolBar *bookmarksToolBarPointer;
+ QList<QPair<QMenu *, QAction *> *> bookmarksToolBarSubfolderActionList;
+ bool bookmarksToolBarIsVisible = false;
+ bool bookmarksToolBarUninitialized = true;
KConfigDialog *configDialogPointer;
QAction *cookiesActionPointer;
QUrl currentUrl;
+ QPushButton *currentZoomButtonPointer;
double currentZoomFactor;
bool customSearchEngineEnabled;
bool customUserAgentEnabled;
+ double defaultZoomFactor;
QAction *domStorageActionPointer;
QComboBox *downloadLocationComboBoxPointer;
QAction *findCaseSensitiveActionPointer;
QAction *userAgentCustomActionPointer;
KLineEdit *urlLineEditPointer;
KToolBar *urlToolBarPointer;
+ QAction *viewBookmarksToolBarActionPointer;
QAction *viewSourceActionPointer;
+ QAction *viewSourceInNewTabActionPointer;
+ QAction *zoomDefaultActionPointer;
QAction *zoomFactorActionPointer;
+ QAction *zoomInActionPointer;
+ QPushButton *zoomMinusButtonPointer;
+ QAction *zoomOutActionPointer;
+ QPushButton *zoomPlusButtonPointer;
+
+ // The private functions.
+ void addFinalBookmarkFolderMenuEntries(QMenu *menuPointer, double folderId);
+ void populateBookmarksMenuSubfolders(const double folderId, QMenu *menuPointer);
+ void populateBookmarksToolBar();
+ void populateBookmarksToolBarSubfolders(const double folderId, QMenu *menuPointer);
+ void updateBookmarkedAction() const;
};
#endif