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

Side by Side Diff: content/browser/android/in_process/context_provider_in_process.cc

Issue 1504913002: Revert of Enforce marking "override" for functions overriding Blink. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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
« no previous file with comments | « components/test_runner/mock_web_theme_engine.h ('k') | content/child/blink_platform_impl.h » ('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) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 "content/browser/android/in_process/context_provider_in_process.h" 5 #include "content/browser/android/in_process/context_provider_in_process.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/callback_helpers.h" 8 #include "base/callback_helpers.h"
9 #include "base/strings/stringprintf.h" 9 #include "base/strings/stringprintf.h"
10 #include "cc/output/managed_memory_policy.h" 10 #include "cc/output/managed_memory_policy.h"
11 #include "content/common/gpu/client/grcontext_for_webgraphicscontext3d.h" 11 #include "content/common/gpu/client/grcontext_for_webgraphicscontext3d.h"
12 #include "gpu/blink/webgraphicscontext3d_in_process_command_buffer_impl.h" 12 #include "gpu/blink/webgraphicscontext3d_in_process_command_buffer_impl.h"
13 #include "gpu/command_buffer/client/gles2_implementation.h" 13 #include "gpu/command_buffer/client/gles2_implementation.h"
14 #include "third_party/skia/include/gpu/GrContext.h" 14 #include "third_party/skia/include/gpu/GrContext.h"
15 15
16 using gpu_blink::WebGraphicsContext3DInProcessCommandBufferImpl; 16 using gpu_blink::WebGraphicsContext3DInProcessCommandBufferImpl;
17 17
18 namespace content { 18 namespace content {
19 19
20 class ContextProviderInProcess::LostContextCallbackProxy 20 class ContextProviderInProcess::LostContextCallbackProxy
21 : public blink::WebGraphicsContext3D::WebGraphicsContextLostCallback { 21 : public blink::WebGraphicsContext3D::WebGraphicsContextLostCallback {
22 public: 22 public:
23 explicit LostContextCallbackProxy(ContextProviderInProcess* provider) 23 explicit LostContextCallbackProxy(ContextProviderInProcess* provider)
24 : provider_(provider) { 24 : provider_(provider) {
25 provider_->WebContext3DImpl()->setContextLostCallback(this); 25 provider_->WebContext3DImpl()->setContextLostCallback(this);
26 } 26 }
27 27
28 ~LostContextCallbackProxy() override { 28 virtual ~LostContextCallbackProxy() {
29 provider_->WebContext3DImpl()->setContextLostCallback(NULL); 29 provider_->WebContext3DImpl()->setContextLostCallback(NULL);
30 } 30 }
31 31
32 void onContextLost() override { 32 virtual void onContextLost() {
33 provider_->OnLostContext(); 33 provider_->OnLostContext();
34 } 34 }
35 35
36 private: 36 private:
37 ContextProviderInProcess* provider_; 37 ContextProviderInProcess* provider_;
38 }; 38 };
39 39
40 // static 40 // static
41 scoped_refptr<ContextProviderInProcess> ContextProviderInProcess::Create( 41 scoped_refptr<ContextProviderInProcess> ContextProviderInProcess::Create(
42 scoped_ptr<WebGraphicsContext3DInProcessCommandBufferImpl> context3d, 42 scoped_ptr<WebGraphicsContext3DInProcessCommandBufferImpl> context3d,
(...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after
187 187
188 void ContextProviderInProcess::SetLostContextCallback( 188 void ContextProviderInProcess::SetLostContextCallback(
189 const LostContextCallback& lost_context_callback) { 189 const LostContextCallback& lost_context_callback) {
190 DCHECK(context_thread_checker_.CalledOnValidThread()); 190 DCHECK(context_thread_checker_.CalledOnValidThread());
191 DCHECK(lost_context_callback_.is_null() || 191 DCHECK(lost_context_callback_.is_null() ||
192 lost_context_callback.is_null()); 192 lost_context_callback.is_null());
193 lost_context_callback_ = lost_context_callback; 193 lost_context_callback_ = lost_context_callback;
194 } 194 }
195 195
196 } // namespace content 196 } // namespace content
OLDNEW
« no previous file with comments | « components/test_runner/mock_web_theme_engine.h ('k') | content/child/blink_platform_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698