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

Side by Side Diff: ui/gl/gl_surface.h

Issue 175093004: ui: Allow individual test suites to opt-out of the TestCompositor. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: nulldrawdisable: ui:: Created 6 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 | Annotate | Revision Log
« no previous file with comments | « ui/gl/gl_implementation.cc ('k') | ui/gl/gl_surface.cc » ('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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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_GL_GL_SURFACE_H_ 5 #ifndef UI_GL_GL_SURFACE_H_
6 #define UI_GL_GL_SURFACE_H_ 6 #define UI_GL_GL_SURFACE_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 virtual unsigned int GetBackingFrameBufferObject(); 68 virtual unsigned int GetBackingFrameBufferObject();
69 69
70 // Copy part of the backbuffer to the frontbuffer. 70 // Copy part of the backbuffer to the frontbuffer.
71 virtual bool PostSubBuffer(int x, int y, int width, int height); 71 virtual bool PostSubBuffer(int x, int y, int width, int height);
72 72
73 // Initialize GL bindings. 73 // Initialize GL bindings.
74 static bool InitializeOneOff(); 74 static bool InitializeOneOff();
75 75
76 // Unit tests should call these instead of InitializeOneOff() to set up 76 // Unit tests should call these instead of InitializeOneOff() to set up
77 // GL bindings appropriate for tests. 77 // GL bindings appropriate for tests.
78 static void InitializeOneOffForTests(); 78 // TODO(danakj): Once all callers pass true, remove the argument.
79 static void InitializeOneOffForTests(bool disable_drawing = false);
79 static void InitializeOneOffWithMockBindingsForTests(); 80 static void InitializeOneOffWithMockBindingsForTests();
80 static void InitializeDynamicMockBindingsForTests(GLContext* context); 81 static void InitializeDynamicMockBindingsForTests(GLContext* context);
81 82
82 // Called after a context is made current with this surface. Returns false 83 // Called after a context is made current with this surface. Returns false
83 // on error. 84 // on error.
84 virtual bool OnMakeCurrent(GLContext* context); 85 virtual bool OnMakeCurrent(GLContext* context);
85 86
86 // Used for explicit buffer management. 87 // Used for explicit buffer management.
87 virtual bool SetBackbufferAllocation(bool allocated); 88 virtual bool SetBackbufferAllocation(bool allocated);
88 virtual void SetFrontbufferAllocation(bool allocated); 89 virtual void SetFrontbufferAllocation(bool allocated);
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
167 168
168 private: 169 private:
169 scoped_refptr<GLSurface> surface_; 170 scoped_refptr<GLSurface> surface_;
170 171
171 DISALLOW_COPY_AND_ASSIGN(GLSurfaceAdapter); 172 DISALLOW_COPY_AND_ASSIGN(GLSurfaceAdapter);
172 }; 173 };
173 174
174 } // namespace gfx 175 } // namespace gfx
175 176
176 #endif // UI_GL_GL_SURFACE_H_ 177 #endif // UI_GL_GL_SURFACE_H_
OLDNEW
« no previous file with comments | « ui/gl/gl_implementation.cc ('k') | ui/gl/gl_surface.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698