https://bugs.webkit.org/show_bug.cgi?id=99204
authorbdakin@apple.com <bdakin@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 12 Oct 2012 20:50:36 +0000 (20:50 +0000)
committerbdakin@apple.com <bdakin@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 12 Oct 2012 20:50:36 +0000 (20:50 +0000)
commit017b0120994cde50f0035fc10e51695b77f02989
tree22d178378cb16dec50748c568a3b3cdfa3be528f
parentcd5a7fd3143c40e9bcbdab60323c8edf5e0dad70
https://bugs.webkit.org/show_bug.cgi?id=99204
ScrollingStateNodes should keep track of their IDs

Reviewed by Simon Fraser.

There is a HashMap in ScrollingCoordinatorMac that maps
ScrollingNodeIDs to ScrollingStateNodes. The nodes themselves should
keep track of this id. Then the id can be used to make sure
ScrollingStateNodes remove themselves from the HashMap when they are
destroyed, and it will also be useful for associating
ScrollingStateNodes with ScrollingTreeNodes over on the scrolling
thread.

This patch only has the ScrollingStateNodes cache the id. I will
actually make use of the id in follow-up patches.

* page/scrolling/ScrollingStateNode.cpp:
(WebCore::ScrollingStateNode::ScrollingStateNode):
* page/scrolling/ScrollingStateNode.h:
(ScrollingStateNode):
(WebCore::ScrollingStateNode::scrollingNodeID):
* page/scrolling/ScrollingStateScrollingNode.cpp:
(WebCore::ScrollingStateScrollingNode::create):
(WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
* page/scrolling/ScrollingStateScrollingNode.h:
(ScrollingStateScrollingNode):
* page/scrolling/mac/ScrollingCoordinatorMac.mm:
(WebCore::ScrollingCoordinatorMac::attachToStateTree):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@131221 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebCore/ChangeLog
Source/WebCore/page/scrolling/ScrollingStateNode.cpp
Source/WebCore/page/scrolling/ScrollingStateNode.h
Source/WebCore/page/scrolling/ScrollingStateScrollingNode.cpp
Source/WebCore/page/scrolling/ScrollingStateScrollingNode.h
Source/WebCore/page/scrolling/mac/ScrollingCoordinatorMac.mm