| 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_root_window_host_win.h" | 5 #include "ui/views/widget/desktop_aura/desktop_root_window_host_win.h" |
| 6 | 6 |
| 7 #include "third_party/skia/include/core/SkPath.h" | 7 #include "third_party/skia/include/core/SkPath.h" |
| 8 #include "third_party/skia/include/core/SkRegion.h" | 8 #include "third_party/skia/include/core/SkRegion.h" |
| 9 #include "ui/aura/client/aura_constants.h" | 9 #include "ui/aura/client/aura_constants.h" |
| 10 #include "ui/aura/client/default_capture_client.h" | 10 #include "ui/aura/client/default_capture_client.h" |
| 11 #include "ui/aura/focus_manager.h" | 11 #include "ui/aura/focus_manager.h" |
| 12 #include "ui/aura/root_window.h" | 12 #include "ui/aura/root_window.h" |
| 13 #include "ui/aura/window_property.h" | 13 #include "ui/aura/window_property.h" |
| 14 #include "ui/base/cursor/cursor_loader_win.h" | 14 #include "ui/base/cursor/cursor_loader_win.h" |
| 15 #include "ui/base/ime/input_method_win.h" | 15 #include "ui/base/ime/input_method_win.h" |
| 16 #include "ui/base/win/shell.h" | 16 #include "ui/base/win/shell.h" |
| 17 #include "ui/gfx/insets.h" |
| 17 #include "ui/gfx/native_widget_types.h" | 18 #include "ui/gfx/native_widget_types.h" |
| 18 #include "ui/gfx/path_win.h" | 19 #include "ui/gfx/path_win.h" |
| 19 #include "ui/native_theme/native_theme_aura.h" | 20 #include "ui/native_theme/native_theme_aura.h" |
| 20 #include "ui/native_theme/native_theme_win.h" | 21 #include "ui/native_theme/native_theme_win.h" |
| 21 #include "ui/views/corewm/compound_event_filter.h" | 22 #include "ui/views/corewm/compound_event_filter.h" |
| 22 #include "ui/views/corewm/corewm_switches.h" | 23 #include "ui/views/corewm/corewm_switches.h" |
| 23 #include "ui/views/corewm/cursor_manager.h" | 24 #include "ui/views/corewm/cursor_manager.h" |
| 24 #include "ui/views/corewm/focus_controller.h" | 25 #include "ui/views/corewm/focus_controller.h" |
| 25 #include "ui/views/corewm/input_method_event_filter.h" | 26 #include "ui/views/corewm/input_method_event_filter.h" |
| 26 #include "ui/views/ime/input_method_bridge.h" | 27 #include "ui/views/ime/input_method_bridge.h" |
| (...skipping 347 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 374 gfx::Rect DesktopRootWindowHostWin::GetBounds() const { | 375 gfx::Rect DesktopRootWindowHostWin::GetBounds() const { |
| 375 // Match the logic in HWNDMessageHandler::ClientAreaSizeChanged(). | 376 // Match the logic in HWNDMessageHandler::ClientAreaSizeChanged(). |
| 376 return WidgetSizeIsClientSize() ? | 377 return WidgetSizeIsClientSize() ? |
| 377 GetClientAreaBoundsInScreen() : GetWindowBoundsInScreen(); | 378 GetClientAreaBoundsInScreen() : GetWindowBoundsInScreen(); |
| 378 } | 379 } |
| 379 | 380 |
| 380 void DesktopRootWindowHostWin::SetBounds(const gfx::Rect& bounds) { | 381 void DesktopRootWindowHostWin::SetBounds(const gfx::Rect& bounds) { |
| 381 message_handler_->SetBounds(bounds); | 382 message_handler_->SetBounds(bounds); |
| 382 } | 383 } |
| 383 | 384 |
| 385 gfx::Insets DesktopRootWindowHostWin::GetInsets() const { |
| 386 return gfx::Insets(); |
| 387 } |
| 388 |
| 389 void DesktopRootWindowHostWin::SetInsets(const gfx::Insets& insets) { |
| 390 } |
| 391 |
| 384 gfx::Point DesktopRootWindowHostWin::GetLocationOnNativeScreen() const { | 392 gfx::Point DesktopRootWindowHostWin::GetLocationOnNativeScreen() const { |
| 385 return GetBounds().origin(); | 393 return GetBounds().origin(); |
| 386 } | 394 } |
| 387 | 395 |
| 388 void DesktopRootWindowHostWin::SetCapture() { | 396 void DesktopRootWindowHostWin::SetCapture() { |
| 389 message_handler_->SetCapture(); | 397 message_handler_->SetCapture(); |
| 390 } | 398 } |
| 391 | 399 |
| 392 void DesktopRootWindowHostWin::ReleaseCapture() { | 400 void DesktopRootWindowHostWin::ReleaseCapture() { |
| 393 message_handler_->ReleaseCapture(); | 401 message_handler_->ReleaseCapture(); |
| (...skipping 378 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 772 DesktopRootWindowHost* DesktopRootWindowHost::Create( | 780 DesktopRootWindowHost* DesktopRootWindowHost::Create( |
| 773 internal::NativeWidgetDelegate* native_widget_delegate, | 781 internal::NativeWidgetDelegate* native_widget_delegate, |
| 774 DesktopNativeWidgetAura* desktop_native_widget_aura, | 782 DesktopNativeWidgetAura* desktop_native_widget_aura, |
| 775 const gfx::Rect& initial_bounds) { | 783 const gfx::Rect& initial_bounds) { |
| 776 return new DesktopRootWindowHostWin(native_widget_delegate, | 784 return new DesktopRootWindowHostWin(native_widget_delegate, |
| 777 desktop_native_widget_aura, | 785 desktop_native_widget_aura, |
| 778 initial_bounds); | 786 initial_bounds); |
| 779 } | 787 } |
| 780 | 788 |
| 781 } // namespace views | 789 } // namespace views |
| OLD | NEW |