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

Side by Side Diff: components/mus/public/cpp/lib/context_provider.cc

Issue 1936423002: Remove unused locks in mus ContextProvider classes (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed typo 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 unified diff | Download patch
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 "components/mus/public/cpp/context_provider.h" 5 #include "components/mus/public/cpp/context_provider.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "mojo/gles2/gles2_context.h" 10 #include "mojo/gles2/gles2_context.h"
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 gpu::Capabilities capabilities; 47 gpu::Capabilities capabilities;
48 // Enabled the CHROMIUM_image extension to use GpuMemoryBuffers. The 48 // Enabled the CHROMIUM_image extension to use GpuMemoryBuffers. The
49 // implementation of which is used in CommandBufferDriver. 49 // implementation of which is used in CommandBufferDriver.
50 capabilities.image = true; 50 capabilities.image = true;
51 return capabilities; 51 return capabilities;
52 } 52 }
53 53
54 void ContextProvider::SetupLock() {} 54 void ContextProvider::SetupLock() {}
55 55
56 base::Lock* ContextProvider::GetLock() { 56 base::Lock* ContextProvider::GetLock() {
57 return &context_lock_; 57 // This context provider is not used on multiple threads.
58 NOTREACHED();
59 return nullptr;
58 } 60 }
59 61
60 ContextProvider::~ContextProvider() { 62 ContextProvider::~ContextProvider() {
61 context_gl_.reset(); 63 context_gl_.reset();
62 if (context_) 64 if (context_)
63 MojoGLES2DestroyContext(context_); 65 MojoGLES2DestroyContext(context_);
64 } 66 }
65 67
66 void ContextProvider::ContextLost() {} 68 void ContextProvider::ContextLost() {}
67 69
68 } // namespace mus 70 } // namespace mus
OLDNEW
« no previous file with comments | « components/mus/public/cpp/context_provider.h ('k') | components/mus/surfaces/surfaces_context_provider.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698