OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserv
ed. | 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserv
ed. |
3 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) | 3 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) |
4 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) | 4 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) |
5 * Copyright (C) 2008 Alp Toker <alp@atoker.com> | 5 * Copyright (C) 2008 Alp Toker <alp@atoker.com> |
6 * Copyright (C) Research In Motion Limited 2009. All rights reserved. | 6 * Copyright (C) Research In Motion Limited 2009. All rights reserved. |
7 * Copyright (C) 2011 Kris Jordan <krisjordan@gmail.com> | 7 * Copyright (C) 2011 Kris Jordan <krisjordan@gmail.com> |
8 * Copyright (C) 2011 Google Inc. All rights reserved. | 8 * Copyright (C) 2011 Google Inc. All rights reserved. |
9 * | 9 * |
10 * Redistribution and use in source and binary forms, with or without | 10 * Redistribution and use in source and binary forms, with or without |
(...skipping 1381 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1392 if (!m_frame->script().canExecuteScripts(NotAboutToExecuteScript)) | 1392 if (!m_frame->script().canExecuteScripts(NotAboutToExecuteScript)) |
1393 return; | 1393 return; |
1394 | 1394 |
1395 if (Page* page = m_frame->page()) | 1395 if (Page* page = m_frame->page()) |
1396 page->inspectorController().didClearWindowObjectInMainWorld(m_frame); | 1396 page->inspectorController().didClearWindowObjectInMainWorld(m_frame); |
1397 InspectorInstrumentation::didClearWindowObjectInMainWorld(m_frame); | 1397 InspectorInstrumentation::didClearWindowObjectInMainWorld(m_frame); |
1398 | 1398 |
1399 Vector<RefPtr<DOMWrapperWorld> > worlds; | 1399 Vector<RefPtr<DOMWrapperWorld> > worlds; |
1400 DOMWrapperWorld::allWorldsInMainThread(worlds); | 1400 DOMWrapperWorld::allWorldsInMainThread(worlds); |
1401 for (size_t i = 0; i < worlds.size(); ++i) | 1401 for (size_t i = 0; i < worlds.size(); ++i) |
1402 m_client->dispatchDidClearWindowObjectInWorld(worlds[i].get()); | 1402 m_client->dispatchDidClearWindowObjectInWorld(*worlds[i]); |
1403 } | 1403 } |
1404 | 1404 |
1405 void FrameLoader::dispatchDidClearWindowObjectInWorld(DOMWrapperWorld* world) | 1405 void FrameLoader::dispatchDidClearWindowObjectInWorld(DOMWrapperWorld& world) |
1406 { | 1406 { |
1407 if (!m_frame->script().canExecuteScripts(NotAboutToExecuteScript) || !m_fram
e->script().existingWindowShell(world)) | 1407 if (!m_frame->script().canExecuteScripts(NotAboutToExecuteScript) || !m_fram
e->script().existingWindowShell(world)) |
1408 return; | 1408 return; |
1409 | 1409 |
1410 m_client->dispatchDidClearWindowObjectInWorld(world); | 1410 m_client->dispatchDidClearWindowObjectInWorld(world); |
1411 } | 1411 } |
1412 | 1412 |
1413 SandboxFlags FrameLoader::effectiveSandboxFlags() const | 1413 SandboxFlags FrameLoader::effectiveSandboxFlags() const |
1414 { | 1414 { |
1415 SandboxFlags flags = m_forcedSandboxFlags; | 1415 SandboxFlags flags = m_forcedSandboxFlags; |
1416 if (LocalFrame* parentFrame = m_frame->tree().parent()) | 1416 if (LocalFrame* parentFrame = m_frame->tree().parent()) |
1417 flags |= parentFrame->document()->sandboxFlags(); | 1417 flags |= parentFrame->document()->sandboxFlags(); |
1418 if (HTMLFrameOwnerElement* ownerElement = m_frame->ownerElement()) | 1418 if (HTMLFrameOwnerElement* ownerElement = m_frame->ownerElement()) |
1419 flags |= ownerElement->sandboxFlags(); | 1419 flags |= ownerElement->sandboxFlags(); |
1420 return flags; | 1420 return flags; |
1421 } | 1421 } |
1422 | 1422 |
1423 } // namespace WebCore | 1423 } // namespace WebCore |
OLD | NEW |