Fix for <rdar://problem/8895140> Adopt WKScrollbar metrics
authorbdakin@apple.com <bdakin@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 27 Jan 2011 04:08:49 +0000 (04:08 +0000)
committerbdakin@apple.com <bdakin@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 27 Jan 2011 04:08:49 +0000 (04:08 +0000)
commit91f6e83bbe7862f8d5119c51c4039e03f1414dbc
treeeb614490ce3cd922e69c1af476304cb6c32a0b4c
parent94235eb2e88290ee992641d4a1c863e416ad1f95
Fix for <rdar://problem/8895140> Adopt WKScrollbar metrics
when using WKScrollbars.

Reviewed by Darin Adler.

Source/WebCore:

New WebKitSystemInterface Functionality.
* WebCore.exp.in:
* platform/mac/WebCoreSystemInterface.h:
* platform/mac/WebCoreSystemInterface.mm:

Some of the terrible static arrays are now only needed in the
old non-WK code, so they are if-def'd now.
* platform/mac/ScrollbarThemeMac.mm:

Just patching this function in a better way than I did
before.
(WebCore::updateArrowPlacement):

Call into WK for the right values.
(WebCore::ScrollbarThemeMac::scrollbarThickness):
(WebCore::ScrollbarThemeMac::hasThumb):
(WebCore::ScrollbarThemeMac::minimumThumbLength):

Return false if there are no buttons.
(WebCore::ScrollbarThemeMac::hasButtons):

Return an empty IntRect if there are not buttons.
(WebCore::buttonRepaintRect):

Source/WebKit/mac:

* WebCoreSupport/WebSystemInterface.mm:
(InitWebCoreSystemInterface):

Source/WebKit2:

* WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
(InitWebCoreSystemInterface):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@76754 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebCore/ChangeLog
Source/WebCore/WebCore.exp.in
Source/WebCore/platform/mac/ScrollbarThemeMac.mm
Source/WebCore/platform/mac/WebCoreSystemInterface.h
Source/WebCore/platform/mac/WebCoreSystemInterface.mm
Source/WebKit/mac/ChangeLog
Source/WebKit/mac/WebCoreSupport/WebSystemInterface.mm
Source/WebKit2/ChangeLog
Source/WebKit2/WebProcess/WebCoreSupport/mac/WebSystemInterface.mm