| OLD | NEW |
| 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/memory/ptr_util.h" | 7 #include "base/memory/ptr_util.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 914 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 925 const ui::ScrollEvent& event) { | 925 const ui::ScrollEvent& event) { |
| 926 SendEventToProcessor(const_cast<ui::ScrollEvent*>(&event)); | 926 SendEventToProcessor(const_cast<ui::ScrollEvent*>(&event)); |
| 927 return event.handled(); | 927 return event.handled(); |
| 928 } | 928 } |
| 929 | 929 |
| 930 void DesktopWindowTreeHostWin::HandleWindowSizeChanging() { | 930 void DesktopWindowTreeHostWin::HandleWindowSizeChanging() { |
| 931 if (compositor()) | 931 if (compositor()) |
| 932 compositor()->DisableSwapUntilResize(); | 932 compositor()->DisableSwapUntilResize(); |
| 933 } | 933 } |
| 934 | 934 |
| 935 void DesktopWindowTreeHostWin::HandleWindowSizeChanged() { | 935 void DesktopWindowTreeHostWin::HandleWindowSizeUnchanged() { |
| 936 // A resize may not have occurred if the window size happened not to have | 936 // A resize may not have occurred if the window size happened not to have |
| 937 // changed (can occur on Windows 10 when snapping a window to the side of | 937 // changed (can occur on Windows 10 when snapping a window to the side of |
| 938 // the screen). In that case do a resize to the current size to reenable | 938 // the screen). In that case do a resize to the current size to reenable |
| 939 // swaps. | 939 // swaps. |
| 940 if (compositor()) { | 940 if (compositor()) { |
| 941 compositor()->SetScaleAndSize( | 941 compositor()->SetScaleAndSize( |
| 942 compositor()->device_scale_factor(), | 942 compositor()->device_scale_factor(), |
| 943 message_handler_->GetClientAreaBounds().size()); | 943 message_handler_->GetClientAreaBounds().size()); |
| 944 } | 944 } |
| 945 } | 945 } |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 997 | 997 |
| 998 // static | 998 // static |
| 999 DesktopWindowTreeHost* DesktopWindowTreeHost::Create( | 999 DesktopWindowTreeHost* DesktopWindowTreeHost::Create( |
| 1000 internal::NativeWidgetDelegate* native_widget_delegate, | 1000 internal::NativeWidgetDelegate* native_widget_delegate, |
| 1001 DesktopNativeWidgetAura* desktop_native_widget_aura) { | 1001 DesktopNativeWidgetAura* desktop_native_widget_aura) { |
| 1002 return new DesktopWindowTreeHostWin(native_widget_delegate, | 1002 return new DesktopWindowTreeHostWin(native_widget_delegate, |
| 1003 desktop_native_widget_aura); | 1003 desktop_native_widget_aura); |
| 1004 } | 1004 } |
| 1005 | 1005 |
| 1006 } // namespace views | 1006 } // namespace views |
| OLD | NEW |