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/ozone/platform/dri/test/mock_dri_wrapper.h" | 5 #include "ui/ozone/platform/dri/test/mock_dri_wrapper.h" |
6 | 6 |
7 #include <xf86drm.h> | 7 #include <xf86drm.h> |
8 #include <xf86drmMode.h> | 8 #include <xf86drmMode.h> |
9 | 9 |
10 #include "third_party/skia/include/core/SkCanvas.h" | 10 #include "third_party/skia/include/core/SkCanvas.h" |
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
103 } | 103 } |
104 | 104 |
105 ScopedDrmPropertyBlobPtr MockDriWrapper::GetPropertyBlob( | 105 ScopedDrmPropertyBlobPtr MockDriWrapper::GetPropertyBlob( |
106 drmModeConnector* connector, | 106 drmModeConnector* connector, |
107 const char* name) { | 107 const char* name) { |
108 return ScopedDrmPropertyBlobPtr(DrmAllocator<drmModePropertyBlobRes>()); | 108 return ScopedDrmPropertyBlobPtr(DrmAllocator<drmModePropertyBlobRes>()); |
109 } | 109 } |
110 | 110 |
111 bool MockDriWrapper::SetCursor(uint32_t crtc_id, | 111 bool MockDriWrapper::SetCursor(uint32_t crtc_id, |
112 uint32_t handle, | 112 uint32_t handle, |
113 uint32_t width, | 113 const gfx::Size& size) { |
114 uint32_t height) { | |
115 return true; | 114 return true; |
116 } | 115 } |
117 | 116 |
118 bool MockDriWrapper::MoveCursor(uint32_t crtc_id, int x, int y) { | 117 bool MockDriWrapper::MoveCursor(uint32_t crtc_id, const gfx::Point& point) { |
119 return true; | 118 return true; |
120 } | 119 } |
121 | 120 |
122 void MockDriWrapper::HandleEvent(drmEventContext& event) { | 121 void MockDriWrapper::HandleEvent(drmEventContext& event) { |
123 } | 122 } |
124 | 123 |
125 bool MockDriWrapper::CreateDumbBuffer(const SkImageInfo& info, | 124 bool MockDriWrapper::CreateDumbBuffer(const SkImageInfo& info, |
126 uint32_t* handle, | 125 uint32_t* handle, |
127 uint32_t* stride, | 126 uint32_t* stride, |
128 void** pixels) { | 127 void** pixels) { |
(...skipping 11 matching lines...) Expand all Loading... |
140 } | 139 } |
141 | 140 |
142 void MockDriWrapper::DestroyDumbBuffer(const SkImageInfo& info, | 141 void MockDriWrapper::DestroyDumbBuffer(const SkImageInfo& info, |
143 uint32_t handle, | 142 uint32_t handle, |
144 uint32_t stride, | 143 uint32_t stride, |
145 void* pixels) { | 144 void* pixels) { |
146 delete[] static_cast<char*>(pixels); | 145 delete[] static_cast<char*>(pixels); |
147 } | 146 } |
148 | 147 |
149 } // namespace ui | 148 } // namespace ui |
OLD | NEW |