| Index: chrome/renderer/extensions/miscellaneous_bindings.cc
|
| diff --git a/chrome/renderer/extensions/miscellaneous_bindings.cc b/chrome/renderer/extensions/miscellaneous_bindings.cc
|
| index da4c58dce0768c60ec016dc45ae07d32ec29043f..37c10201f0bfc40f3c24e982a5817aee6941a675 100644
|
| --- a/chrome/renderer/extensions/miscellaneous_bindings.cc
|
| +++ b/chrome/renderer/extensions/miscellaneous_bindings.cc
|
| @@ -68,8 +68,9 @@ const char kReceivingEndDoesntExistError[] =
|
|
|
| class ExtensionImpl : public extensions::ChromeV8Extension {
|
| public:
|
| - explicit ExtensionImpl(extensions::Dispatcher* dispatcher)
|
| - : extensions::ChromeV8Extension(dispatcher) {
|
| + explicit ExtensionImpl(extensions::Dispatcher* dispatcher,
|
| + v8::Handle<v8::Context> context)
|
| + : extensions::ChromeV8Extension(dispatcher, context) {
|
| RouteStaticFunction("CloseChannel", &CloseChannel);
|
| RouteStaticFunction("PortAddRef", &PortAddRef);
|
| RouteStaticFunction("PortRelease", &PortRelease);
|
| @@ -81,7 +82,8 @@ class ExtensionImpl : public extensions::ChromeV8Extension {
|
|
|
| // Sends a message along the given channel.
|
| static v8::Handle<v8::Value> PostMessage(const v8::Arguments& args) {
|
| - content::RenderView* renderview = GetCurrentRenderView();
|
| + ExtensionImpl* self = GetFromArguments<ExtensionImpl>(args);
|
| + content::RenderView* renderview = self->GetRenderView();
|
| if (!renderview)
|
| return v8::Undefined();
|
|
|
| @@ -181,8 +183,10 @@ class ExtensionImpl : public extensions::ChromeV8Extension {
|
|
|
| namespace extensions {
|
|
|
| -ChromeV8Extension* MiscellaneousBindings::Get(Dispatcher* dispatcher) {
|
| - return new ExtensionImpl(dispatcher);
|
| +ChromeV8Extension* MiscellaneousBindings::Get(
|
| + Dispatcher* dispatcher,
|
| + v8::Handle<v8::Context> context) {
|
| + return new ExtensionImpl(dispatcher, context);
|
| }
|
|
|
| // static
|
|
|