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

Side by Side Diff: ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc

Issue 1139623003: Removes the redundant IMB::OnFocus call in DNWA::HandleNativeFocus(). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 7 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 | no next file » | 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 "ui/views/widget/desktop_aura/desktop_window_tree_host_win.h" 5 #include "ui/views/widget/desktop_aura/desktop_window_tree_host_win.h"
6 6
7 #include "base/win/metro.h" 7 #include "base/win/metro.h"
8 #include "third_party/skia/include/core/SkPath.h" 8 #include "third_party/skia/include/core/SkPath.h"
9 #include "third_party/skia/include/core/SkRegion.h" 9 #include "third_party/skia/include/core/SkRegion.h"
10 #include "ui/aura/client/aura_constants.h" 10 #include "ui/aura/client/aura_constants.h"
(...skipping 801 matching lines...) Expand 10 before | Expand all | Expand 10 after
812 OnHostResized(new_size); 812 OnHostResized(new_size);
813 } 813 }
814 814
815 void DesktopWindowTreeHostWin::HandleFrameChanged() { 815 void DesktopWindowTreeHostWin::HandleFrameChanged() {
816 SetWindowTransparency(); 816 SetWindowTransparency();
817 // Replace the frame and layout the contents. 817 // Replace the frame and layout the contents.
818 GetWidget()->non_client_view()->UpdateFrame(); 818 GetWidget()->non_client_view()->UpdateFrame();
819 } 819 }
820 820
821 void DesktopWindowTreeHostWin::HandleNativeFocus(HWND last_focused_window) { 821 void DesktopWindowTreeHostWin::HandleNativeFocus(HWND last_focused_window) {
822 // TODO(beng): inform the native_widget_delegate_. 822 // TODO(beng): inform the native_widget_delegate_.
sky 2015/05/22 17:29:02 I think it's worth a comment here as to why you do
Shu Chen 2015/05/25 01:14:25 Thanks for your comment. My later cl soon to refac
823 InputMethod* input_method = GetInputMethod();
824 if (input_method)
825 input_method->OnFocus();
826 } 823 }
827 824
828 void DesktopWindowTreeHostWin::HandleNativeBlur(HWND focused_window) { 825 void DesktopWindowTreeHostWin::HandleNativeBlur(HWND focused_window) {
829 // TODO(beng): inform the native_widget_delegate_. 826 // TODO(beng): inform the native_widget_delegate_.
830 InputMethod* input_method = GetInputMethod();
831 if (input_method)
832 input_method->OnBlur();
833 } 827 }
sadrul 2015/05/16 02:24:25 The X11 version seems to still do this (e.g. Deskt
Shu Chen 2015/05/20 06:30:52 Let's limit the scope of this change in Windows pl
834 828
835 bool DesktopWindowTreeHostWin::HandleMouseEvent(const ui::MouseEvent& event) { 829 bool DesktopWindowTreeHostWin::HandleMouseEvent(const ui::MouseEvent& event) {
836 SendEventToProcessor(const_cast<ui::MouseEvent*>(&event)); 830 SendEventToProcessor(const_cast<ui::MouseEvent*>(&event));
837 return event.handled(); 831 return event.handled();
838 } 832 }
839 833
840 bool DesktopWindowTreeHostWin::HandleKeyEvent(const ui::KeyEvent& event) { 834 bool DesktopWindowTreeHostWin::HandleKeyEvent(const ui::KeyEvent& event) {
841 return false; 835 return false;
842 } 836 }
843 837
(...skipping 148 matching lines...) Expand 10 before | Expand all | Expand 10 after
992 986
993 // static 987 // static
994 DesktopWindowTreeHost* DesktopWindowTreeHost::Create( 988 DesktopWindowTreeHost* DesktopWindowTreeHost::Create(
995 internal::NativeWidgetDelegate* native_widget_delegate, 989 internal::NativeWidgetDelegate* native_widget_delegate,
996 DesktopNativeWidgetAura* desktop_native_widget_aura) { 990 DesktopNativeWidgetAura* desktop_native_widget_aura) {
997 return new DesktopWindowTreeHostWin(native_widget_delegate, 991 return new DesktopWindowTreeHostWin(native_widget_delegate,
998 desktop_native_widget_aura); 992 desktop_native_widget_aura);
999 } 993 }
1000 994
1001 } // namespace views 995 } // namespace views
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698