From c90f0af043e3691d194f04e416e4d7b8a115437b Mon Sep 17 00:00:00 2001 From: Andrea Diamantini Date: Wed, 24 Feb 2010 16:30:17 +0100 Subject: Remember "Never for this site" urls Also if I think this is NOT a proper solution.. BUG:227651 --- src/rekonq.kcfg | 3 +++ src/walletbar.cpp | 9 ++++++++- src/webtab.cpp | 8 +++++++- 3 files changed, 18 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/rekonq.kcfg b/src/rekonq.kcfg index 77d66628..0675720c 100644 --- a/src/rekonq.kcfg +++ b/src/rekonq.kcfg @@ -22,6 +22,9 @@ false + + + diff --git a/src/walletbar.cpp b/src/walletbar.cpp index c5d705e0..5b911585 100644 --- a/src/walletbar.cpp +++ b/src/walletbar.cpp @@ -28,6 +28,9 @@ #include "walletbar.h" #include "walletbar.moc" +// Auto Includes +#include "rekonq.h" + // KDE Includes #include #include @@ -85,7 +88,11 @@ void WalletBar::rememberData() void WalletBar::neverRememberData() { - // TODO: store site url (to remember never bother about) + // add url to the blacklist + QStringList list = ReKonfig::walletBlackList(); + list << m_url.toString(); + ReKonfig::setWalletBlackList( list ); + notNowRememberData(); } diff --git a/src/webtab.cpp b/src/webtab.cpp index 645c9606..b4759995 100644 --- a/src/webtab.cpp +++ b/src/webtab.cpp @@ -141,7 +141,13 @@ void WebTab::loadFinished(bool) void WebTab::createWalletBar(const QString &key, const QUrl &url) -{ +{ + // check if the url is in the wallet blacklist + QString urlString = url.toString(); + QStringList blackList = ReKonfig::walletBlackList(); + if( blackList.contains( urlString ) ) + return; + KWebWallet *wallet = page()->wallet(); QWidget *messageBar = layout()->itemAt(0)->widget(); -- cgit v1.2.1