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

Issue 126107: Creates a new TabContentsViewGtk for views based FE. (Closed)

Created:
11 years, 6 months ago by Ben Goodger (Google)
Modified:
9 years, 6 months ago
Reviewers:
sky
CC:
chromium-reviews_googlegroups.com
Visibility:
Public.

Description

Fix build bustage by removing another dependency on browser/gtk by creating a new TabContentsViewGtk specifically for views. This subclasses WidgetGtk similar to how TabContentsViewWin subclasses WidgetWin. There was a bug in NativeViewHostGtk - reparenting needs to be done atomically using gtk_widget_reparent since GtkWidgets are refcounted and when removed from a container are released, causing a crash when a TabContents is reparented. The code now compiles thanks to a stubbed BlockedPopupContainer, however there is one remaining issue - the browser window no longer paints and the app instantly hangs. However this is better than the current state so I figured I'd send the code review. Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=18588

Patch Set 1 #

Patch Set 2 : '' #

Patch Set 3 : '' #

Patch Set 4 : '' #

Patch Set 5 : '' #

Total comments: 4
Unified diffs Side-by-side diffs Delta from patch set Stats (+527 lines, -106 lines) Patch
M chrome/browser/views/tab_contents/render_view_context_menu_win.h View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
A chrome/browser/views/tab_contents/tab_contents_view_gtk.h View 1 2 3 1 chunk +86 lines, -0 lines 0 comments Download
A chrome/browser/views/tab_contents/tab_contents_view_gtk.cc View 1 2 3 1 chunk +322 lines, -0 lines 0 comments Download
M chrome/chrome.gyp View 1 2 3 3 chunks +13 lines, -0 lines 0 comments Download
MM views/controls/button/native_button_gtk.h View 1 chunk +1 line, -1 line 0 comments Download
MM views/controls/button/native_button_gtk.cc View 2 chunks +3 lines, -5 lines 0 comments Download
MM views/controls/native/native_view_host_gtk.h View 2 chunks +1 line, -6 lines 0 comments Download
M views/controls/native/native_view_host_gtk.cc View 3 4 chunks +16 lines, -42 lines 1 comment Download
MM views/widget/widget_gtk.h View 2 3 4 3 chunks +25 lines, -7 lines 1 comment Download
M views/widget/widget_gtk.cc View 2 3 4 14 chunks +59 lines, -44 lines 2 comments Download

Messages

Total messages: 3 (0 generated)
Ben Goodger (Google)
11 years, 6 months ago (2009-06-16 11:35:30 UTC) #1
sky
http://codereview.chromium.org/126107/diff/38/45 File views/controls/native/native_view_host_gtk.cc (right): http://codereview.chromium.org/126107/diff/38/45#newcode33 Line 33: if (gtk_widget_get_parent(host_->native_view())) { NOTE: rather than invoking ReparentChild ...
11 years, 6 months ago (2009-06-16 16:01:45 UTC) #2
Ben Goodger (Google)
11 years, 6 months ago (2009-06-16 19:53:46 UTC) #3
http://codereview.chromium.org/126107/diff/38/43
File views/widget/widget_gtk.cc (right):

http://codereview.chromium.org/126107/diff/38/43#newcode178
Line 178: bounds.width(), bounds.height());
On 2009/06/16 16:01:45, sky wrote:
> I think you need to persist the bounds some how, otherwise Show won't know
what
> bounds to show the widget at.

It seems like the bounds setting will be done when the GtkWidget corresponding
to this WidgetGtk is attached to a NativeViewHost - the NativeViewHosts' bounds
will be applied.

Powered by Google App Engine
This is Rietveld 408576698