]> gitweb.stoutner.com Git - PrivacyBrowserPC.git/blobdiff - src/dialogs/AddOrEditCookieDialog.h
Add a default folder icon to the edit folder dialog. https://redmine.stoutner.com...
[PrivacyBrowserPC.git] / src / dialogs / AddOrEditCookieDialog.h
index 5bc763f6e5a2b6dc9f87bf28ec47a2388954185d..cb641c951a2759c1d4d75c29a058f5904a2d94c7 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * 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>.
  *
@@ -33,7 +33,7 @@ class AddOrEditCookieDialog : public QDialog
 
 public:
     // The primary constructor.
-    explicit AddOrEditCookieDialog(const int &dialogType, const QNetworkCookie *cookiePointer = nullptr);
+    explicit AddOrEditCookieDialog(QWidget *parentWidgetPointer, const int dialogType, const QNetworkCookie *cookiePointer = nullptr, const bool isDurable = false);
 
     // The public static constants.
     static const int AddCookie;
@@ -41,7 +41,7 @@ public:
 
 signals:
     // The signals.
-    void addCookie(const QNetworkCookie &cookie) const;
+    void addCookie(const QNetworkCookie &cookie, const bool &isDurable) const;
     void deleteCookie(const QNetworkCookie &cookie) const;
 
 private Q_SLOTS:
@@ -53,6 +53,7 @@ private Q_SLOTS:
 private:
     // The private widgets.
     QLineEdit *domainLineEditPointer;
+    QCheckBox *durableCheckBoxPointer;
     QCheckBox *expirationCheckBoxPointer;
     QDateTimeEdit *expirationDateTimeEditPointer;
     QCheckBox *httpOnlyCheckBoxPointer;
@@ -63,7 +64,8 @@ private:
     QLineEdit *valueLineEditPointer;
 
     // The private variables.
-    QNetworkCookie oldCookie;
     bool isEditDialog;
+    QNetworkCookie originalCookie;
+    bool originalIsDurable;
 };
 #endif