RESOLVED FIXED 109125
[chromium] Clean up WebWidget / WebLayerTreeView interactions
https://bugs.webkit.org/show_bug.cgi?id=109125
Summary [chromium] Clean up WebWidget / WebLayerTreeView interactions
James Robinson
Reported 2013-02-06 18:41:37 PST
[chromium] Clean up WebWidget / WebLayerTreeView interactions
Attachments
Patch (26.08 KB, patch)
2013-02-06 18:42 PST, James Robinson
no flags
Patch (26.94 KB, patch)
2013-02-21 15:39 PST, James Robinson
no flags
Patch (27.21 KB, patch)
2013-02-28 17:11 PST, James Robinson
no flags
more fixups to ScrollingCoordinatorChromiumTest (28.99 KB, patch)
2013-02-28 17:15 PST, James Robinson
no flags
fix WebTestProxy compilation (29.68 KB, patch)
2013-03-01 18:49 PST, James Robinson
no flags
rebased (29.71 KB, patch)
2013-03-04 14:42 PST, James Robinson
no flags
James Robinson
Comment 1 2013-02-06 18:42:03 PST
James Robinson
Comment 2 2013-02-06 18:51:17 PST
This probably doesn't even compile by itself. In conjunction with https://codereview.chromium.org/12226051, chrome itself seems to work fine but some WebKit-side tests don't. The goals of this patch are in the chromium-side codereview's description.
James Robinson
Comment 3 2013-02-06 18:54:19 PST
Comment on attachment 186975 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=186975&action=review > Source/WebKit/chromium/public/WebWidget.h:256 > + // Instrumentation method that marks beginning of frame update that includes > + // things like animate()/layout()/paint(). > + virtual void instrumentBeginFrame() { instrumentWillBeginFrame(); } > + > + // instrumentWillBeginFrame will be followed by either > + // instrumentDidBeginFrame or instrumentDidCancelFrame. > + virtual void instrumentWillBeginFrame() { } > + virtual void instrumentDidCancelFrame() { } > + virtual void instrumentDidBeginFrame() { } > + virtual void instrumentWillComposite() { } caseq/pfeldman: I'm not super happy about these calls being on WebWidget, but I'm not sure exactly what to do. The basic issue here is that the inspector instrumentation wants to know about steps in the compositing process, but other than these calls WebKit doesn't have any involvement with these steps. InspectorInstrumentation doesn't appear to be exposed directly. I could add add these calls to WebWidget as this patch does but it's fairly ugly. I could also add another tear-off interface, or perhaps put these on WebDevToolsAgent which hangs off of WebView. Logically these steps can apply to any WebWidget but I think WebViews are the only sorts of Widgets that the inspector can collect timeline data for.
WebKit Review Bot
Comment 4 2013-02-06 19:14:23 PST
Please wait for approval from abarth@webkit.org, dglazkov@chromium.org, fishd@chromium.org, jamesr@chromium.org or tkent@chromium.org before submitting, as this patch contains changes to the Chromium public API. See also https://trac.webkit.org/wiki/ChromiumWebKitAPI.
Peter Beverloo (cr-android ews)
Comment 5 2013-02-06 19:49:33 PST
Comment on attachment 186975 [details] Patch Attachment 186975 [details] did not pass cr-android-ews (chromium-android): Output: http://queues.webkit.org/results/16408029
WebKit Review Bot
Comment 6 2013-02-06 19:54:58 PST
Comment on attachment 186975 [details] Patch Attachment 186975 [details] did not pass cr-linux-debug-ews (chromium-xvfb): Output: http://queues.webkit.org/results/16404050
WebKit Review Bot
Comment 7 2013-02-07 06:11:50 PST
Comment on attachment 186975 [details] Patch Attachment 186975 [details] did not pass chromium-ews (chromium-xvfb): Output: http://queues.webkit.org/results/16435152
Andrey Kosyakov
Comment 8 2013-02-07 07:56:01 PST
Comment on attachment 186975 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=186975&action=review >> Source/WebKit/chromium/public/WebWidget.h:256 >> + virtual void instrumentWillComposite() { } > > caseq/pfeldman: I'm not super happy about these calls being on WebWidget, but I'm not sure exactly what to do. The basic issue here is that the inspector instrumentation wants to know about steps in the compositing process, but other than these calls WebKit doesn't have any involvement with these steps. InspectorInstrumentation doesn't appear to be exposed directly. I could add add these calls to WebWidget as this patch does but it's fairly ugly. I could also add another tear-off interface, or perhaps put these on WebDevToolsAgent which hangs off of WebView. Logically these steps can apply to any WebWidget but I think WebViews are the only sorts of Widgets that the inspector can collect timeline data for. We discussed it with Pavel and the consensus was that for the time being the best place for the methods would be on WebDevToolsAgent -- I can help with that if you like. Another idea that Nat proposed would be to use our emerging trace event based instrumentation, which would allow to cut down on plumbing quite a bit, but we thought it would perhaps be too early for it.
James Robinson
Comment 9 2013-02-21 15:39:41 PST
James Robinson
Comment 10 2013-02-21 15:41:17 PST
This patch passes layout and unit tests, but doesn't work entirely correctly (i.e. devtools instrumentation does not work as expected) without some chromium-side changes.
James Robinson
Comment 11 2013-02-28 17:11:15 PST
James Robinson
Comment 12 2013-02-28 17:14:04 PST
It's alive! This patch works. What it does is move the rest of the compositor-interaction responsibilies to WebWidget / WebWidgetClient and leaves WebLayerTreeViewClient as just a shell. Once this lands and the chromium side that moves calls over to the new interfaces, WebLayerTreeViewClient will go away completely. WebViewImpl (or other WebWidget implementations) will use WebWidgetClient for widget-specific compositor communication and use WebLayerTreeView to talk directly to the compositor implementation for things that aren't widget-specific.
James Robinson
Comment 13 2013-02-28 17:15:16 PST
Created attachment 190852 [details] more fixups to ScrollingCoordinatorChromiumTest
James Robinson
Comment 14 2013-02-28 17:50:58 PST
Oh - this also depends on https://codereview.chromium.org/12377029/ landing + rolling in to Source/WebKit/chromium/DEPS
WebKit Review Bot
Comment 15 2013-02-28 17:55:22 PST
Comment on attachment 190852 [details] more fixups to ScrollingCoordinatorChromiumTest Attachment 190852 [details] did not pass cr-linux-debug-ews (chromium-xvfb): Output: http://webkit-commit-queue.appspot.com/results/16822361
WebKit Review Bot
Comment 16 2013-02-28 17:56:43 PST
Comment on attachment 190852 [details] more fixups to ScrollingCoordinatorChromiumTest Attachment 190852 [details] did not pass chromium-ews (chromium-xvfb): Output: http://webkit-commit-queue.appspot.com/results/16863126
Peter Beverloo (cr-android ews)
Comment 17 2013-02-28 22:51:50 PST
Comment on attachment 190852 [details] more fixups to ScrollingCoordinatorChromiumTest Attachment 190852 [details] did not pass cr-android-ews (chromium-android): Output: http://webkit-commit-queue.appspot.com/results/16778589
James Robinson
Comment 18 2013-03-01 14:02:04 PST
Comment on attachment 190852 [details] more fixups to ScrollingCoordinatorChromiumTest View in context: https://bugs.webkit.org/attachment.cgi?id=190852&action=review > Source/Platform/chromium/public/WebLayerTreeViewClient.h:-76 > - virtual void scheduleComposite() = 0; I'll have to muck about with content shell a bit before deleting this virtual.
James Robinson
Comment 19 2013-03-01 18:49:25 PST
Created attachment 191089 [details] fix WebTestProxy compilation
James Robinson
Comment 20 2013-03-01 18:49:55 PST
This fixes the WebTestProxy compile
WebKit Review Bot
Comment 21 2013-03-01 18:58:22 PST
Comment on attachment 191089 [details] fix WebTestProxy compilation Attachment 191089 [details] did not pass chromium-ews (chromium-xvfb): Output: http://webkit-commit-queue.appspot.com/results/16885043
WebKit Review Bot
Comment 22 2013-03-01 19:03:49 PST
Comment on attachment 191089 [details] fix WebTestProxy compilation Attachment 191089 [details] did not pass cr-linux-debug-ews (chromium-xvfb): Output: http://webkit-commit-queue.appspot.com/results/16668335
James Robinson
Comment 23 2013-03-04 14:42:04 PST
James Robinson
Comment 24 2013-03-04 14:42:45 PST
This should build and work fine against current chromium. It deprecates the WebLayerTreeViewClient implementations in WebKit, but leaves them in place so the callers can be removed on the chromium side. Mind having a look, Enne?
Adrienne Walker
Comment 25 2013-03-04 15:37:53 PST
Comment on attachment 191315 [details] rebased View in context: https://bugs.webkit.org/attachment.cgi?id=191315&action=review R=me. > Source/WebKit/chromium/src/WebViewImpl.h:156 > + virtual WebInputHandler* createInputHandler() OVERRIDE; > + virtual void applyScrollAndScale(const WebSize&, float); Just a drive-by comment, but what's with the inconsistent use of OVERRIDE in this block if these are all WebWidget methods?
James Robinson
Comment 26 2013-03-04 15:45:05 PST
Comment on attachment 191315 [details] rebased View in context: https://bugs.webkit.org/attachment.cgi?id=191315&action=review >> Source/WebKit/chromium/src/WebViewImpl.h:156 >> + virtual void applyScrollAndScale(const WebSize&, float); > > Just a drive-by comment, but what's with the inconsistent use of OVERRIDE in this block if these are all WebWidget methods? No reason. I'll add OVERRIDES to the rest of this file as a style follow-up
WebKit Review Bot
Comment 27 2013-03-04 20:06:59 PST
Comment on attachment 191315 [details] rebased Attachment 191315 [details] did not pass chromium-ews (chromium-xvfb): Output: http://webkit-commit-queue.appspot.com/results/16986028 New failing tests: inspector/debugger/pause-in-internal-script.html
WebKit Review Bot
Comment 28 2013-03-05 11:09:04 PST
Comment on attachment 191315 [details] rebased Clearing flags on attachment: 191315 Committed r144784: <http://trac.webkit.org/changeset/144784>
WebKit Review Bot
Comment 29 2013-03-05 11:09:10 PST
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.