Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(118)

Issue 149620: Use WebWidget from the WebKit API. This change also makes... (Closed)

Created:
11 years, 5 months ago by darin (slow to review)
Modified:
9 years, 7 months ago
Reviewers:
jam
CC:
chromium-reviews_googlegroups.com, John Grabowski, darin (slow to review), brettw, jam, Ben Goodger (Google)
Visibility:
Public.

Description

Use WebWidget from the WebKit API. This change also makes use of WebKitClient (replacing WebWidgetDelegate from glue). The ripple effects of this change are rather large, but most of the impact is mechanical. The more interesting changes include: 1- Removing the WebWidget parameter from WebWidgetClient methods. This didn't matter at all to RenderWidget or RenderView, but it did cause some changes to be made to TestWebViewDelegate. Now, it is not possible to share a delegate implementation for both the WebView and a popup menu, so I have a second instance of the delegate owned by TestShell for use with popup menus. 2- Plumbing WebNavigationPolicy in place of WindowOpenDisposition was getting to be a pretty large change, so I stopped short of deleting WindowOpenDisposition. That way the Chrome side can remain mostly unmodified. I then added a mapping function to convert from WebNavigationPolicy to WindowOpenDisposition. 3- The IME methods on WebWidget were renamed (reviewed separately by hbono), and there is now an enum to specify the composition command (WebCompositionCommand). 4- I added IPC serialization for WebCompositionCommand and WebTextDirection, which cleaned up some code that was just using ints in IPC messages. R=jam BUG=16234 TEST=none Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=20854

Patch Set 1 #

Patch Set 2 : '' #

Patch Set 3 : '' #

Patch Set 4 : '' #

Patch Set 5 : '' #

Patch Set 6 : '' #

Patch Set 7 : '' #

Patch Set 8 : '' #

Patch Set 9 : '' #

Patch Set 10 : '' #

Total comments: 4

Patch Set 11 : '' #

Patch Set 12 : '' #

