DescriptionIssue #2230 - Refactor filter life cycle and use
Remove "CPluginTab::m_traverser" and replace it with an object constructed at
the point of traversal. Remove "CPluginTraverserBase::ClearCache()". Because
traverser object are now used only once, there's no reason to reset their
state. Removed "isMainDoc" argument to 'TraverseDocument()', whose only
purpose was to guard a call to 'ClearCache()'.
Remove 'CAdblockPlusClient::IsElementHidden()'. It's only behavior over the
filter function of the same name was some unnecessary locking.
Change constructor argument for traverser classes from 'CPluginTab' to
'CPluginFilter'. These classes were only accessing the filter value.
Renamed the externally-visible version of 'TraverseDocument()' to
'TraverseDocumentRoot()'.
Remove 'TraverseHeader()' and 'TraverseSubdocument()', which were never
called. Remove 'm_isHeaderTraversed', now not assigned to anything after
initialization.
Remove traverser members 'm_cacheDomElementCount' and 'm_pBrowser', neither of
which was referenced.
--------
Other reviews depend on this one:
Load filters on "download begin" event
https://codereview.adblockplus.org/29334397/
Patch Set 1 #Patch Set 2 : rebase only #
MessagesTotal messages: 6
|