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

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

Issue 7484035: Reapplies r91761. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 5 months 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 | « chrome/browser/renderer_host/gtk_key_bindings_handler.cc ('k') | chrome/browser/ui/browser_list_gtk.cc » ('j') | 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 f5274bb5fe4004c71bbda44df671cfc803161a21..4e52393e668ff1bbf93d5a963eed41e257c4b6e9 100644
--- a/chrome/browser/renderer_host/render_widget_host_view_gtk.cc
+++ b/chrome/browser/renderer_host/render_widget_host_view_gtk.cc
@@ -120,7 +120,7 @@ class RenderWidgetHostViewGtkWidget {
GDK_FOCUS_CHANGE_MASK |
GDK_ENTER_NOTIFY_MASK |
GDK_LEAVE_NOTIFY_MASK);
- GTK_WIDGET_SET_FLAGS(widget, GTK_CAN_FOCUS);
+ gtk_widget_set_can_focus(widget, TRUE);
g_signal_connect(widget, "expose-event",
G_CALLBACK(OnExposeEvent), host_view);
@@ -322,7 +322,7 @@ class RenderWidgetHostViewGtkWidget {
// TODO(evanm): why is this necessary here but not in test shell?
// This logic is the same as GtkButton.
- if (event->type == GDK_BUTTON_PRESS && !GTK_WIDGET_HAS_FOCUS(widget))
+ if (event->type == GDK_BUTTON_PRESS && !gtk_widget_has_focus(widget))
gtk_widget_grab_focus(widget);
host_view->is_popup_first_mouse_release_ = false;
@@ -696,8 +696,7 @@ void RenderWidgetHostViewGtk::Hide() {
}
bool RenderWidgetHostViewGtk::IsShowing() {
- // TODO(jcivelli): use gtk_widget_get_visible once we build with GTK 2.18.
- return (GTK_WIDGET_FLAGS(view_.get()) & GTK_VISIBLE) != 0;
+ return gtk_widget_get_visible(view_.get());
}
gfx::Rect RenderWidgetHostViewGtk::GetViewBounds() const {
« no previous file with comments | « chrome/browser/renderer_host/gtk_key_bindings_handler.cc ('k') | chrome/browser/ui/browser_list_gtk.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698