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

Side by Side Diff: chrome/renderer/extensions/chrome_v8_context.h

Issue 15091002: Lazily load API schemas from resource files and convert all APIs to features (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix chromeos tests Created 7 years, 6 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 CHROME_RENDERER_EXTENSIONS_CHROME_V8_CONTEXT_H_ 5 #ifndef CHROME_RENDERER_EXTENSIONS_CHROME_V8_CONTEXT_H_
6 #define CHROME_RENDERER_EXTENSIONS_CHROME_V8_CONTEXT_H_ 6 #define CHROME_RENDERER_EXTENSIONS_CHROME_V8_CONTEXT_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 ModuleSystem* module_system() { return module_system_.get(); } 68 ModuleSystem* module_system() { return module_system_.get(); }
69 69
70 // Returns the ID of the extension associated with this context, or empty 70 // Returns the ID of the extension associated with this context, or empty
71 // string if there is no such extension. 71 // string if there is no such extension.
72 std::string GetExtensionID(); 72 std::string GetExtensionID();
73 73
74 // Returns the RenderView associated with this context. Can return NULL if the 74 // Returns the RenderView associated with this context. Can return NULL if the
75 // context is in the process of being destroyed. 75 // context is in the process of being destroyed.
76 content::RenderView* GetRenderView() const; 76 content::RenderView* GetRenderView() const;
77 77
78 // Get the URL of this context's web frame.
79 GURL GetURL() const;
80
78 // Runs |function| with appropriate scopes. Doesn't catch exceptions, callers 81 // Runs |function| with appropriate scopes. Doesn't catch exceptions, callers
79 // must do that if they want. 82 // must do that if they want.
80 // 83 //
81 // USE THIS METHOD RATHER THAN v8::Function::Call WHEREVER POSSIBLE. 84 // USE THIS METHOD RATHER THAN v8::Function::Call WHEREVER POSSIBLE.
82 v8::Local<v8::Value> CallFunction(v8::Handle<v8::Function> function, 85 v8::Local<v8::Value> CallFunction(v8::Handle<v8::Function> function,
83 int argc, 86 int argc,
84 v8::Handle<v8::Value> argv[]) const; 87 v8::Handle<v8::Value> argv[]) const;
85 88
86 // Fires the onunload event on the unload_event module. 89 // Fires the onunload event on the unload_event module.
87 void DispatchOnUnloadEvent(); 90 void DispatchOnUnloadEvent();
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
122 125
123 // Owns and structures the JS that is injected to set up extension bindings. 126 // Owns and structures the JS that is injected to set up extension bindings.
124 scoped_ptr<ModuleSystem> module_system_; 127 scoped_ptr<ModuleSystem> module_system_;
125 128
126 DISALLOW_COPY_AND_ASSIGN(ChromeV8Context); 129 DISALLOW_COPY_AND_ASSIGN(ChromeV8Context);
127 }; 130 };
128 131
129 } // namespace extensions 132 } // namespace extensions
130 133
131 #endif // CHROME_RENDERER_EXTENSIONS_CHROME_V8_CONTEXT_H_ 134 #endif // CHROME_RENDERER_EXTENSIONS_CHROME_V8_CONTEXT_H_
OLDNEW
« no previous file with comments | « chrome/renderer/extensions/api_definitions_natives.cc ('k') | chrome/renderer/extensions/chrome_v8_context.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698