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

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

Issue 131153007: Send size to NativeViewportClient::OnCreated instead of GLES2Client::DidCreateContext (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase, fix various issues Created 6 years, 10 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/codec.js ('k') | mojo/apps/js/bindings/gl/context.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 #ifndef MOJO_APPS_JS_BINDINGS_GL_CONTEXT_H_ 5 #ifndef MOJO_APPS_JS_BINDINGS_GL_CONTEXT_H_
6 #define MOJO_APPS_JS_BINDINGS_GL_CONTEXT_H_ 6 #define MOJO_APPS_JS_BINDINGS_GL_CONTEXT_H_
7 7
8 #include <GLES2/gl2.h> 8 #include <GLES2/gl2.h>
9 9
10 #include "base/memory/weak_ptr.h" 10 #include "base/memory/weak_ptr.h"
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 55
56 private: 56 private:
57 virtual gin::ObjectTemplateBuilder GetObjectTemplateBuilder( 57 virtual gin::ObjectTemplateBuilder GetObjectTemplateBuilder(
58 v8::Isolate* isolate) OVERRIDE; 58 v8::Isolate* isolate) OVERRIDE;
59 59
60 explicit Context(v8::Isolate* isolate, 60 explicit Context(v8::Isolate* isolate,
61 mojo::Handle handle, 61 mojo::Handle handle,
62 v8::Handle<v8::Function> did_create_callback); 62 v8::Handle<v8::Function> did_create_callback);
63 virtual ~Context(); 63 virtual ~Context();
64 64
65 void DidCreateContext(uint32_t width, uint32_t height); 65 void DidCreateContext();
66 static void DidCreateContextThunk( 66 static void DidCreateContextThunk(void* closure);
67 void* closure,
68 uint32_t width,
69 uint32_t height);
70 void ContextLost(); 67 void ContextLost();
71 static void ContextLostThunk(void* closure); 68 static void ContextLostThunk(void* closure);
72 69
73 base::WeakPtr<gin::Runner> runner_; 70 base::WeakPtr<gin::Runner> runner_;
74 v8::Persistent<v8::Function> did_create_callback_; 71 v8::Persistent<v8::Function> did_create_callback_;
75 MojoGLES2Context context_; 72 MojoGLES2Context context_;
76 }; 73 };
77 74
78 } // namespace gl 75 } // namespace gl
79 } // namespace js 76 } // namespace js
80 } // namespace mojo 77 } // namespace mojo
81 78
82 #endif // MOJO_APPS_JS_BINDINGS_GL_CONTEXT_H_ 79 #endif // MOJO_APPS_JS_BINDINGS_GL_CONTEXT_H_
OLDNEW
« no previous file with comments | « mojo/apps/js/bindings/codec.js ('k') | mojo/apps/js/bindings/gl/context.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698