Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(44)

Side by Side Diff: ui/events/test/events_test_utils_x11.h

Issue 1868363002: Replace scoped_ptr with std::unique_ptr in //ui (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@scopedptrcc
Patch Set: scopedptrui: rebase-make_scoped_ptr Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « ui/events/test/event_generator.cc ('k') | ui/events/test/test_event_processor.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #ifndef UI_EVENTS_TEST_EVENTS_TEST_UTILS_X11_H_ 5 #ifndef UI_EVENTS_TEST_EVENTS_TEST_UTILS_X11_H_
6 #define UI_EVENTS_TEST_EVENTS_TEST_UTILS_X11_H_ 6 #define UI_EVENTS_TEST_EVENTS_TEST_UTILS_X11_H_
7 7
8 #include <memory>
9
8 #include "base/macros.h" 10 #include "base/macros.h"
9 #include "base/memory/scoped_ptr.h"
10 #include "ui/events/devices/x11/device_data_manager_x11.h" 11 #include "ui/events/devices/x11/device_data_manager_x11.h"
11 #include "ui/events/event_constants.h" 12 #include "ui/events/event_constants.h"
12 #include "ui/events/keycodes/keyboard_codes.h" 13 #include "ui/events/keycodes/keyboard_codes.h"
13 #include "ui/gfx/geometry/point.h" 14 #include "ui/gfx/geometry/point.h"
14 #include "ui/gfx/x/x11_types.h" 15 #include "ui/gfx/x/x11_types.h"
15 16
16 typedef union _XEvent XEvent; 17 typedef union _XEvent XEvent;
17 18
18 namespace ui { 19 namespace ui {
19 20
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 int evtype, 82 int evtype,
82 int tracking_id, 83 int tracking_id,
83 const gfx::Point& location, 84 const gfx::Point& location,
84 const std::vector<Valuator>& valuators); 85 const std::vector<Valuator>& valuators);
85 86
86 private: 87 private:
87 void Cleanup(); 88 void Cleanup();
88 89
89 void SetUpValuators(const std::vector<Valuator>& valuators); 90 void SetUpValuators(const std::vector<Valuator>& valuators);
90 91
91 scoped_ptr<XEvent, XEventDeleter> event_; 92 std::unique_ptr<XEvent, XEventDeleter> event_;
92 93
93 DISALLOW_COPY_AND_ASSIGN(ScopedXI2Event); 94 DISALLOW_COPY_AND_ASSIGN(ScopedXI2Event);
94 }; 95 };
95 96
96 // Initializes a test touchpad device for scroll events. 97 // Initializes a test touchpad device for scroll events.
97 void SetUpTouchPadForTest(int deviceid); 98 void SetUpTouchPadForTest(int deviceid);
98 99
99 // Initializes a list of touchscreen devices for touch events. 100 // Initializes a list of touchscreen devices for touch events.
100 void SetUpTouchDevicesForTest(const std::vector<int>& devices); 101 void SetUpTouchDevicesForTest(const std::vector<int>& devices);
101 102
102 // Initializes a list of non-touch, non-cmt pointer devices. 103 // Initializes a list of non-touch, non-cmt pointer devices.
103 void SetUpPointerDevicesForTest(const std::vector<int>& devices); 104 void SetUpPointerDevicesForTest(const std::vector<int>& devices);
104 105
105 } // namespace ui 106 } // namespace ui
106 107
107 #endif // UI_EVENTS_TEST_EVENTS_TEST_UTILS_X11_H_ 108 #endif // UI_EVENTS_TEST_EVENTS_TEST_UTILS_X11_H_
OLDNEW
« no previous file with comments | « ui/events/test/event_generator.cc ('k') | ui/events/test/test_event_processor.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698