Index: chrome/browser/ui/libgtk2ui/gtk2_key_bindings_handler.cc |
diff --git a/chrome/browser/ui/libgtk2ui/gtk2_key_bindings_handler.cc b/chrome/browser/ui/libgtk2ui/gtk2_key_bindings_handler.cc |
index eec9dde2d6dbdf5787e391e62508b9bfcb3d2c51..aad16ccddc24e22da85396a93a6cebf846ad26cb 100644 |
--- a/chrome/browser/ui/libgtk2ui/gtk2_key_bindings_handler.cc |
+++ b/chrome/browser/ui/libgtk2ui/gtk2_key_bindings_handler.cc |
@@ -61,7 +61,14 @@ bool Gtk2KeyBindingsHandler::MatchEvent( |
edit_commands_.clear(); |
// If this key event matches a predefined key binding, corresponding signal |
// will be emitted. |
- gtk_bindings_activate_event(GTK_OBJECT(handler_.get()), &gdk_event); |
+ |
+ gtk_bindings_activate_event( |
+#if GDK_MAJOR_VERSION >= 3 |
+ G_OBJECT(handler_.get()), |
+#else |
+ GTK_OBJECT(handler_.get()), |
+#endif |
+ &gdk_event); |
bool matched = !edit_commands_.empty(); |
if (edit_commands) |
@@ -123,7 +130,7 @@ void Gtk2KeyBindingsHandler::BuildGdkEventKeyFromXEvent( |
gdk_event->group = 0; |
} |
- gdk_event->keyval = GDK_VoidSymbol; |
+ gdk_event->keyval = GDK_KEY_VoidSymbol; |
gdk_keymap_translate_keyboard_state( |
keymap, |
gdk_event->hardware_keycode, |