Patch Set 13 : '' #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1060 lines, -1566 lines) Patch
M chrome/browser/renderer_host/render_widget_host.h View 1 2 3 4 5 6 7 8 9 10 11 12 5 chunks +5 lines, -5 lines 0 comments Download
M chrome/browser/renderer_host/render_widget_host.cc View 1 2 3 4 5 6 7 8 9 10 11 12 5 chunks +15 lines, -12 lines 0 comments Download
M chrome/browser/renderer_host/render_widget_host_view.h View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +0 lines, -1 line 0 comments Download
M chrome/browser/renderer_host/render_widget_host_view_gtk.cc View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/browser/renderer_host/render_widget_host_view_win.cc View 1 2 3 4 5 6 7 8 9 10 11 12 6 chunks +8 lines, -5 lines 0 comments Download
M chrome/common/render_messages_internal.h View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +4 lines, -11 lines 0 comments Download
M chrome/common/webkit_param_traits.h View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +38 lines, -0 lines 0 comments Download
M chrome/renderer/print_web_view_helper.h View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +13 lines, -22 lines 0 comments Download
M chrome/renderer/print_web_view_helper.cc View 1 2 3 4 5 6 7 8 9 10 11 12 6 chunks +22 lines, -15 lines 0 comments Download
M chrome/renderer/render_view.h View 1 2 3 4 5 6 7 8 9 10 11 12 6 chunks +15 lines, -12 lines 0 comments Download
M chrome/renderer/render_view.cc View 1 2 3 4 5 6 7 8 9 10 11 12 12 chunks +32 lines, -23 lines 0 comments Download
M chrome/renderer/render_view_unittest.cc View 3 4 5 6 7 8 9 10 11 12 3 chunks +23 lines, -7 lines 0 comments Download
M chrome/renderer/render_widget.h View 1 2 3 4 5 6 7 8 9 10 11 12 6 chunks +28 lines, -29 lines 0 comments Download
M chrome/renderer/render_widget.cc View 1 2 3 4 5 6 7 8 9 10 11 12 26 chunks +59 lines, -72 lines 0 comments Download
M webkit/api/public/WebCompositionCommand.h View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +3 lines, -5 lines 0 comments Download
M webkit/api/public/WebNavigationPolicy.h View 1 2 3 4 5 6 7 8 9 10 11 12 4 chunks +5 lines, -7 lines 0 comments Download
M webkit/api/public/WebPopupMenu.h View 1 2 3 4 5 6 7 8 9 10 11 12 4 chunks +6 lines, -5 lines 0 comments Download
M webkit/api/public/WebTextDirection.h View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +4 lines, -6 lines 0 comments Download
M webkit/api/public/WebWidget.h View 1 2 3 4 5 6 7 8 9 10 11 12 4 chunks +10 lines, -6 lines 0 comments Download
M webkit/api/public/WebWidgetClient.h View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +16 lines, -23 lines 0 comments Download
M webkit/glue/chrome_client_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 15 chunks +23 lines, -28 lines 0 comments Download
M webkit/glue/chromium_bridge_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 4 chunks +25 lines, -28 lines 0 comments Download
M webkit/glue/context_menu_unittest.cc View 3 4 5 6 7 8 9 10 11 12 1 chunk +2 lines, -2 lines 0 comments Download
M webkit/glue/inspector_client_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +1 line, -1 line 0 comments Download
M webkit/glue/webframeloaderclient_impl.h View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +7 lines, -12 lines 0 comments Download
M webkit/glue/webframeloaderclient_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 9 chunks +40 lines, -28 lines 0 comments Download
M webkit/glue/webplugin_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +2 lines, -2 lines 0 comments Download
A + webkit/glue/webpopupmenu_impl.h View 5 chunks +32 lines, -40 lines 0 comments Download
A + webkit/glue/webpopupmenu_impl.cc View 8 chunks +70 lines, -79 lines 0 comments Download
D webkit/glue/webtextdirection.h View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +0 lines, -22 lines 0 comments Download
M webkit/glue/webview.h View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +2 lines, -2 lines 0 comments Download
M webkit/glue/webview_delegate.h View 1 2 3 4 5 6 7 8 9 10 11 12 9 chunks +25 lines, -15 lines 0 comments Download
M webkit/glue/webview_impl.h View 1 2 3 4 5 6 7 8 9 10 11 12 5 chunks +26 lines, -25 lines 0 comments Download
M webkit/glue/webview_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 21 chunks +159 lines, -146 lines 0 comments Download
D webkit/glue/webwidget.h View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +0 lines, -80 lines 0 comments Download
D webkit/glue/webwidget_delegate.h View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +0 lines, -102 lines 0 comments Download
D webkit/glue/webwidget_impl.h View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +0 lines, -114 lines 0 comments Download
D webkit/glue/webwidget_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +0 lines, -279 lines 0 comments Download
M webkit/glue/webworker_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +21 lines, -24 lines 0 comments Download
M webkit/glue/window_open_disposition.h View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +8 lines, -0 lines 0 comments Download
A webkit/glue/window_open_disposition.cc View 1 chunk +43 lines, -0 lines 0 comments Download
M webkit/tools/test_shell/event_sending_controller.cc View 1 2 3 4 5 6 7 8 9 10 11 12 10 chunks +16 lines, -17 lines 0 comments Download
M webkit/tools/test_shell/mac/test_webview_delegate.mm View 1 2 3 4 5 6 7 8 9 10 11 12 7 chunks +28 lines, -32 lines 0 comments Download
M webkit/tools/test_shell/mac/webview_host.mm View 3 4 5 6 7 8 9 10 11 12 1 chunk +1 line, -1 line 0 comments Download
M webkit/tools/test_shell/mac/webwidget_host.mm View 3 4 5 6 7 8 9 10 11 12 8 chunks +15 lines, -16 lines 0 comments Download
M webkit/tools/test_shell/plugin_tests.cc View 4 5 6 7 8 9 10 11 12 1 chunk +1 line, -1 line 0 comments Download
M webkit/tools/test_shell/test_shell.h View 1 2 3 4 5 6 7 8 9 10 11 12 5 chunks +7 lines, -3 lines 0 comments Download
M webkit/tools/test_shell/test_shell.cc View 1 2 3 4 5 6 7 8 9 10 11 12 5 chunks +10 lines, -9 lines 0 comments Download
M webkit/tools/test_shell/test_shell_gtk.cc View 3 4 5 6 7 8 9 10 11 12 2 chunks +3 lines, -1 line 0 comments Download
M webkit/tools/test_shell/test_shell_mac.mm View 3 4 5 6 7 8 9 10 11 12 3 chunks +3 lines, -2 lines 0 comments Download
M webkit/tools/test_shell/test_shell_main.cc View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +1 line, -1 line 0 comments Download
M webkit/tools/test_shell/test_shell_test.cc View 4 5 6 7 8 9 10 11 12 1 chunk +1 line, -1 line 0 comments Download
M webkit/tools/test_shell/test_shell_win.cc View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +3 lines, -1 line 0 comments Download
M webkit/tools/test_shell/test_webview_delegate.h View 1 2 3 4 5 6 7 8 9 10 11 12 5 chunks +23 lines, -27 lines 0 comments Download
M webkit/tools/test_shell/test_webview_delegate.cc View 1 2 3 4 5 6 7 8 9 10 11 12 7 chunks +27 lines, -29 lines 0 comments Download
M webkit/tools/test_shell/test_webview_delegate_gtk.cc View 3 4 5 6 7 8 9 10 11 12 6 chunks +25 lines, -31 lines 0 comments Download
M webkit/tools/test_shell/test_webview_delegate_win.cc View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +54 lines, -55 lines 0 comments Download
M webkit/tools/test_shell/webview_host_gtk.cc View 1 chunk +1 line, -1 line 0 comments Download
M webkit/tools/test_shell/webwidget_host.h View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +5 lines, -6 lines 0 comments Download
M webkit/tools/test_shell/webwidget_host_gtk.cc View 10 11 12 12 chunks +19 lines, -19 lines 0 comments Download
M webkit/tools/test_shell/webwidget_host_win.cc View 1 2 3 4 5 6 7 8 9 10 11 12 8 chunks +15 lines, -12 lines 0 comments Download
M webkit/webkit.gyp View 1 2 3 4 5 6 7 8 9 10 11 12 5 chunks +8 lines, -4 lines 0 comments Download

