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

Side by Side Diff: chrome/browser/renderer_host/render_widget_host_view_win.cc

Issue 140023: Reverting 18872. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 11 years, 6 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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/renderer_host/render_widget_host_view_win.h" 5 #include "chrome/browser/renderer_host/render_widget_host_view_win.h"
6 6
7 #include "app/gfx/canvas.h" 7 #include "app/gfx/canvas.h"
8 #include "app/l10n_util.h" 8 #include "app/l10n_util.h"
9 #include "app/l10n_util_win.h" 9 #include "app/l10n_util_win.h"
10 #include "app/resource_bundle.h" 10 #include "app/resource_bundle.h"
(...skipping 388 matching lines...) Expand 10 before | Expand all | Expand 10 after
399 return parent; 399 return parent;
400 } 400 }
401 401
402 void RenderWidgetHostViewWin::Focus() { 402 void RenderWidgetHostViewWin::Focus() {
403 if (IsWindow()) 403 if (IsWindow())
404 SetFocus(); 404 SetFocus();
405 } 405 }
406 406
407 void RenderWidgetHostViewWin::Blur() { 407 void RenderWidgetHostViewWin::Blur() {
408 views::FocusManager* focus_manager = 408 views::FocusManager* focus_manager =
409 views::FocusManager::GetFocusManagerForNativeView(m_hWnd); 409 views::FocusManager::GetFocusManager(GetParent());
410 // We don't have a FocusManager if we are hidden. 410 // We don't have a FocusManager if we are hidden.
411 if (focus_manager && render_widget_host_->CanBlur()) 411 if (focus_manager && render_widget_host_->CanBlur())
412 focus_manager->ClearFocus(); 412 focus_manager->ClearFocus();
413 } 413 }
414 414
415 bool RenderWidgetHostViewWin::HasFocus() { 415 bool RenderWidgetHostViewWin::HasFocus() {
416 return ::GetFocus() == m_hWnd; 416 return ::GetFocus() == m_hWnd;
417 } 417 }
418 418
419 void RenderWidgetHostViewWin::Show() { 419 void RenderWidgetHostViewWin::Show() {
(...skipping 898 matching lines...) Expand 10 before | Expand all | Expand 10 after
1318 // WM_LBUTTONDOWN. 1318 // WM_LBUTTONDOWN.
1319 SetFocus(); 1319 SetFocus();
1320 } 1320 }
1321 } 1321 }
1322 1322
1323 void RenderWidgetHostViewWin::ShutdownHost() { 1323 void RenderWidgetHostViewWin::ShutdownHost() {
1324 shutdown_factory_.RevokeAll(); 1324 shutdown_factory_.RevokeAll();
1325 render_widget_host_->Shutdown(); 1325 render_widget_host_->Shutdown();
1326 // Do not touch any members at this point, |this| has been deleted. 1326 // Do not touch any members at this point, |this| has been deleted.
1327 } 1327 }
OLDNEW
« no previous file with comments | « chrome/browser/first_run_win.cc ('k') | chrome/browser/views/autocomplete/autocomplete_popup_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698