diff options
author | Andrea Diamantini <adjam7@gmail.com> | 2009-12-02 12:28:39 +0100 |
---|---|---|
committer | Andrea Diamantini <adjam7@gmail.com> | 2009-12-02 12:28:39 +0100 |
commit | b679535011c98e17c97c06c7079efb53f6d89769 (patch) | |
tree | f56150287d668e66abf4ad6b3fc64742b33906ba /src | |
parent | trade-off: speed vs mem saving. (diff) | |
download | rekonq-b679535011c98e17c97c06c7079efb53f6d89769.tar.xz |
push startup on disabled adblock (don't load filters)
Diffstat (limited to 'src')
-rw-r--r-- | src/adblock/adblockmanager.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/adblock/adblockmanager.cpp b/src/adblock/adblockmanager.cpp index bfdbd5ad..209c2ab0 100644 --- a/src/adblock/adblockmanager.cpp +++ b/src/adblock/adblockmanager.cpp @@ -66,6 +66,10 @@ void AdBlockManager::loadSettings() filterList.clear(); + // no need to load filters if adblock is not enabled :) + if(!_isAdblockEnabled) + return; + QMap<QString,QString> entryMap = cg.entryMap(); QMap<QString,QString>::ConstIterator it; for( it = entryMap.constBegin(); it != entryMap.constEnd(); ++it ) @@ -93,13 +97,12 @@ QNetworkReply *AdBlockManager::block(const QNetworkRequest &request) return 0; QString urlString = request.url().toString(); - kDebug() << "****************************** ADBLOCK: Matching url: "<< urlString; foreach(const AdBlockRule &filter, filterList) { if(filter.match(urlString)) { - kDebug() << "****ADBLOCK: Matched: **************************"; + kDebug() << "****ADBLOCK: Matched: ***********" << urlString; AdBlockNetworkReply *reply = new AdBlockNetworkReply(request, urlString, this); return reply; } |