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

Side by Side Diff: mojo/apps/js/bindings/gl/context.cc

Issue 218193002: Mojo: Move C gles2 header files to mojo/public/c/gles2. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebased Created 6 years, 8 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 | Annotate | Revision Log
« no previous file with comments | « mojo/apps/js/bindings/gl/context.h ('k') | mojo/examples/aura_demo/window_tree_host_mojo.cc » ('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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 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 "mojo/apps/js/bindings/gl/context.h" 5 #include "mojo/apps/js/bindings/gl/context.h"
6 6
7 #include <GLES2/gl2.h> 7 #include <GLES2/gl2.h>
8 8
9 #include "gin/arguments.h" 9 #include "gin/arguments.h"
10 #include "gin/array_buffer.h" 10 #include "gin/array_buffer.h"
11 #include "gin/object_template_builder.h" 11 #include "gin/object_template_builder.h"
12 #include "gin/per_context_data.h" 12 #include "gin/per_context_data.h"
13 #include "mojo/public/gles2/gles2.h" 13 #include "mojo/public/c/gles2/gles2.h"
14 14
15 namespace gin { 15 namespace gin {
16 template<> 16 template<>
17 struct Converter<GLboolean> { 17 struct Converter<GLboolean> {
18 static bool FromV8(v8::Isolate* isolate, v8::Handle<v8::Value> val, 18 static bool FromV8(v8::Isolate* isolate, v8::Handle<v8::Value> val,
19 GLboolean* out) { 19 GLboolean* out) {
20 bool bool_val = false; 20 bool bool_val = false;
21 if (!Converter<bool>::FromV8(isolate, val, &bool_val)) 21 if (!Converter<bool>::FromV8(isolate, val, &bool_val))
22 return false; 22 return false;
23 *out = static_cast<GLboolean>(bool_val); 23 *out = static_cast<GLboolean>(bool_val);
(...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after
178 runner_->Call(callback, runner_->global(), 0, NULL); 178 runner_->Call(callback, runner_->global(), 0, NULL);
179 } 179 }
180 180
181 void Context::ContextLostThunk(void* closure) { 181 void Context::ContextLostThunk(void* closure) {
182 static_cast<Context*>(closure)->ContextLost(); 182 static_cast<Context*>(closure)->ContextLost();
183 } 183 }
184 184
185 } // namespace gl 185 } // namespace gl
186 } // namespace js 186 } // namespace js
187 } // namespace mojo 187 } // namespace mojo
OLDNEW
« no previous file with comments | « mojo/apps/js/bindings/gl/context.h ('k') | mojo/examples/aura_demo/window_tree_host_mojo.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698