From d9028baf5c8261cbad540893465965730386a1cf Mon Sep 17 00:00:00 2001 From: Benjamin Poulain Date: Wed, 18 Aug 2010 03:32:50 +0200 Subject: Split AdBlock rule in two classes to move the implementation out of it In order to make special matching rules, we need specialization of the implementation depending on the type of rule. The previous AdBlockRule was entierly based on regexp. The new one is only a factory to a AdBlockRuleImpl, and delegate everything to this implementation. This will allow faster specialization of the ad block rules in the future. --- src/CMakeLists.txt | 1 + 1 file changed, 1 insertion(+) (limited to 'src/CMakeLists.txt') diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 46e9240c..8f4ac651 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -53,6 +53,7 @@ SET( rekonq_KDEINIT_SRCS adblock/adblockmanager.cpp adblock/adblocknetworkreply.cpp adblock/adblockrule.cpp + adblock/adblockrulefallbackimpl.cpp #---------------------------------------- urlbar/stackedurlbar.cpp urlbar/urlbar.cpp -- cgit v1.2.1 From 95c71246916f0986101f08ee362429b505cbcd3d Mon Sep 17 00:00:00 2001 From: Benjamin Poulain Date: Wed, 18 Aug 2010 04:44:22 +0200 Subject: Add a primitive text machter as an AdBlockRule implementations About 30% of the filter of easylist are just simple text matching. This new AdBlockRule implementation detects the simple occurences of this to match the url directly. On Qt 4.7, this reduce the time spend in AdBlock by around 20%. --- src/CMakeLists.txt | 1 + 1 file changed, 1 insertion(+) (limited to 'src/CMakeLists.txt') diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 8f4ac651..127c1c4f 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -54,6 +54,7 @@ SET( rekonq_KDEINIT_SRCS adblock/adblocknetworkreply.cpp adblock/adblockrule.cpp adblock/adblockrulefallbackimpl.cpp + adblock/adblockruletextmatchimpl.cpp #---------------------------------------- urlbar/stackedurlbar.cpp urlbar/urlbar.cpp -- cgit v1.2.1