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

Side by Side Diff: chrome/browser/ui/gtk/find_bar_gtk.cc

Issue 177863007: Replace WebDocument::clearfocusedNode to clearFocusedElement (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebased with latest Created 6 years, 10 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 unified diff | Download patch
« no previous file with comments | « no previous file | chrome/browser/ui/views/find_bar_host.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/ui/gtk/find_bar_gtk.h" 5 #include "chrome/browser/ui/gtk/find_bar_gtk.h"
6 6
7 #include <gdk/gdkkeysyms.h> 7 #include <gdk/gdkkeysyms.h>
8 8
9 #include <algorithm> 9 #include <algorithm>
10 #include <string> 10 #include <string>
(...skipping 685 matching lines...) Expand 10 before | Expand all | Expand 10 after
696 } 696 }
697 697
698 content::WebContents* contents = find_bar_controller_->web_contents(); 698 content::WebContents* contents = find_bar_controller_->web_contents();
699 if (!contents) 699 if (!contents)
700 return false; 700 return false;
701 701
702 content::RenderViewHost* render_view_host = contents->GetRenderViewHost(); 702 content::RenderViewHost* render_view_host = contents->GetRenderViewHost();
703 703
704 // Make sure we don't have a text field element interfering with keyboard 704 // Make sure we don't have a text field element interfering with keyboard
705 // input. Otherwise Up and Down arrow key strokes get eaten. "Nom Nom Nom". 705 // input. Otherwise Up and Down arrow key strokes get eaten. "Nom Nom Nom".
706 render_view_host->ClearFocusedNode(); 706 render_view_host->ClearFocusedElement();
707 707
708 NativeWebKeyboardEvent wke(reinterpret_cast<GdkEvent*>(event)); 708 NativeWebKeyboardEvent wke(reinterpret_cast<GdkEvent*>(event));
709 render_view_host->ForwardKeyboardEvent(wke); 709 render_view_host->ForwardKeyboardEvent(wke);
710 return true; 710 return true;
711 } 711 }
712 712
713 void FindBarGtk::AdjustTextAlignment() { 713 void FindBarGtk::AdjustTextAlignment() {
714 PangoDirection content_dir = 714 PangoDirection content_dir =
715 pango_find_base_dir(gtk_entry_get_text(GTK_ENTRY(text_entry_)), -1); 715 pango_find_base_dir(gtk_entry_get_text(GTK_ENTRY(text_entry_)), -1);
716 716
(...skipping 316 matching lines...) Expand 10 before | Expand all | Expand 10 after
1033 return FALSE; // Continue propagation. 1033 return FALSE; // Continue propagation.
1034 } 1034 }
1035 1035
1036 gboolean FindBarGtk::OnFocusOut(GtkWidget* entry, GdkEventFocus* event) { 1036 gboolean FindBarGtk::OnFocusOut(GtkWidget* entry, GdkEventFocus* event) {
1037 g_signal_handlers_disconnect_by_func( 1037 g_signal_handlers_disconnect_by_func(
1038 gdk_keymap_get_for_display(gtk_widget_get_display(entry)), 1038 gdk_keymap_get_for_display(gtk_widget_get_display(entry)),
1039 reinterpret_cast<gpointer>(&OnKeymapDirectionChanged), this); 1039 reinterpret_cast<gpointer>(&OnKeymapDirectionChanged), this);
1040 1040
1041 return FALSE; // Continue propagation. 1041 return FALSE; // Continue propagation.
1042 } 1042 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/views/find_bar_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698