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 #ifndef UI_OZONE_PLATFORM_DRM_GPU_DRM_DEVICE_H_ | 5 #ifndef UI_OZONE_PLATFORM_DRM_GPU_DRM_DEVICE_H_ |
6 #define UI_OZONE_PLATFORM_DRM_GPU_DRM_DEVICE_H_ | 6 #define UI_OZONE_PLATFORM_DRM_GPU_DRM_DEVICE_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 #include <stdint.h> | 9 #include <stdint.h> |
10 | 10 |
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
179 | 179 |
180 base::FilePath device_path() const { return device_path_; } | 180 base::FilePath device_path() const { return device_path_; } |
181 | 181 |
182 HardwareDisplayPlaneManager* plane_manager() { return plane_manager_.get(); } | 182 HardwareDisplayPlaneManager* plane_manager() { return plane_manager_.get(); } |
183 | 183 |
184 protected: | 184 protected: |
185 friend class base::RefCountedThreadSafe<DrmDevice>; | 185 friend class base::RefCountedThreadSafe<DrmDevice>; |
186 | 186 |
187 virtual ~DrmDevice(); | 187 virtual ~DrmDevice(); |
188 | 188 |
189 scoped_ptr<HardwareDisplayPlaneManager> plane_manager_; | 189 std::unique_ptr<HardwareDisplayPlaneManager> plane_manager_; |
190 | 190 |
191 private: | 191 private: |
192 class IOWatcher; | 192 class IOWatcher; |
193 class PageFlipManager; | 193 class PageFlipManager; |
194 | 194 |
195 // Path to the DRM device (in sysfs). | 195 // Path to the DRM device (in sysfs). |
196 const base::FilePath device_path_; | 196 const base::FilePath device_path_; |
197 | 197 |
198 // DRM device. | 198 // DRM device. |
199 base::File file_; | 199 base::File file_; |
200 | 200 |
201 scoped_ptr<PageFlipManager> page_flip_manager_; | 201 std::unique_ptr<PageFlipManager> page_flip_manager_; |
202 | 202 |
203 // Watcher for |fd_| listening for page flip events. | 203 // Watcher for |fd_| listening for page flip events. |
204 scoped_ptr<IOWatcher> watcher_; | 204 std::unique_ptr<IOWatcher> watcher_; |
205 | 205 |
206 bool is_primary_device_; | 206 bool is_primary_device_; |
207 | 207 |
208 DISALLOW_COPY_AND_ASSIGN(DrmDevice); | 208 DISALLOW_COPY_AND_ASSIGN(DrmDevice); |
209 }; | 209 }; |
210 | 210 |
211 } // namespace ui | 211 } // namespace ui |
212 | 212 |
213 #endif // UI_OZONE_PLATFORM_DRM_GPU_DRM_DEVICE_H_ | 213 #endif // UI_OZONE_PLATFORM_DRM_GPU_DRM_DEVICE_H_ |
OLD | NEW |