diff options
Diffstat (limited to 'lib/web/webprofile.h')
-rw-r--r-- | lib/web/webprofile.h | 31 |
1 files changed, 2 insertions, 29 deletions
diff --git a/lib/web/webprofile.h b/lib/web/webprofile.h index 269989b..a3b5b12 100644 --- a/lib/web/webprofile.h +++ b/lib/web/webprofile.h @@ -17,28 +17,12 @@ #include <QNetworkCookie> #include <QMap> #include <QWebEngineSettings> +#include <profileinterface.h> -class WebProfile : public QWebEngineProfile +class WebProfile : public Profile { Q_OBJECT - Q_PROPERTY(QString name READ name WRITE setName NOTIFY nameChanged) - Q_PROPERTY(QString search READ search WRITE setSearch NOTIFY searchChanged) - Q_PROPERTY(QUrl homepage READ homepage WRITE setHomepage NOTIFY homepageChanged) - Q_PROPERTY(QUrl newtab READ newtab WRITE setNewtab NOTIFY newtabChanged) - - // QWebEngineProfile should-be properties - Q_PROPERTY(QString cachePath READ cachePath WRITE setCachePath NOTIFY propertyChanged) - Q_PROPERTY(QString persistentStoragePath READ persistentStoragePath WRITE setPersistentStoragePath NOTIFY propertyChanged) - Q_PROPERTY(int persistentCookiesPolicy READ persistentCookiesPolicy WRITE setPersistentCookiesPolicy NOTIFY propertyChanged) - - Q_PROPERTY(QString httpAcceptLanguage READ httpAcceptLanguage WRITE setHttpAcceptLanguage NOTIFY propertyChanged) - Q_PROPERTY(int httpCacheMaximumSize READ httpCacheMaximumSize WRITE setHttpCacheMaximumSize NOTIFY propertyChanged) - Q_PROPERTY(int httpCacheType READ httpCacheType WRITE setHttpCacheType NOTIFY propertyChanged) - Q_PROPERTY(QString httpUserAgent READ httpUserAgent WRITE setHttpUserAgent NOTIFY propertyChanged) - - Q_PROPERTY(bool spellCheckEnabled READ isSpellCheckEnabled WRITE setSpellCheckEnabled NOTIFY propertyChanged) - public: // off-the-record constructor explicit WebProfile(const QString &name, QObject *parent = nullptr); @@ -95,17 +79,6 @@ public: void setSpellCheckEnabled(bool enable); -signals: - void nameChanged(const QString &name); - void searchChanged(const QString &url); - void homepageChanged(const QUrl &url); - void newtabChanged(const QUrl &url); - - void propertyChanged(const QString &name, const QVariant &value); - void attributeChanged(const QWebEngineSettings::WebAttribute attribute, const bool value); - void headerChanged(const QString &name, const QString &value); - void headerRemoved(const QString &name); - private: static WebProfile *profile; |