summaryrefslogtreecommitdiff
path: root/src/webengine/api/qquickwebengineprofile.cpp
diff options
context:
space:
mode:
authorSzabolcs David <davidsz@inf.u-szeged.hu>2015-12-10 07:05:29 -0800
committerSzabolcs David <davidsz@inf.u-szeged.hu>2016-01-06 08:06:33 +0000
commitf5ed13b1e2d20ca49adb6fa378faee14bece16a0 (patch)
tree70dbd031d4a59a8b5031fc93795f5a08ac715c65 /src/webengine/api/qquickwebengineprofile.cpp
parent1ae9e7cc00a366fddcb4909df375829e9727c7fa (diff)
downloadqtwebengine-f5ed13b1e2d20ca49adb6fa378faee14bece16a0.tar.gz
Add function to clear data from the cache
It marks the entries of the current cache backend for deletion and starts to remove them. Task-number: QTBUG-48177 Change-Id: I85ec25048ff5429976f1b2dcacd74666bdbe6624 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com>
Diffstat (limited to 'src/webengine/api/qquickwebengineprofile.cpp')
-rw-r--r--src/webengine/api/qquickwebengineprofile.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/webengine/api/qquickwebengineprofile.cpp b/src/webengine/api/qquickwebengineprofile.cpp
index 0c3f7400b..6df16bf54 100644
--- a/src/webengine/api/qquickwebengineprofile.cpp
+++ b/src/webengine/api/qquickwebengineprofile.cpp
@@ -436,6 +436,20 @@ QWebEngineCookieStore *QQuickWebEngineProfile::cookieStore() const
return d->browserContext()->cookieStore();
}
+/*!
+ \qmlmethod void WebEngineProfile::clearHttpCache()
+ \since QtWebEngine 1.3
+
+ Removes the profile's cache entries.
+
+ \sa WebEngineProfile::cachePath
+*/
+void QQuickWebEngineProfile::clearHttpCache()
+{
+ Q_D(QQuickWebEngineProfile);
+ d->browserContext()->clearHttpCache();
+}
+
QQuickWebEngineSettings *QQuickWebEngineProfile::settings() const
{
const Q_D(QQuickWebEngineProfile);