| 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 <cstring> | 5 #include <cstring> |
| 6 #include <set> | 6 #include <set> |
| 7 | 7 |
| 8 #include <X11/extensions/XInput2.h> | 8 #include <X11/extensions/XInput2.h> |
| 9 #include <X11/Xlib.h> | 9 #include <X11/Xlib.h> |
| 10 #include <X11/Xutil.h> | 10 #include <X11/Xutil.h> |
| 11 #include <X11/XKBlib.h> | 11 #include <X11/XKBlib.h> |
| 12 | 12 |
| 13 // Generically-named #defines from Xlib that conflict with symbols in GTest. | 13 // Generically-named #defines from Xlib that conflict with symbols in GTest. |
| 14 #undef Bool | 14 #undef Bool |
| 15 #undef None | 15 #undef None |
| 16 | 16 |
| 17 #include "base/memory/scoped_ptr.h" | 17 #include "base/memory/scoped_ptr.h" |
| 18 #include "testing/gtest/include/gtest/gtest.h" | 18 #include "testing/gtest/include/gtest/gtest.h" |
| 19 #include "ui/events/devices/x11/device_data_manager_x11.h" |
| 20 #include "ui/events/devices/x11/touch_factory_x11.h" |
| 19 #include "ui/events/event.h" | 21 #include "ui/events/event.h" |
| 20 #include "ui/events/event_constants.h" | 22 #include "ui/events/event_constants.h" |
| 21 #include "ui/events/event_utils.h" | 23 #include "ui/events/event_utils.h" |
| 22 #include "ui/events/test/events_test_utils.h" | 24 #include "ui/events/test/events_test_utils.h" |
| 23 #include "ui/events/test/events_test_utils_x11.h" | 25 #include "ui/events/test/events_test_utils_x11.h" |
| 24 #include "ui/events/x/device_data_manager_x11.h" | |
| 25 #include "ui/events/x/touch_factory_x11.h" | |
| 26 #include "ui/gfx/point.h" | 26 #include "ui/gfx/point.h" |
| 27 | 27 |
| 28 namespace ui { | 28 namespace ui { |
| 29 | 29 |
| 30 namespace { | 30 namespace { |
| 31 | 31 |
| 32 // Initializes the passed-in Xlib event. | 32 // Initializes the passed-in Xlib event. |
| 33 void InitButtonEvent(XEvent* event, | 33 void InitButtonEvent(XEvent* event, |
| 34 bool is_press, | 34 bool is_press, |
| 35 const gfx::Point& location, | 35 const gfx::Point& location, |
| (...skipping 597 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 633 KeyEventTestApi test_event(&key_event); | 633 KeyEventTestApi test_event(&key_event); |
| 634 test_event.set_is_char(true); | 634 test_event.set_is_char(true); |
| 635 } | 635 } |
| 636 EXPECT_FALSE(key_event.flags() & ui::EF_IME_FABRICATED_KEY); | 636 EXPECT_FALSE(key_event.flags() & ui::EF_IME_FABRICATED_KEY); |
| 637 } | 637 } |
| 638 } | 638 } |
| 639 } | 639 } |
| 640 #endif | 640 #endif |
| 641 | 641 |
| 642 } // namespace ui | 642 } // namespace ui |
| OLD | NEW |