| 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 470 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 481 token = frameSecurityToken + token; | 481 token = frameSecurityToken + token; |
| 482 } | 482 } |
| 483 | 483 |
| 484 // NOTE: V8 does identity comparison in fast path, must use a symbol | 484 // NOTE: V8 does identity comparison in fast path, must use a symbol |
| 485 // as the security token. | 485 // as the security token. |
| 486 context->SetSecurityToken(v8AtomicString(m_isolate, token)); | 486 context->SetSecurityToken(v8AtomicString(m_isolate, token)); |
| 487 } | 487 } |
| 488 | 488 |
| 489 void WindowProxy::updateDocument() { | 489 void WindowProxy::updateDocument() { |
| 490 ASSERT(m_world->isMainWorld()); | 490 ASSERT(m_world->isMainWorld()); |
| 491 if (!isGlobalInitialized()) | |
| 492 return; | |
| 493 if (!isContextInitialized()) | 491 if (!isContextInitialized()) |
| 494 return; | 492 return; |
| 495 updateActivityLogger(); | 493 updateActivityLogger(); |
| 496 updateDocumentProperty(); | 494 updateDocumentProperty(); |
| 497 updateSecurityOrigin(m_frame->securityContext()->getSecurityOrigin()); | 495 updateSecurityOrigin(m_frame->securityContext()->getSecurityOrigin()); |
| 498 } | 496 } |
| 499 | 497 |
| 500 static v8::Local<v8::Value> getNamedProperty( | 498 static v8::Local<v8::Value> getNamedProperty( |
| 501 HTMLDocument* htmlDocument, | 499 HTMLDocument* htmlDocument, |
| 502 const AtomicString& key, | 500 const AtomicString& key, |
| (...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 577 v8String(m_isolate, name)); | 575 v8String(m_isolate, name)); |
| 578 } | 576 } |
| 579 | 577 |
| 580 void WindowProxy::updateSecurityOrigin(SecurityOrigin* origin) { | 578 void WindowProxy::updateSecurityOrigin(SecurityOrigin* origin) { |
| 581 if (!isContextInitialized()) | 579 if (!isContextInitialized()) |
| 582 return; | 580 return; |
| 583 setSecurityToken(origin); | 581 setSecurityToken(origin); |
| 584 } | 582 } |
| 585 | 583 |
| 586 } // namespace blink | 584 } // namespace blink |
| OLD | NEW |