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

Side by Side Diff: ui/ozone/platform/dri/gbm_surfaceless.cc

Issue 884183007: [Ozone-Gbm] Return true on resize of surfaceless surfaces (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 10 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 | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/gbm_surfaceless.h" 5 #include "ui/ozone/platform/dri/gbm_surfaceless.h"
6 6
7 #include "ui/ozone/platform/dri/dri_vsync_provider.h" 7 #include "ui/ozone/platform/dri/dri_vsync_provider.h"
8 #include "ui/ozone/platform/dri/dri_window_delegate.h" 8 #include "ui/ozone/platform/dri/dri_window_delegate.h"
9 #include "ui/ozone/platform/dri/gbm_buffer.h" 9 #include "ui/ozone/platform/dri/gbm_buffer.h"
10 #include "ui/ozone/platform/dri/hardware_display_controller.h" 10 #include "ui/ozone/platform/dri/hardware_display_controller.h"
11 11
12 namespace ui { 12 namespace ui {
13 13
14 GbmSurfaceless::GbmSurfaceless(DriWindowDelegate* window_delegate) 14 GbmSurfaceless::GbmSurfaceless(DriWindowDelegate* window_delegate)
15 : window_delegate_(window_delegate) { 15 : window_delegate_(window_delegate) {
16 } 16 }
17 17
18 GbmSurfaceless::~GbmSurfaceless() {} 18 GbmSurfaceless::~GbmSurfaceless() {}
19 19
20 intptr_t GbmSurfaceless::GetNativeWindow() { 20 intptr_t GbmSurfaceless::GetNativeWindow() {
21 NOTREACHED(); 21 NOTREACHED();
22 return 0; 22 return 0;
23 } 23 }
24 24
25 bool GbmSurfaceless::ResizeNativeWindow(const gfx::Size& viewport_size) { 25 bool GbmSurfaceless::ResizeNativeWindow(const gfx::Size& viewport_size) {
26 NOTIMPLEMENTED(); 26 return true;
27 return false;
28 } 27 }
29 28
30 bool GbmSurfaceless::OnSwapBuffers() { 29 bool GbmSurfaceless::OnSwapBuffers() {
31 NOTREACHED(); 30 NOTREACHED();
32 return false; 31 return false;
33 } 32 }
34 33
35 bool GbmSurfaceless::OnSwapBuffersAsync( 34 bool GbmSurfaceless::OnSwapBuffersAsync(
36 const SwapCompletionCallback& callback) { 35 const SwapCompletionCallback& callback) {
37 HardwareDisplayController* controller = window_delegate_->GetController(); 36 HardwareDisplayController* controller = window_delegate_->GetController();
38 if (!controller) { 37 if (!controller) {
39 callback.Run(); 38 callback.Run();
40 return true; 39 return true;
41 } 40 }
42 41
43 return controller->SchedulePageFlip(callback); 42 return controller->SchedulePageFlip(callback);
44 } 43 }
45 44
46 scoped_ptr<gfx::VSyncProvider> GbmSurfaceless::CreateVSyncProvider() { 45 scoped_ptr<gfx::VSyncProvider> GbmSurfaceless::CreateVSyncProvider() {
47 return scoped_ptr<gfx::VSyncProvider>(new DriVSyncProvider(window_delegate_)); 46 return scoped_ptr<gfx::VSyncProvider>(new DriVSyncProvider(window_delegate_));
48 } 47 }
49 48
50 } // namespace ui 49 } // namespace ui
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698