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

Unified Diff: gpu/command_buffer/service/gl_context_virtual.cc

Issue 1998723002: Move code in ui/gl/* from gfx:: to gl:: (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 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 side-by-side diff with in-line comments
Download patch
Index: gpu/command_buffer/service/gl_context_virtual.cc
diff --git a/gpu/command_buffer/service/gl_context_virtual.cc b/gpu/command_buffer/service/gl_context_virtual.cc
index 11138fe1d5816803eb2ed2cf43b4e996051aaee5..4c2776d4c8793c0d49372b952ce154f81682480f 100644
--- a/gpu/command_buffer/service/gl_context_virtual.cc
+++ b/gpu/command_buffer/service/gl_context_virtual.cc
@@ -15,17 +15,15 @@
namespace gpu {
-GLContextVirtual::GLContextVirtual(
- gfx::GLShareGroup* share_group,
- gfx::GLContext* shared_context,
- base::WeakPtr<gles2::GLES2Decoder> decoder)
- : GLContext(share_group),
- shared_context_(shared_context),
- decoder_(decoder) {
-}
-
-bool GLContextVirtual::Initialize(
- gfx::GLSurface* compatible_surface, gfx::GpuPreference gpu_preference) {
+GLContextVirtual::GLContextVirtual(gl::GLShareGroup* share_group,
+ gl::GLContext* shared_context,
+ base::WeakPtr<gles2::GLES2Decoder> decoder)
+ : GLContext(share_group),
+ shared_context_(shared_context),
+ decoder_(decoder) {}
+
+bool GLContextVirtual::Initialize(gl::GLSurface* compatible_surface,
+ gl::GpuPreference gpu_preference) {
SetGLStateRestorer(new GLStateRestorerImpl(decoder_));
// Virtual contexts obviously can't make a context that is compatible
@@ -50,7 +48,7 @@ void GLContextVirtual::Destroy() {
shared_context_ = NULL;
}
-bool GLContextVirtual::MakeCurrent(gfx::GLSurface* surface) {
+bool GLContextVirtual::MakeCurrent(gl::GLSurface* surface) {
if (decoder_.get())
return shared_context_->MakeVirtuallyCurrent(this, surface);
@@ -58,14 +56,14 @@ bool GLContextVirtual::MakeCurrent(gfx::GLSurface* surface) {
return false;
}
-void GLContextVirtual::ReleaseCurrent(gfx::GLSurface* surface) {
+void GLContextVirtual::ReleaseCurrent(gl::GLSurface* surface) {
if (IsCurrent(surface)) {
shared_context_->OnReleaseVirtuallyCurrent(this);
shared_context_->ReleaseCurrent(surface);
}
}
-bool GLContextVirtual::IsCurrent(gfx::GLSurface* surface) {
+bool GLContextVirtual::IsCurrent(gl::GLSurface* surface) {
// If it's a real surface it needs to be current.
if (surface &&
!surface->IsOffscreen())
@@ -79,7 +77,7 @@ void* GLContextVirtual::GetHandle() {
return shared_context_->GetHandle();
}
-scoped_refptr<gfx::GPUTimingClient> GLContextVirtual::CreateGPUTimingClient() {
+scoped_refptr<gl::GPUTimingClient> GLContextVirtual::CreateGPUTimingClient() {
return shared_context_->CreateGPUTimingClient();
}
« no previous file with comments | « gpu/command_buffer/service/gl_context_virtual.h ('k') | gpu/command_buffer/service/gl_context_virtual_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698