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

Side by Side Diff: ui/ozone/platform/egltest/ozone_platform_egltest.cc

Issue 300023006: ozone: Add OnSwapBuffers hook to SurfaceOzoneEGL (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 6 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « ui/gl/gl_surface_ozone.cc ('k') | 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/egltest/ozone_platform_egltest.h" 5 #include "ui/ozone/platform/egltest/ozone_platform_egltest.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/environment.h" 8 #include "base/environment.h"
9 #include "base/files/file_path.h" 9 #include "base/files/file_path.h"
10 #include "base/path_service.h" 10 #include "base/path_service.h"
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 LibeglplatformShimLoader* eglplatform_shim) 52 LibeglplatformShimLoader* eglplatform_shim)
53 : eglplatform_shim_(eglplatform_shim) { 53 : eglplatform_shim_(eglplatform_shim) {
54 native_window_ = eglplatform_shim_->ShimGetNativeWindow(window_id); 54 native_window_ = eglplatform_shim_->ShimGetNativeWindow(window_id);
55 } 55 }
56 virtual ~SurfaceOzoneEgltest() { 56 virtual ~SurfaceOzoneEgltest() {
57 CHECK(eglplatform_shim_->ShimReleaseNativeWindow(native_window_)); 57 CHECK(eglplatform_shim_->ShimReleaseNativeWindow(native_window_));
58 } 58 }
59 59
60 virtual intptr_t GetNativeWindow() OVERRIDE { return native_window_; } 60 virtual intptr_t GetNativeWindow() OVERRIDE { return native_window_; }
61 61
62 virtual bool OnSwapBuffers() OVERRIDE { return true; }
63
62 virtual bool ResizeNativeWindow(const gfx::Size& viewport_size) OVERRIDE { 64 virtual bool ResizeNativeWindow(const gfx::Size& viewport_size) OVERRIDE {
63 return true; 65 return true;
64 } 66 }
65 67
66 virtual scoped_ptr<gfx::VSyncProvider> CreateVSyncProvider() OVERRIDE { 68 virtual scoped_ptr<gfx::VSyncProvider> CreateVSyncProvider() OVERRIDE {
67 return scoped_ptr<gfx::VSyncProvider>(); 69 return scoped_ptr<gfx::VSyncProvider>();
68 } 70 }
69 71
70 private: 72 private:
71 LibeglplatformShimLoader* eglplatform_shim_; 73 LibeglplatformShimLoader* eglplatform_shim_;
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after
276 278
277 } // namespace 279 } // namespace
278 280
279 OzonePlatform* CreateOzonePlatformEgltest() { 281 OzonePlatform* CreateOzonePlatformEgltest() {
280 OzonePlatformEgltest* platform = new OzonePlatformEgltest; 282 OzonePlatformEgltest* platform = new OzonePlatformEgltest;
281 platform->Initialize(); 283 platform->Initialize();
282 return platform; 284 return platform;
283 } 285 }
284 286
285 } // namespace ui 287 } // namespace ui
OLDNEW
« no previous file with comments | « ui/gl/gl_surface_ozone.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698