Web Inspector: do not use inspector cookie in InspectorInstrumentation::{will,did}Paint
https://bugs.webkit.org/show_bug.cgi?id=112787

Reviewed by Pavel Feldman.

- pass frame, not inspector cookie to InspectorInstrumentation::didPaint;
- use frame to determine timeline agent in InspectorInstrumentation::didPaint.

* inspector/InspectorInstrumentation.cpp:
(WebCore):
(WebCore::InspectorInstrumentation::willPaintImpl):
(WebCore::InspectorInstrumentation::didPaintImpl):
* inspector/InspectorInstrumentation.h:
(InspectorInstrumentation):
(WebCore::InspectorInstrumentation::willPaint):
(WebCore::InspectorInstrumentation::didPaint):
* page/FrameView.cpp:
(WebCore::FrameView::paintContents):
* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::paintContents):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@146475 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Web Inspector: Paint rectangles shown on hover over Timeline's paint records occasionally have wrong offsets
https://bugs.webkit.org/show_bug.cgi?id=112371

Reviewed by Pavel Feldman.

Source/WebCore:

- pass frame to InspectorTimelineAgent::didPaint();
- convert paint coordinates to root view.

* inspector/InspectorInstrumentation.cpp:
(WebCore):
(WebCore::InspectorInstrumentation::willPaintImpl):
(WebCore::InspectorInstrumentation::didPaintImpl):
* inspector/InspectorInstrumentation.h:
(InspectorInstrumentation):
(WebCore::InspectorInstrumentation::willPaint):
(WebCore::InspectorInstrumentation::didPaint):
* inspector/InspectorTimelineAgent.cpp:
(WebCore::InspectorTimelineAgent::didPaint):
* inspector/InspectorTimelineAgent.h:
(InspectorTimelineAgent):

LayoutTests:

* http/tests/inspector/timeline-test.js:
(initialize_Timeline.InspectorTest.startTimeline.InspectorTest._addTimelineEvent):
(initialize_Timeline.InspectorTest.startTimeline):
(initialize_Timeline.addEvent):
(initialize_Timeline.addRecord):
(initialize_Timeline.InspectorTest.waitForRecordType):
(initialize_Timeline.InspectorTest.stopTimeline):
* inspector/timeline/timeline-paint-expected.txt:
* inspector/timeline/timeline-paint.html:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@146476 268f45cc-cd09-0410-ab3c-d52691b4dbfc