OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/x11_topmost_window_finder.h" | 5 #include "ui/views/widget/desktop_aura/x11_topmost_window_finder.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <stddef.h> |
8 #include <vector> | |
9 #include <X11/extensions/shape.h> | 8 #include <X11/extensions/shape.h> |
10 #include <X11/Xlib.h> | 9 #include <X11/Xlib.h> |
11 #include <X11/Xregion.h> | 10 #include <X11/Xregion.h> |
| 11 #include <algorithm> |
| 12 #include <vector> |
12 | 13 |
13 // Get rid of X11 macros which conflict with gtest. | 14 // Get rid of X11 macros which conflict with gtest. |
14 #undef Bool | 15 #undef Bool |
15 #undef None | 16 #undef None |
16 | 17 |
| 18 #include "base/macros.h" |
17 #include "base/memory/scoped_ptr.h" | 19 #include "base/memory/scoped_ptr.h" |
18 #include "base/path_service.h" | 20 #include "base/path_service.h" |
19 #include "third_party/skia/include/core/SkRect.h" | 21 #include "third_party/skia/include/core/SkRect.h" |
20 #include "third_party/skia/include/core/SkRegion.h" | 22 #include "third_party/skia/include/core/SkRegion.h" |
21 #include "ui/aura/window.h" | 23 #include "ui/aura/window.h" |
22 #include "ui/aura/window_tree_host.h" | 24 #include "ui/aura/window_tree_host.h" |
23 #include "ui/base/resource/resource_bundle.h" | 25 #include "ui/base/resource/resource_bundle.h" |
24 #include "ui/base/ui_base_paths.h" | 26 #include "ui/base/ui_base_paths.h" |
25 #include "ui/events/platform/x11/x11_event_source.h" | 27 #include "ui/events/platform/x11/x11_event_source.h" |
26 #include "ui/gfx/path.h" | 28 #include "ui/gfx/path.h" |
(...skipping 406 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
433 | 435 |
434 EXPECT_EQ(xid, FindTopmostXWindowAt(110, 110)); | 436 EXPECT_EQ(xid, FindTopmostXWindowAt(110, 110)); |
435 EXPECT_EQ(menu_xid, FindTopmostXWindowAt(150, 120)); | 437 EXPECT_EQ(menu_xid, FindTopmostXWindowAt(150, 120)); |
436 EXPECT_EQ(menu_xid, FindTopmostXWindowAt(210, 120)); | 438 EXPECT_EQ(menu_xid, FindTopmostXWindowAt(210, 120)); |
437 | 439 |
438 XDestroyWindow(xdisplay(), xid); | 440 XDestroyWindow(xdisplay(), xid); |
439 XDestroyWindow(xdisplay(), menu_xid); | 441 XDestroyWindow(xdisplay(), menu_xid); |
440 } | 442 } |
441 | 443 |
442 } // namespace views | 444 } // namespace views |
OLD | NEW |