| Index: webkit/port/bindings/v8/v8_custom.cpp
|
| ===================================================================
|
| --- webkit/port/bindings/v8/v8_custom.cpp (revision 2825)
|
| +++ webkit/port/bindings/v8/v8_custom.cpp (working copy)
|
| @@ -2600,16 +2600,18 @@
|
| CALLBACK_FUNC_DECL(HTMLDocumentWrite) {
|
| INC_STATS(L"DOM.HTMLDocument.write()");
|
| HTMLDocument* imp = V8Proxy::DOMWrapperToNode<HTMLDocument>(args.Holder());
|
| - imp->write(WriteHelper_GetString(args),
|
| - V8Proxy::retrieveWindow()->document());
|
| + Frame* frame = V8Proxy::retrieveActiveFrame();
|
| + ASSERT(frame);
|
| + imp->write(WriteHelper_GetString(args), frame->document());
|
| return v8::Undefined();
|
| }
|
|
|
| CALLBACK_FUNC_DECL(HTMLDocumentWriteln) {
|
| INC_STATS(L"DOM.HTMLDocument.writeln()");
|
| HTMLDocument* imp = V8Proxy::DOMWrapperToNode<HTMLDocument>(args.Holder());
|
| - imp->writeln(WriteHelper_GetString(args),
|
| - V8Proxy::retrieveWindow()->document());
|
| + Frame* frame = V8Proxy::retrieveActiveFrame();
|
| + ASSERT(frame);
|
| + imp->writeln(WriteHelper_GetString(args), frame->document());
|
| return v8::Undefined();
|
| }
|
|
|
|
|