| OLD | NEW |
| 1 // Copyright (c) 2006-2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2009 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/views/find_bar_host.h" | 5 #include "chrome/browser/views/find_bar_host.h" |
| 6 | 6 |
| 7 #include "chrome/browser/find_bar_controller.h" | 7 #include "chrome/browser/find_bar_controller.h" |
| 8 #include "chrome/browser/renderer_host/render_view_host.h" | 8 #include "chrome/browser/renderer_host/render_view_host.h" |
| 9 #include "chrome/browser/tab_contents/tab_contents.h" | 9 #include "chrome/browser/tab_contents/tab_contents.h" |
| 10 #include "chrome/browser/tab_contents/tab_contents_view.h" | 10 #include "chrome/browser/tab_contents/tab_contents_view.h" |
| (...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 182 ::GetWindowRect( | 182 ::GetWindowRect( |
| 183 find_bar_controller_->tab_contents()->view()->GetNativeView(), | 183 find_bar_controller_->tab_contents()->view()->GetNativeView(), |
| 184 &webcontents_rect); | 184 &webcontents_rect); |
| 185 avoid_overlapping_rect->Offset(0, webcontents_rect.top - frame_rect.top); | 185 avoid_overlapping_rect->Offset(0, webcontents_rect.top - frame_rect.top); |
| 186 } | 186 } |
| 187 | 187 |
| 188 gfx::NativeView FindBarHost::GetNativeView(BrowserView* browser_view) { | 188 gfx::NativeView FindBarHost::GetNativeView(BrowserView* browser_view) { |
| 189 return browser_view->GetWidget()->GetNativeView(); | 189 return browser_view->GetWidget()->GetNativeView(); |
| 190 } | 190 } |
| 191 | 191 |
| 192 bool FindBarHost::ShouldForwardKeystrokeToWebpageNative( |
| 193 const views::Textfield::Keystroke& key_stroke) { |
| 194 // We specifically ignore WM_CHAR. See http://crbug.com/10509. |
| 195 return key_stroke.message() == WM_KEYDOWN || key_stroke.message() == WM_KEYUP; |
| 196 } |
| 197 |
| OLD | NEW |