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/native_widget_aura.h" | 5 #include "ui/views/widget/native_widget_aura.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/strings/string_util.h" | 8 #include "base/strings/string_util.h" |
9 #include "third_party/skia/include/core/SkRegion.h" | 9 #include "third_party/skia/include/core/SkRegion.h" |
10 #include "ui/aura/client/activation_client.h" | 10 #include "ui/aura/client/activation_client.h" |
(...skipping 30 matching lines...) Expand all Loading... |
41 #include "ui/views/widget/widget_delegate.h" | 41 #include "ui/views/widget/widget_delegate.h" |
42 #include "ui/views/widget/window_reorderer.h" | 42 #include "ui/views/widget/window_reorderer.h" |
43 | 43 |
44 #if defined(OS_WIN) | 44 #if defined(OS_WIN) |
45 #include "base/win/scoped_gdi_object.h" | 45 #include "base/win/scoped_gdi_object.h" |
46 #include "base/win/win_util.h" | 46 #include "base/win/win_util.h" |
47 #include "ui/base/l10n/l10n_util_win.h" | 47 #include "ui/base/l10n/l10n_util_win.h" |
48 #include "ui/views/widget/desktop_aura/desktop_root_window_host_win.h" | 48 #include "ui/views/widget/desktop_aura/desktop_root_window_host_win.h" |
49 #endif | 49 #endif |
50 | 50 |
51 #if defined(OS_LINUX) && !defined(OS_CHROMEOS) | 51 #if defined(USE_X11) && !defined(OS_CHROMEOS) |
52 #include "ui/views/widget/desktop_aura/desktop_root_window_host_x11.h" | 52 #include "ui/views/widget/desktop_aura/desktop_root_window_host_x11.h" |
53 #endif | 53 #endif |
54 | 54 |
55 #if !defined(OS_CHROMEOS) | 55 #if !defined(OS_CHROMEOS) |
56 #include "ui/views/widget/desktop_aura/desktop_root_window_host.h" | 56 #include "ui/views/widget/desktop_aura/desktop_root_window_host.h" |
57 #endif | 57 #endif |
58 | 58 |
59 namespace views { | 59 namespace views { |
60 | 60 |
61 namespace { | 61 namespace { |
(...skipping 878 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
940 } | 940 } |
941 #endif | 941 #endif |
942 } // namespace | 942 } // namespace |
943 | 943 |
944 // static | 944 // static |
945 void Widget::CloseAllSecondaryWidgets() { | 945 void Widget::CloseAllSecondaryWidgets() { |
946 #if defined(OS_WIN) | 946 #if defined(OS_WIN) |
947 EnumThreadWindows(GetCurrentThreadId(), WindowCallbackProc, 0); | 947 EnumThreadWindows(GetCurrentThreadId(), WindowCallbackProc, 0); |
948 #endif | 948 #endif |
949 | 949 |
950 #if defined(OS_LINUX) && !defined(OS_CHROMEOS) | 950 #if defined(USE_X11) && !defined(OS_CHROMEOS) |
951 std::vector<aura::Window*> open_windows = | 951 std::vector<aura::Window*> open_windows = |
952 DesktopRootWindowHostX11::GetAllOpenWindows(); | 952 DesktopRootWindowHostX11::GetAllOpenWindows(); |
953 std::for_each(open_windows.begin(), open_windows.end(), CloseWindow); | 953 std::for_each(open_windows.begin(), open_windows.end(), CloseWindow); |
954 DesktopRootWindowHostX11::CleanUpWindowList(); | 954 DesktopRootWindowHostX11::CleanUpWindowList(); |
955 #endif | 955 #endif |
956 } | 956 } |
957 | 957 |
958 bool Widget::ConvertRect(const Widget* source, | 958 bool Widget::ConvertRect(const Widget* source, |
959 const Widget* target, | 959 const Widget* target, |
960 gfx::Rect* rect) { | 960 gfx::Rect* rect) { |
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1069 return aura::Env::GetInstance()->is_mouse_button_down(); | 1069 return aura::Env::GetInstance()->is_mouse_button_down(); |
1070 } | 1070 } |
1071 | 1071 |
1072 // static | 1072 // static |
1073 bool NativeWidgetPrivate::IsTouchDown() { | 1073 bool NativeWidgetPrivate::IsTouchDown() { |
1074 return aura::Env::GetInstance()->is_touch_down(); | 1074 return aura::Env::GetInstance()->is_touch_down(); |
1075 } | 1075 } |
1076 | 1076 |
1077 } // namespace internal | 1077 } // namespace internal |
1078 } // namespace views | 1078 } // namespace views |
OLD | NEW |