diff options
author | Lionel Chauvin <megabigbug@yahoo.fr> | 2009-08-05 22:47:31 +0200 |
---|---|---|
committer | Lionel Chauvin <megabigbug@yahoo.fr> | 2009-08-05 22:47:31 +0200 |
commit | 4b38a882c26d23f22f603f8638c178b2bf4e183a (patch) | |
tree | 340663084cb34fc03692bfbfd651eba1f297bec4 /src/cookiejar.cpp | |
parent | add m_windowId else unable to connect to KCookieJarServer (diff) | |
download | rekonq-4b38a882c26d23f22f603f8638c178b2bf4e183a.tar.xz |
fix: clear cookies
Diffstat (limited to 'src/cookiejar.cpp')
-rw-r--r-- | src/cookiejar.cpp | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/src/cookiejar.cpp b/src/cookiejar.cpp index 324fe827..e6409f3e 100644 --- a/src/cookiejar.cpp +++ b/src/cookiejar.cpp @@ -86,7 +86,6 @@ QList<QNetworkCookie> CookieJar::cookiesForUrl(const QUrl & url) const } - bool CookieJar::setCookiesFromUrl(const QList<QNetworkCookie> & cookieList, const QUrl & url) { @@ -109,7 +108,20 @@ bool CookieJar::setCookiesFromUrl(const QList<QNetworkCookie> & cookieList, cons return false; } + void CookieJar::setWindowId(qlonglong id) { m_windowId=id; } + + +void CookieJar::clear() +{ + QDBusInterface kcookiejar("org.kde.kded", "/modules/kcookiejar", "org.kde.KCookieServer", QDBusConnection::sessionBus()); + QDBusReply<void> reply = kcookiejar.call( "deleteAllCookies" ); + if (!reply.isValid()) + { + kWarning() << "Unable to delete all the cookies as requested."; + return; + } +}
\ No newline at end of file |