]> gitweb.stoutner.com Git - PrivacyBrowserPC.git/blobdiff - src/dialogs/DomainSettingsDialog.h
Partial filter list implementation.
[PrivacyBrowserPC.git] / src / dialogs / DomainSettingsDialog.h
index 5663787b1b6ecc749cef5c431b08d1e4d4abde14..cef20602e5dc1073f0431c1210425062cb60689d 100644 (file)
@@ -1,7 +1,7 @@
 /*
- * Copyright © 2022 Soren Stoutner <soren@stoutner.com>.
+ * Copyright 2022, 2024 Soren Stoutner <soren@stoutner.com>.
  *
- * This file is part of Privacy Browser PC <https://www.stoutner.com/privacy-browser-pc>.
+ * This file is part of Privacy Browser PC <https://www.stoutner.com/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
@@ -20,6 +20,9 @@
 #ifndef DOMAINSETTINGSDIALOG_H
 #define DOMAINSETTINGSDIALOG_H
 
+// Application headers.
+#include "helpers/UserAgentHelper.h"
+
 // KDE Frameworks headers.
 #include <KLineEdit>
 
@@ -36,7 +39,7 @@ class DomainSettingsDialog : public QDialog
 
 public:
     // The primary constructor.
-    explicit DomainSettingsDialog(const int &startType = SHOW_ALL_DOMAINS, const QString &domainName = QStringLiteral(""));
+    explicit DomainSettingsDialog(QWidget *parentWidgetPointer, const int &startType = SHOW_ALL_DOMAINS, const QString &domainName = QStringLiteral(""));
 
     // The public static int constants.
     static const int SHOW_ALL_DOMAINS;
@@ -51,6 +54,7 @@ private Q_SLOTS:
     void apply() const;
     void cancel();
     void customZoomFactorChanged(const double &newValue) const;
+    void domStorageChanged(const int &newIndex) const;
     void domainNameChanged(const QString &updatedDomainName) const;
     void domainSelected(const QModelIndex &modelIndex) const;
     void javaScriptChanged(const int &newIndex) const;
@@ -66,25 +70,37 @@ private:
     // The private variables.
     QPushButton *applyButtonPointer;
     QDoubleSpinBox *customZoomFactorSpinBoxPointer;
+    QPalette defaultPalette;
     QPushButton *deleteDomainButtonPointer;
-    QListView *domainsListViewPointer;
+    QWidget *domStorageWidgetPointer;
+    QComboBox *domStorageComboBoxPointer;
+    QLabel *domStorageLabelPointer;
     KLineEdit *domainNameLineEditPointer;
     QWidget *domainSettingsWidgetPointer;
+    QListView *domainsListViewPointer;
     QSqlTableModel *domainsTableModelPointer;
+    QItemSelectionModel *domainsSelectionModelPointer;
+    QPalette highlightedPalette;
+    QWidget *javaScriptWidgetPointer;
     QComboBox *javaScriptComboBoxPointer;
     QLabel *javaScriptLabelPointer;
+    QWidget *localStorageWidgetPointer;
     QComboBox *localStorageComboBoxPointer;
     QLabel *localStorageLabelPointer;
     QPushButton *resetButtonPointer;
+    QWidget *userAgentWidgetPointer;
     QComboBox *userAgentComboBoxPointer;
+    UserAgentHelper *userAgentHelperPointer;
     QLabel *userAgentLabelPointer;
+    QWidget *zoomFactorWidgetPointer;
     QComboBox *zoomFactorComboBoxPointer;
 
     // The private functions.
-    void addDomain(const QString &domainName) const;
+    void populateDomStorageLabel() const;
     void populateJavaScriptLabel() const;
     void populateLocalStorageLabel() const;
     void populateUserAgentLabel(const QString &userAgentName) const;
+    void updateDomStorageStatus() const;
     void updateUi() const;
 };
 #endif