Find now uses WebKit's TextMatch highlighting for Find-in-page.
commit884db41554423ec017c57709f92cc2379e0cc02d
authorfinnur@google.com <finnur@google.com@0039d316-1c4b-4281-b951-d872f2087c98>
Mon, 24 Nov 2008 23:46:50 +0000 (24 23:46 +0000)
committerfinnur@google.com <finnur@google.com@0039d316-1c4b-4281-b951-d872f2087c98>
Mon, 24 Nov 2008 23:46:50 +0000 (24 23:46 +0000)
tree275e81e0c6ab0717912dd4864d91ad719bd2a55c
parent498c1a6b2dc98869e0703127565247830227d075
Find now uses WebKit's TextMatch highlighting for Find-in-page.

This allows us to discard a bunch of code and plumbing related to
maintaining and passing around the tickmark vector.

WebKit now owns the drawing of the highlights for inactive matches and
we use the selection controller to draw the active highlight.

I also simplified the code by eliminating the separate FindNext
function, which has been merged into Find.

This change also requires minor changes to WebKit upstream (sold
seperately, void where prohibited).

It simply consists of adding one empty virtual paint function to
ScrollbarThemeComposite.h (paintTickmarks) and in
ScrollbarThemeComposite::paint call paintTickmarks().

This fixes/makes obsolete a slew of bugs:

BUG=13263991241554,114399110701901023019, 984786, 893737, 868599
... and a couple of external ones as well. Full list:

1326399 Find highlighting disappears on ThinkPad x60s
1241554 Find doesn't highlight word inside blinky tag
1143991 Have find-in-page code use skia and have inspected node highlighting set the right xfermode
1070190 Find should begin searching from caret/selection
1023019 Find not highlighting correctly
984786  Find highlight drawing code causes ClearType text to look bad
893737  Find in page should search textareas
868599  Find in page tick marks incorrectly appear on nested scrollbars
298 Find-In-page should highlight elided entries
4389    Find-in-box is not highlighting all the instances of the search word
3908    Find in page highlighting and tickmarks are broken

Review URL: http://codereview.chromium.org/11364

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@5946 0039d316-1c4b-4281-b951-d872f2087c98
12 files changed:
DEPS
chrome/renderer/render_view.cc
webkit/glue/webframe.h
webkit/glue/webframe_impl.cc
webkit/glue/webframe_impl.h
webkit/glue/webview_impl.cc
webkit/glue/webview_impl.h
webkit/glue/webwidget_impl.cc
webkit/port/platform/chromium/ScrollbarThemeChromium.cpp
webkit/port/platform/chromium/ScrollbarThemeChromium.h
webkit/port/rendering/RenderThemeWin.cpp
webkit/port/rendering/RenderThemeWin.h