Bug 116703

Summary: Typing in Safari's unified field causes unnecessary web content repaints.
Product: WebKit Reporter: Andreas Kling <kling>
Component: WebCore Misc.Assignee: Andreas Kling <kling>
Status: RESOLVED FIXED    
Severity: Normal CC: commit-queue
Priority: P2 Keywords: Performance
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch none

Description Andreas Kling 2013-05-23 23:08:22 PDT
Typing in Safari's unified field causes unnecessary web content repaints.
Comment 1 Andreas Kling 2013-05-23 23:09:30 PDT
Created attachment 202768 [details]
Patch

Give WebCore::Page the ability to count the number of times a string occurs in the page without painting anything.
Comment 2 Andy Estes 2013-05-23 23:36:40 PDT
Comment on attachment 202768 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=202768&action=review

r=me. Looks like this is covered by the WebKit2.Find API test, so I assume this test still passes after this change.

> Source/WebCore/page/Page.h:414
> +    unsigned findMatchesForText(const String&, FindOptions, unsigned maxMatchCount, bool shouldHighlight, bool markMatches);

You could use enums for shouldHighlight and markMatches for some added readability at call sites of this function.
Comment 3 WebKit Commit Bot 2013-05-24 00:11:58 PDT
Comment on attachment 202768 [details]
Patch

Clearing flags on attachment: 202768

Committed r150633: <http://trac.webkit.org/changeset/150633>
Comment 4 WebKit Commit Bot 2013-05-24 00:12:00 PDT
All reviewed patches have been landed.  Closing bug.