| Index: Source/bindings/v8/custom/V8WindowCustom.cpp
|
| diff --git a/Source/bindings/v8/custom/V8WindowCustom.cpp b/Source/bindings/v8/custom/V8WindowCustom.cpp
|
| index 2ff08647cb1469fea6e0d016e832d817c9850746..d2cb0cfbf5b7320d1d22f2c3d89ff2f1895b3696 100644
|
| --- a/Source/bindings/v8/custom/V8WindowCustom.cpp
|
| +++ b/Source/bindings/v8/custom/V8WindowCustom.cpp
|
| @@ -85,7 +85,7 @@ void WindowSetTimeoutImpl(const v8::FunctionCallbackInfo<v8::Value>& info, bool
|
| ExecutionContext* scriptContext = static_cast<ExecutionContext*>(imp->document());
|
|
|
| if (!scriptContext) {
|
| - exceptionState.throwUninformativeAndGenericDOMException(InvalidAccessError);
|
| + exceptionState.throwDOMException(InvalidAccessError, "No script context is available in which to execute the script.");
|
| return;
|
| }
|
|
|
| @@ -161,7 +161,7 @@ void V8Window::eventAttributeGetterCustom(const v8::PropertyCallbackInfo<v8::Val
|
| return;
|
|
|
| Frame* frame = V8Window::toNative(holder)->frame();
|
| - ExceptionState exceptionState(info.Holder(), info.GetIsolate());
|
| + ExceptionState exceptionState(ExceptionState::GetterContext, "event", "Window", info.Holder(), info.GetIsolate());
|
| if (!BindingSecurity::shouldAllowAccessToFrame(frame, exceptionState)) {
|
| exceptionState.throwIfNeeded();
|
| return;
|
| @@ -186,7 +186,7 @@ void V8Window::eventAttributeSetterCustom(v8::Local<v8::Value> value, const v8::
|
| return;
|
|
|
| Frame* frame = V8Window::toNative(holder)->frame();
|
| - ExceptionState exceptionState(info.Holder(), info.GetIsolate());
|
| + ExceptionState exceptionState(ExceptionState::SetterContext, "event", "Window", info.Holder(), info.GetIsolate());
|
| if (!BindingSecurity::shouldAllowAccessToFrame(frame, exceptionState)) {
|
| exceptionState.throwIfNeeded();
|
| return;
|
| @@ -204,7 +204,7 @@ void V8Window::eventAttributeSetterCustom(v8::Local<v8::Value> value, const v8::
|
| void V8Window::frameElementAttributeGetterCustom(const v8::PropertyCallbackInfo<v8::Value>& info)
|
| {
|
| DOMWindow* imp = V8Window::toNative(info.Holder());
|
| - ExceptionState exceptionState(info.Holder(), info.GetIsolate());
|
| + ExceptionState exceptionState(ExceptionState::GetterContext, "frame", "Window", info.Holder(), info.GetIsolate());
|
| if (!BindingSecurity::shouldAllowAccessToNode(imp->frameElement(), exceptionState)) {
|
| v8SetReturnValueNull(info);
|
| exceptionState.throwIfNeeded();
|
| @@ -222,7 +222,7 @@ void V8Window::frameElementAttributeGetterCustom(const v8::PropertyCallbackInfo<
|
| void V8Window::openerAttributeSetterCustom(v8::Local<v8::Value> value, const v8::PropertyCallbackInfo<void>& info)
|
| {
|
| DOMWindow* imp = V8Window::toNative(info.Holder());
|
| - ExceptionState exceptionState(info.Holder(), info.GetIsolate());
|
| + ExceptionState exceptionState(ExceptionState::SetterContext, "opener", "Window", info.Holder(), info.GetIsolate());
|
| if (!BindingSecurity::shouldAllowAccessToFrame(imp->frame(), exceptionState)) {
|
| exceptionState.throwIfNeeded();
|
| return;
|
| @@ -296,7 +296,7 @@ void V8Window::postMessageMethodCustom(const v8::FunctionCallbackInfo<v8::Value>
|
| if (didThrow)
|
| return;
|
|
|
| - ExceptionState exceptionState(info.Holder(), info.GetIsolate());
|
| + ExceptionState exceptionState(ExceptionState::ExecutionContext, "postMessage", "Window", info.Holder(), info.GetIsolate());
|
| window->postMessage(message.release(), &portArray, targetOrigin, source, exceptionState);
|
| exceptionState.throwIfNeeded();
|
| }
|
| @@ -360,7 +360,7 @@ static void setUpDialog(DOMWindow* dialog, void* handler)
|
| void V8Window::showModalDialogMethodCustom(const v8::FunctionCallbackInfo<v8::Value>& info)
|
| {
|
| DOMWindow* impl = V8Window::toNative(info.Holder());
|
| - ExceptionState exceptionState(info.Holder(), info.GetIsolate());
|
| + ExceptionState exceptionState(ExceptionState::ExecutionContext, "showModalDialog", "Window", info.Holder(), info.GetIsolate());
|
| if (!BindingSecurity::shouldAllowAccessToFrame(impl->frame(), exceptionState)) {
|
| exceptionState.throwIfNeeded();
|
| return;
|
| @@ -379,7 +379,7 @@ void V8Window::showModalDialogMethodCustom(const v8::FunctionCallbackInfo<v8::Va
|
| void V8Window::openMethodCustom(const v8::FunctionCallbackInfo<v8::Value>& info)
|
| {
|
| DOMWindow* impl = V8Window::toNative(info.Holder());
|
| - ExceptionState exceptionState(info.Holder(), info.GetIsolate());
|
| + ExceptionState exceptionState(ExceptionState::ExecutionContext, "open", "Window", info.Holder(), info.GetIsolate());
|
| if (!BindingSecurity::shouldAllowAccessToFrame(impl->frame(), exceptionState)) {
|
| exceptionState.throwIfNeeded();
|
| return;
|
| @@ -447,7 +447,7 @@ void V8Window::namedPropertyGetterCustom(v8::Local<v8::String> name, const v8::P
|
|
|
| void V8Window::setTimeoutMethodCustom(const v8::FunctionCallbackInfo<v8::Value>& info)
|
| {
|
| - ExceptionState exceptionState(info.Holder(), info.GetIsolate());
|
| + ExceptionState exceptionState(ExceptionState::ExecutionContext, "setTimeout", "Window", info.Holder(), info.GetIsolate());
|
| WindowSetTimeoutImpl(info, true, exceptionState);
|
| exceptionState.throwIfNeeded();
|
| }
|
| @@ -455,7 +455,7 @@ void V8Window::setTimeoutMethodCustom(const v8::FunctionCallbackInfo<v8::Value>&
|
|
|
| void V8Window::setIntervalMethodCustom(const v8::FunctionCallbackInfo<v8::Value>& info)
|
| {
|
| - ExceptionState exceptionState(info.Holder(), info.GetIsolate());
|
| + ExceptionState exceptionState(ExceptionState::ExecutionContext, "setInterval", "Window", info.Holder(), info.GetIsolate());
|
| WindowSetTimeoutImpl(info, false, exceptionState);
|
| exceptionState.throwIfNeeded();
|
| }
|
|
|