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 <vector> | 5 #include <vector> |
6 | 6 |
| 7 #include <stddef.h> |
7 #include <X11/extensions/shape.h> | 8 #include <X11/extensions/shape.h> |
8 #include <X11/Xlib.h> | 9 #include <X11/Xlib.h> |
9 | 10 |
10 // Get rid of X11 macros which conflict with gtest. | 11 // Get rid of X11 macros which conflict with gtest. |
11 // It is necessary to include this header before the rest so that Bool can be | 12 // It is necessary to include this header before the rest so that Bool can be |
12 // undefined. | 13 // undefined. |
13 #include "ui/events/test/events_test_utils_x11.h" | 14 #include "ui/events/test/events_test_utils_x11.h" |
14 #undef Bool | 15 #undef Bool |
15 #undef None | 16 #undef None |
16 | 17 |
17 #include "base/command_line.h" | 18 #include "base/command_line.h" |
| 19 #include "base/macros.h" |
18 #include "base/memory/scoped_ptr.h" | 20 #include "base/memory/scoped_ptr.h" |
19 #include "base/run_loop.h" | 21 #include "base/run_loop.h" |
20 #include "ui/aura/window.h" | 22 #include "ui/aura/window.h" |
21 #include "ui/aura/window_tree_host.h" | 23 #include "ui/aura/window_tree_host.h" |
22 #include "ui/base/hit_test.h" | 24 #include "ui/base/hit_test.h" |
23 #include "ui/base/x/x11_util.h" | 25 #include "ui/base/x/x11_util.h" |
24 #include "ui/events/devices/x11/touch_factory_x11.h" | 26 #include "ui/events/devices/x11/touch_factory_x11.h" |
25 #include "ui/events/platform/x11/x11_event_source.h" | 27 #include "ui/events/platform/x11/x11_event_source.h" |
26 #include "ui/events/test/platform_event_source_test_api.h" | 28 #include "ui/events/test/platform_event_source_test_api.h" |
27 #include "ui/gfx/geometry/point.h" | 29 #include "ui/gfx/geometry/point.h" |
(...skipping 614 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
642 EXPECT_EQ(ui::ET_MOUSEWHEEL, second_recorder.mouse_events()[0].type()); | 644 EXPECT_EQ(ui::ET_MOUSEWHEEL, second_recorder.mouse_events()[0].type()); |
643 EXPECT_EQ(gfx::Point(-25, -25).ToString(), | 645 EXPECT_EQ(gfx::Point(-25, -25).ToString(), |
644 second_recorder.mouse_events()[0].location().ToString()); | 646 second_recorder.mouse_events()[0].location().ToString()); |
645 | 647 |
646 PretendCapture(nullptr); | 648 PretendCapture(nullptr); |
647 first.GetNativeWindow()->RemovePreTargetHandler(&first_recorder); | 649 first.GetNativeWindow()->RemovePreTargetHandler(&first_recorder); |
648 second.GetNativeWindow()->RemovePreTargetHandler(&second_recorder); | 650 second.GetNativeWindow()->RemovePreTargetHandler(&second_recorder); |
649 } | 651 } |
650 | 652 |
651 } // namespace views | 653 } // namespace views |
OLD | NEW |