aboutsummaryrefslogtreecommitdiff
path: root/src/webengine/webengineprofile.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/webengine/webengineprofile.h')
-rw-r--r--src/webengine/webengineprofile.h27
1 files changed, 9 insertions, 18 deletions
diff --git a/src/webengine/webengineprofile.h b/src/webengine/webengineprofile.h
index d93e079..6a0d4e2 100644
--- a/src/webengine/webengineprofile.h
+++ b/src/webengine/webengineprofile.h
@@ -6,44 +6,35 @@
* SPDX-License-Identifier: GPL-3.0
*/
-#ifndef WEBENGINEPROFILE_H
-#define WEBENGINEPROFILE_H
+#ifndef SMOLBOTE_WEBENGINEPROFILE_H
+#define SMOLBOTE_WEBENGINEPROFILE_H
#include <QUrl>
#include <QWebEngineProfile>
-#include "cookieinterceptor.h"
+#include "cookiefilter.h"
class WebEngineProfile : public QWebEngineProfile
{
Q_OBJECT
public:
explicit WebEngineProfile(QObject *parent = nullptr);
- explicit WebEngineProfile(const QString &name, const QString &path, QObject *parent = nullptr);
+ explicit WebEngineProfile(const QString &name, QObject *parent = nullptr);
- ~WebEngineProfile();
+ ~WebEngineProfile() override;
QString name() const;
-
QUrl homepage() const;
- void setHomepage(const QUrl &url);
-
QUrl newtab() const;
- void setNewtab(const QUrl &url);
-
- void setCookieInterceptor(CookieInterceptor *interceptor);
-
-signals:
public slots:
- void saveProfile();
+ void loadProfile(const QString &path);
+ void saveProfile(const QString &path = QString());
private:
+ QString m_configPath;
QString m_name;
- bool shouldSaveProfile = false;
QUrl m_homepage = QUrl("about:blank");
QUrl m_newtab = QUrl("about:blank");
};
-[[nodiscard]] WebEngineProfile *createProfile(const QString &name, const QString &path, QObject *parent);
-
-#endif // WEBENGINEPROFILE_H
+#endif // SMOLBOTE_WEBENGINEPROFILE_H