X-Git-Url: https://gitweb.stoutner.com/?p=PrivacyBrowserPC.git;a=blobdiff_plain;f=src%2Fmainview.h;h=5e5535fba43fb741a9ca5fecdc89ea454cc3a544;hp=6b9e6ca8657f93405100422e43c54cc1a50ebfa7;hb=3d2e70c352736d809d6d0b705864ce17ffde68ae;hpb=153c5c0d60eaf3185cb4419032fb0fdaeb78907c diff --git a/src/mainview.h b/src/mainview.h index 6b9e6ca..5e5535f 100644 --- a/src/mainview.h +++ b/src/mainview.h @@ -1,45 +1,53 @@ /* - SPDX-FileCopyrightText: %{CURRENT_YEAR} %{AUTHOR} <%{EMAIL}> - - SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL -*/ + * Copyright © 2022 Soren Stoutner . + * + * This file is part of Privacy Browser PC . + * + * Privacy Browser PC 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. + * + * Privacy Browser PC 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 Privacy Browser PC. If not, see . + */ #ifndef MAINVIEW_H #define MAINVIEW_H +// Application headers. #include "ui_mainview.h" - -/** - * This class serves as the main window for privacybrowserpc. It handles the - * menus, toolbars and status bars. - * - * @short Main window class - * @author %{AUTHOR} <%{EMAIL}> - * @version %{VERSION} - */ class MainView : public QWidget { + // Include the Q_OBJECT macro. Q_OBJECT + public: - /** - * Default Constructor - */ + // The primary contructor. explicit MainView(QWidget *parent); - /** - * Default Destructor - */ - ~MainView() override; +signals: + // Define the signals. + void linkHovered(const QString &linkUrl); -public Q_SLOTS: - void switchColors(); - void handleSettingsChanged(); +private Q_SLOTS: + // Define the private slots. + void loadUrl(const QString &urlFromUser); + void pageLinkHovered(const QString &linkUrl); + void updateInterface(); private: - // this is the name of the root widget inside our Ui file - // you can rename it in designer and then change it here - Ui::MainView m_ui; + // Define the private variables. + QPushButton *backButtonPointer; + QPushButton *forwardButtonPointer; + KLineEdit *urlLineEditPointer; + QWebEngineHistory *webEngineHistoryPointer; + QWebEngineView *webEngineViewPointer; }; - #endif