From e3b8ece1ce004f2049481ceb668bf05ad3ae99f7 Mon Sep 17 00:00:00 2001 From: Andrea Diamantini Date: Sun, 16 Dec 2012 17:04:37 +0100 Subject: "Workaround" cookie management in private browsing mode From the note in webpage file: I'm sorry I really cannot let KIO work as needed in private browsing mode. The problem is basically cookie related. This way we lose some features in private browsing mode, but we ensure PRIVACY! This change cannot be reverted until a proper fix for KIO (or the right workaround for rekonq) will be found. BUG: 303552 --- src/webwindow/webwindow.cpp | 18 ++---------------- 1 file changed, 2 insertions(+), 16 deletions(-) (limited to 'src/webwindow/webwindow.cpp') diff --git a/src/webwindow/webwindow.cpp b/src/webwindow/webwindow.cpp index 616ccc69..74d1eda7 100644 --- a/src/webwindow/webwindow.cpp +++ b/src/webwindow/webwindow.cpp @@ -70,9 +70,9 @@ #include -WebWindow::WebWindow(QWidget *parent, WebPage *pg) +WebWindow::WebWindow(QWidget *parent, bool isPrivateBrowsing, WebPage *pg) : QWidget(parent) - , _tab(new WebTab(this)) + , _tab(new WebTab(this, isPrivateBrowsing)) , _bar(new UrlBar(_tab)) , _mainToolBar(0) , m_findBar(new FindBar(this)) @@ -81,7 +81,6 @@ WebWindow::WebWindow(QWidget *parent, WebPage *pg) , m_popup(new QLabel(this)) , m_hidePopupTimer(new QTimer(this)) , _ac(new KActionCollection(this)) - , _isPrivateBrowsing(false) { if (pg) { @@ -897,19 +896,6 @@ void WebWindow::toggleBookmarksToolbar(bool b) } -bool WebWindow::isPrivateBrowsing() -{ - return _isPrivateBrowsing; -} - - -void WebWindow::setPrivateBrowsing(bool on) -{ - _tab->page()->settings()->setAttribute(QWebSettings::PrivateBrowsingEnabled, on); - _isPrivateBrowsing = on; -} - - void WebWindow::showCrashMessageBar() { _tab->showCrashMessageBar(); -- cgit v1.2.1