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

Unified Diff: chrome/browser/renderer_host/render_widget_host_view_gtk.cc

Issue 361034: Tell the RWH about the intial window size for drop down menus. (Closed)
Patch Set: Created 11 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/renderer_host/render_widget_host_view_gtk.cc
diff --git a/chrome/browser/renderer_host/render_widget_host_view_gtk.cc b/chrome/browser/renderer_host/render_widget_host_view_gtk.cc
index 939c8f136ab60865f98fe4f28dd65dcdaaefe5e2..b54aba3e9e2749c8fe9e96e301162ee6495189f7 100644
--- a/chrome/browser/renderer_host/render_widget_host_view_gtk.cc
+++ b/chrome/browser/renderer_host/render_widget_host_view_gtk.cc
@@ -358,9 +358,11 @@ void RenderWidgetHostViewGtk::InitAsPopup(
parent_host_view->Blur();
}
- gtk_widget_set_size_request(view_.get(),
- std::min(pos.width(), kMaxWindowWidth),
+ requested_size_ = gfx::Size(std::min(pos.width(), kMaxWindowWidth),
std::min(pos.height(), kMaxWindowHeight));
+ host_->WasResized();
+ gtk_widget_set_size_request(view_.get(), requested_size_.width(),
+ requested_size_.height());
gtk_window_set_default_size(GTK_WINDOW(popup), -1, -1);
// Don't allow the window to be resized. This also forces the window to
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698