Index: ui/gl/gl_context.h |
diff --git a/ui/gl/gl_context.h b/ui/gl/gl_context.h |
index dc65f64a8ae6baad9b6990ef104a46ba445b99d4..e396ca0cc2258e2c515f56b130b4a069cbc147cb 100644 |
--- a/ui/gl/gl_context.h |
+++ b/ui/gl/gl_context.h |
@@ -88,6 +88,7 @@ class GL_EXPORT GLContext : public base::RefCounted<GLContext> { |
static bool LosesAllContextsOnContextLost(); |
+ // Returns the last GLContext made current, virtual or real. |
static GLContext* GetCurrent(); |
virtual bool WasAllocatedUsingRobustnessExtension(); |
@@ -114,9 +115,17 @@ class GL_EXPORT GLContext : public base::RefCounted<GLContext> { |
// current. |
bool InitializeExtensionBindings(); |
+ virtual bool IsVirtualContext(); |
+ |
+ // Returns the last real (non-virtual) GLContext made current. |
+ static GLContext* GetRealCurrent(); |
+ |
private: |
friend class base::RefCounted<GLContext>; |
+ // For GetRealCurrent. |
+ friend class VirtualGLApi; |
+ |
scoped_refptr<GLShareGroup> share_group_; |
scoped_ptr<VirtualGLApi> virtual_gl_api_; |
scoped_ptr<GLStateRestorer> state_restorer_; |