summaryrefslogtreecommitdiffstats
path: root/WebKit/chromium/src/WebBindings.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'WebKit/chromium/src/WebBindings.cpp')
-rw-r--r--WebKit/chromium/src/WebBindings.cpp11
1 files changed, 7 insertions, 4 deletions
diff --git a/WebKit/chromium/src/WebBindings.cpp b/WebKit/chromium/src/WebBindings.cpp
index 0bc67b6..04f2f85 100644
--- a/WebKit/chromium/src/WebBindings.cpp
+++ b/WebKit/chromium/src/WebBindings.cpp
@@ -44,9 +44,12 @@
#include "MouseEvent.h"
#include "NPV8Object.h" // for PrivateIdentifier
#include "Range.h"
+#include "V8BindingState.h"
#include "V8DOMWrapper.h"
+#include "V8Event.h"
#include "V8Helpers.h"
#include "V8Proxy.h"
+#include "V8Range.h"
#elif USE(JSC)
#include "bridge/c/c_utility.h"
#endif
@@ -223,20 +226,20 @@ static bool getDragDataImpl(NPObject* npobj, int* eventId, WebDragData* data)
// Get the current WebCore event.
v8::Handle<v8::Value> currentEvent(getEvent(context));
- Event* event = V8DOMWrapper::convertToNativeEvent(currentEvent);
+ Event* event = V8Event::toNative(v8::Handle<v8::Object>::Cast(currentEvent));
if (!event)
return false;
// Check that the given npobj is that event.
V8NPObject* object = reinterpret_cast<V8NPObject*>(npobj);
- Event* given = V8DOMWrapper::convertToNativeEvent(object->v8Object);
+ Event* given = V8Event::toNative(object->v8Object);
if (given != event)
return false;
// Check the execution frames are same origin.
V8Proxy* current = V8Proxy::retrieve(V8Proxy::retrieveFrameForCurrentContext());
Frame* frame = V8Proxy::retrieveFrame(context);
- if (!current || !current->canAccessFrame(frame, false))
+ if (!current || !V8BindingSecurity::canAccessFrame(V8BindingState::Only(), frame, false))
return false;
const EventNames& names(eventNames());
@@ -284,7 +287,7 @@ static bool getRangeImpl(NPObject* npobj, WebRange* range)
if (V8ClassIndex::RANGE != V8DOMWrapper::domWrapperType(v8object))
return false;
- Range* native = V8DOMWrapper::convertToNativeObject<WebCore::Range>(V8ClassIndex::RANGE, v8object);
+ Range* native = V8Range::toNative(v8object);
if (!native)
return false;