diff options
author | danakj <danakj@chromium.org> | 2016-03-24 20:11:58 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-03-25 03:13:39 +0000 |
commit | 6d1bfc385d5f190c3b37e8df0793ae75af5ae6f5 (patch) | |
tree | 98e6e6494387fc2a87e0f60f6b4892fe1de2919c /gpu | |
parent | e18e7a6d2e1971e9b50b0ca3fe1fc9f17b264193 (diff) | |
download | chromium_src-6d1bfc385d5f190c3b37e8df0793ae75af5ae6f5.zip chromium_src-6d1bfc385d5f190c3b37e8df0793ae75af5ae6f5.tar.gz chromium_src-6d1bfc385d5f190c3b37e8df0793ae75af5ae6f5.tar.bz2 |
Make lost context callback a base::Closure thru the WGC3DProvider.
This makes the WebGraphicsContext3DProvider have a method to set a lost
context callback, and has that method take a SameThreadClosure, wrapped
inside a WebClosure.
The SameThreadClosure is converted to a base::Closure and passed thru
by the WebGraphicsContext3DProviderImpl (which lives in content/) to
the actual ContextProvider::SetLostContextCallback() method. This skips
going through WebGraphicsContext3D in blink for the callback, though
internally the provider does call the same method on
WebGraphicsContext3DImpl, which blink used to hijack from it later.
This removes the setter method from the WebGraphicsContext3D public API
exposed to blink.
It introduces a new public/platform/callback/ directory for the
WebClosure in order to make separate DEPS rules for this class. It
makes use of base::Bind/Callback which has previously not been allowed
in blink, though only to wrap a WTF::SameThreadClosure.
It also makes use of base/logging.h directly (previously we were unable
to use DCHECK in public/platform since the files there build both
with and without BLINK_IMPLEMENTATION and in the without case wtf/ is
not available to be included.
It also uses scoped_ptr since that is nicer than raw pointers and
base::Callback understands it but doesn't understand OwnPtr.
R=kbr@chromium.org, kinuko@chromium.org, piman@chromium.org
BUG=584497
CQ_INCLUDE_TRYBOTS=tryserver.chromium.win:win_optional_gpu_tests_rel
Review URL: https://codereview.chromium.org/1830033003
Cr-Commit-Position: refs/heads/master@{#383233}
Diffstat (limited to 'gpu')
-rw-r--r-- | gpu/blink/webgraphicscontext3d_impl.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gpu/blink/webgraphicscontext3d_impl.h b/gpu/blink/webgraphicscontext3d_impl.h index db08260..071e508 100644 --- a/gpu/blink/webgraphicscontext3d_impl.h +++ b/gpu/blink/webgraphicscontext3d_impl.h @@ -52,7 +52,7 @@ class GPU_BLINK_EXPORT WebGraphicsContext3DImpl blink::WebGLId shader) override; void setContextLostCallback( - WebGraphicsContext3D::WebGraphicsContextLostCallback* callback) override; + WebGraphicsContext3D::WebGraphicsContextLostCallback* callback); void setErrorMessageCallback( WebGraphicsContext3D::WebGraphicsErrorMessageCallback* callback) override; |