| Index: extensions/renderer/guest_view/guest_view_internal_custom_bindings.cc
|
| diff --git a/extensions/renderer/guest_view/guest_view_internal_custom_bindings.cc b/extensions/renderer/guest_view/guest_view_internal_custom_bindings.cc
|
| index 5a240f816a61d4918b74a06ce2caef81ee6d2b2b..a474311f8fbe6d900a37bb4043de42d9ddb79576 100644
|
| --- a/extensions/renderer/guest_view/guest_view_internal_custom_bindings.cc
|
| +++ b/extensions/renderer/guest_view/guest_view_internal_custom_bindings.cc
|
| @@ -108,7 +108,7 @@ void GuestViewInternalCustomBindings::AttachGuest(
|
| // Optional Callback Function.
|
| CHECK(args.Length() < 4 || args[3]->IsFunction());
|
|
|
| - int element_instance_id = args[0]->Int32Value();
|
| + int element_instance_id = args[0].As<v8::Int32>()->Value();
|
| // An element instance ID uniquely identifies a GuestViewContainer.
|
| auto guest_view_container =
|
| guest_view::GuestViewContainer::FromID(element_instance_id);
|
| @@ -118,7 +118,7 @@ void GuestViewInternalCustomBindings::AttachGuest(
|
| if (!guest_view_container)
|
| return;
|
|
|
| - int guest_instance_id = args[1]->Int32Value();
|
| + int guest_instance_id = args[1].As<v8::Int32>()->Value();
|
|
|
| scoped_ptr<base::DictionaryValue> params;
|
| {
|
| @@ -154,7 +154,7 @@ void GuestViewInternalCustomBindings::DetachGuest(
|
| // Optional Callback Function.
|
| CHECK(args.Length() < 2 || args[1]->IsFunction());
|
|
|
| - int element_instance_id = args[0]->Int32Value();
|
| + int element_instance_id = args[0].As<v8::Int32>()->Value();
|
| // An element instance ID uniquely identifies a GuestViewContainer.
|
| auto guest_view_container =
|
| guest_view::GuestViewContainer::FromID(element_instance_id);
|
| @@ -186,7 +186,7 @@ void GuestViewInternalCustomBindings::GetContentWindow(
|
| if (!args[0]->IsInt32())
|
| return;
|
|
|
| - int view_id = args[0]->Int32Value();
|
| + int view_id = args[0].As<v8::Int32>()->Value();
|
| if (view_id == MSG_ROUTING_NONE)
|
| return;
|
|
|
| @@ -207,7 +207,7 @@ void GuestViewInternalCustomBindings::GetViewFromID(
|
| CHECK(args.Length() == 1);
|
| // The view ID.
|
| CHECK(args[0]->IsInt32());
|
| - int view_id = args[0]->Int32Value();
|
| + int view_id = args[0].As<v8::Int32>()->Value();
|
|
|
| ViewMap& view_map = weak_view_map.Get();
|
| auto map_entry = view_map.find(view_id);
|
| @@ -228,7 +228,7 @@ void GuestViewInternalCustomBindings::RegisterDestructionCallback(
|
| // Callback function.
|
| CHECK(args[1]->IsFunction());
|
|
|
| - int element_instance_id = args[0]->Int32Value();
|
| + int element_instance_id = args[0].As<v8::Int32>()->Value();
|
| // An element instance ID uniquely identifies a ExtensionsGuestViewContainer
|
| // within a RenderView.
|
| auto guest_view_container = static_cast<ExtensionsGuestViewContainer*>(
|
| @@ -251,7 +251,7 @@ void GuestViewInternalCustomBindings::RegisterElementResizeCallback(
|
| // Callback function.
|
| CHECK(args[1]->IsFunction());
|
|
|
| - int element_instance_id = args[0]->Int32Value();
|
| + int element_instance_id = args[0].As<v8::Int32>()->Value();
|
| // An element instance ID uniquely identifies a ExtensionsGuestViewContainer
|
| // within a RenderView.
|
| auto guest_view_container = static_cast<ExtensionsGuestViewContainer*>(
|
| @@ -277,7 +277,7 @@ void GuestViewInternalCustomBindings::RegisterView(
|
| // A reference to the view object is stored in |weak_view_map| using its view
|
| // ID as the key. The reference is made weak so that it will not extend the
|
| // lifetime of the object.
|
| - int view_id = args[0]->Int32Value();
|
| + int view_id = args[0].As<v8::Int32>()->Value();
|
| auto object =
|
| new v8::Global<v8::Object>(args.GetIsolate(), args[1].As<v8::Object>());
|
| weak_view_map.Get().insert(std::make_pair(view_id, object));
|
|
|