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

Unified Diff: Source/core/html/canvas/WebGLContextGroup.cpp

Issue 24096029: Moved the majority of WebGL functionality into WebGLRenderingContextBase (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: Source/core/html/canvas/WebGLContextGroup.cpp
diff --git a/Source/core/html/canvas/WebGLContextGroup.cpp b/Source/core/html/canvas/WebGLContextGroup.cpp
index 46650a6e29205de66c7c84e4b19e1d67f846b9a2..b020d29e142265ffdb342236c50cae4107ba2cb8 100644
--- a/Source/core/html/canvas/WebGLContextGroup.cpp
+++ b/Source/core/html/canvas/WebGLContextGroup.cpp
@@ -27,7 +27,7 @@
#include "core/html/canvas/WebGLContextGroup.h"
-#include "core/html/canvas/WebGLRenderingContext.h"
+#include "core/html/canvas/WebGLRenderingContextBase.h"
#include "core/html/canvas/WebGLSharedObject.h"
namespace WebCore {
@@ -50,16 +50,16 @@ WebGLContextGroup::~WebGLContextGroup()
GraphicsContext3D* WebGLContextGroup::getAGraphicsContext3D()
{
ASSERT(!m_contexts.isEmpty());
- HashSet<WebGLRenderingContext*>::iterator it = m_contexts.begin();
+ HashSet<WebGLRenderingContextBase*>::iterator it = m_contexts.begin();
return (*it)->graphicsContext3D();
}
-void WebGLContextGroup::addContext(WebGLRenderingContext* context)
+void WebGLContextGroup::addContext(WebGLRenderingContextBase* context)
{
m_contexts.add(context);
}
-void WebGLContextGroup::removeContext(WebGLRenderingContext* context)
+void WebGLContextGroup::removeContext(WebGLRenderingContextBase* context)
{
// We must call detachAndRemoveAllObjects before removing the last context.
if (m_contexts.size() == 1 && m_contexts.contains(context))
@@ -86,13 +86,13 @@ void WebGLContextGroup::detachAndRemoveAllObjects()
}
}
-void WebGLContextGroup::loseContextGroup(WebGLRenderingContext::LostContextMode mode)
+void WebGLContextGroup::loseContextGroup(WebGLRenderingContextBase::LostContextMode mode)
{
// Detach must happen before loseContextImpl, which destroys the GraphicsContext3D
// and prevents groupObjects from being properly deleted.
detachAndRemoveAllObjects();
- for (HashSet<WebGLRenderingContext*>::iterator it = m_contexts.begin(); it != m_contexts.end(); ++it)
+ for (HashSet<WebGLRenderingContextBase*>::iterator it = m_contexts.begin(); it != m_contexts.end(); ++it)
(*it)->loseContextImpl(mode);
}

Powered by Google App Engine
This is Rietveld 408576698