Messages

Total messages: 6 (0 generated)
darin (slow to review)
11 years, 5 months ago (2009-07-15 17:32:35 UTC) #1
darin (slow to review)
11 years, 5 months ago (2009-07-15 17:49:57 UTC) #2
jam
lgtm http://codereview.chromium.org/149620/diff/1602/639 File chrome/browser/renderer_host/render_widget_host.cc (right): http://codereview.chromium.org/149620/diff/1602/639#newcode474 Line 474: ime_string)); nit: the style in this function ...
11 years, 5 months ago (2009-07-15 19:52:19 UTC) #3
darin (slow to review)
http://codereview.chromium.org/149620/diff/1602/643 File chrome/common/webkit_param_traits.h (right): http://codereview.chromium.org/149620/diff/1602/643#newcode100 Line 100: struct ParamTraits<WebKit::WebCompositionCommand> { yeah, i had the same ...
11 years, 5 months ago (2009-07-15 20:45:18 UTC) #4
jam
http://codereview.chromium.org/149620/diff/1602/643 File chrome/common/webkit_param_traits.h (right): http://codereview.chromium.org/149620/diff/1602/643#newcode100 Line 100: struct ParamTraits<WebKit::WebCompositionCommand> { On 2009/07/15 20:45:18, darin wrote: ...
11 years, 5 months ago (2009-07-15 21:54:48 UTC) #5
darin (slow to review)
11 years, 5 months ago (2009-07-15 22:18:34 UTC) #6
On Wed, Jul 15, 2009 at 2:54 PM, <jam@chromium.org> wrote:

>
> http://codereview.chromium.org/149620/diff/1602/643
> File chrome/common/webkit_param_traits.h (right):
>
> http://codereview.chromium.org/149620/diff/1602/643#newcode100
> Line 100: struct ParamTraits<WebKit::WebCompositionCommand> {
> On 2009/07/15 20:45:18, darin wrote:
>
>> yeah, i had the same thought... it is easy to do with a macro, but i
>>
> couldn't
>
>> find a non-macro way to do something more compact.  any ideas?
>>
>
>
> no not sure (mpcomplete's template fu is better than mine)
>
>  if i assume sizeof(int) == sizeof(param_type), then i could make the
>>
> Read
>
>> function one line.  that assumption is probably ok though it is not
>>
> required by
>
>> the spec.
>>
>
> do you mean by using reinterpret_cast?  from what I read, gcc will use
> 64 bits if there are negative + positive numbers.  so maybe it's just
> safer to leave the static_cast there sinec it'll cause this problem in
> the future (unless the static_cast in the Write function will catch it
> on its own)
>
>
> http://codereview.chromium.org/149620
>


I think there is probably a good cleanup task here to coalesce a bunch of
our
ParamTraits.  We have many others that are just for serializing enums.  I
filed
http://crbug.com/16866 for that.

-Darin

Powered by Google App Engine
This is Rietveld 408576698