mirror of
https://invent.kde.org/network/falkon.git
synced 2024-12-24 04:36:34 +01:00
parent
949bfe42ed
commit
109f607157
@ -671,14 +671,10 @@ void MainApplication::saveSettings()
|
||||
settings.endGroup();
|
||||
|
||||
settings.beginGroup("Web-Browser-Settings");
|
||||
bool deleteCookies = settings.value("deleteCookiesOnClose", false).toBool();
|
||||
bool deleteHistory = settings.value("deleteHistoryOnClose", false).toBool();
|
||||
bool deleteHtml5Storage = settings.value("deleteHTML5StorageOnClose", false).toBool();
|
||||
settings.endGroup();
|
||||
|
||||
if (deleteCookies) {
|
||||
m_cookiejar->clearCookies();
|
||||
}
|
||||
if (deleteHistory) {
|
||||
m_historymodel->clearHistory();
|
||||
}
|
||||
|
@ -1,6 +1,6 @@
|
||||
/* ============================================================
|
||||
* QupZilla - WebKit based browser
|
||||
* Copyright (C) 2010-2012 David Rosca <nowrep@gmail.com>
|
||||
* Copyright (C) 2010-2013 David Rosca <nowrep@gmail.com>
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@ -177,11 +177,16 @@ bool CookieJar::setCookiesFromUrl(const QList<QNetworkCookie> &cookieList, const
|
||||
|
||||
void CookieJar::saveCookies()
|
||||
{
|
||||
if (m_deleteOnClose || mApp->isPrivateSession()) {
|
||||
if (mApp->isPrivateSession()) {
|
||||
return;
|
||||
}
|
||||
|
||||
QList<QNetworkCookie> allCookies = getAllCookies();
|
||||
QList<QNetworkCookie> allCookies;
|
||||
|
||||
// If we are deleting cookies on close, let's just save empty cookie list
|
||||
if (!m_deleteOnClose) {
|
||||
allCookies = getAllCookies();
|
||||
}
|
||||
|
||||
QFile file(m_activeProfil + "cookies.dat");
|
||||
file.open(QIODevice::WriteOnly);
|
||||
|
Loading…
Reference in New Issue
Block a user