| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2008, 2009, 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2008, 2009, 2011 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 430 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 441 if (node->hasTagName(HTMLNames::iframeTag) && (frame = toHTMLIFrameEleme
nt(node)->contentFrame())) | 441 if (node->hasTagName(HTMLNames::iframeTag) && (frame = toHTMLIFrameEleme
nt(node)->contentFrame())) |
| 442 return toV8(frame->domWindow(), creationContext, isolate); | 442 return toV8(frame->domWindow(), creationContext, isolate); |
| 443 return toV8(node, creationContext, isolate); | 443 return toV8(node, creationContext, isolate); |
| 444 } | 444 } |
| 445 return toV8(items.release(), creationContext, isolate); | 445 return toV8(items.release(), creationContext, isolate); |
| 446 } | 446 } |
| 447 | 447 |
| 448 static void getter(v8::Local<v8::String> property, const v8::PropertyCallbackInf
o<v8::Value>& info) | 448 static void getter(v8::Local<v8::String> property, const v8::PropertyCallbackInf
o<v8::Value>& info) |
| 449 { | 449 { |
| 450 // FIXME: Consider passing StringImpl directly. | 450 // FIXME: Consider passing StringImpl directly. |
| 451 AtomicString name = toWebCoreAtomicString(property); | 451 AtomicString name = toCoreAtomicString(property); |
| 452 HTMLDocument* htmlDocument = V8HTMLDocument::toNative(info.Holder()); | 452 HTMLDocument* htmlDocument = V8HTMLDocument::toNative(info.Holder()); |
| 453 ASSERT(htmlDocument); | 453 ASSERT(htmlDocument); |
| 454 v8::Handle<v8::Value> result = getNamedProperty(htmlDocument, name, info.Hol
der(), info.GetIsolate()); | 454 v8::Handle<v8::Value> result = getNamedProperty(htmlDocument, name, info.Hol
der(), info.GetIsolate()); |
| 455 if (!result.IsEmpty()) { | 455 if (!result.IsEmpty()) { |
| 456 v8SetReturnValue(info, result); | 456 v8SetReturnValue(info, result); |
| 457 return; | 457 return; |
| 458 } | 458 } |
| 459 v8::Handle<v8::Value> prototype = info.Holder()->GetPrototype(); | 459 v8::Handle<v8::Value> prototype = info.Holder()->GetPrototype(); |
| 460 if (prototype->IsObject()) { | 460 if (prototype->IsObject()) { |
| 461 v8SetReturnValue(info, prototype.As<v8::Object>()->Get(property)); | 461 v8SetReturnValue(info, prototype.As<v8::Object>()->Get(property)); |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 501 void V8WindowShell::updateSecurityOrigin() | 501 void V8WindowShell::updateSecurityOrigin() |
| 502 { | 502 { |
| 503 ASSERT(m_world->isMainWorld()); | 503 ASSERT(m_world->isMainWorld()); |
| 504 if (!m_contextHolder) | 504 if (!m_contextHolder) |
| 505 return; | 505 return; |
| 506 v8::HandleScope handleScope(m_isolate); | 506 v8::HandleScope handleScope(m_isolate); |
| 507 setSecurityToken(); | 507 setSecurityToken(); |
| 508 } | 508 } |
| 509 | 509 |
| 510 } // WebCore | 510 } // WebCore |
| OLD | NEW |