Chromium Code Reviews| 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 1023 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1034 const ResourceError& error = m_documentLoader->mainDocumentError(); | 1034 const ResourceError& error = m_documentLoader->mainDocumentError(); |
| 1035 if (!error.isNull()) | 1035 if (!error.isNull()) |
| 1036 m_client->dispatchDidFailLoad(error); | 1036 m_client->dispatchDidFailLoad(error); |
| 1037 else | 1037 else |
| 1038 m_client->dispatchDidFinishLoad(); | 1038 m_client->dispatchDidFinishLoad(); |
| 1039 m_loadType = FrameLoadTypeStandard; | 1039 m_loadType = FrameLoadTypeStandard; |
| 1040 } | 1040 } |
| 1041 | 1041 |
| 1042 void FrameLoader::didFirstLayout() | 1042 void FrameLoader::didFirstLayout() |
| 1043 { | 1043 { |
| 1044 if (m_frame->page() && isBackForwardLoadType(m_loadType)) | 1044 if (m_frame->page() |
| 1045 && (isBackForwardLoadType(m_loadType) || m_loadType == FrameLoadTypeRelo ad || m_loadType == FrameLoadTypeReloadFromOrigin)) | |
|
Nate Chapin
2013/10/30 19:00:44
It might be good to split this into 2 separate if(
| |
| 1045 history()->restoreScrollPositionAndViewState(); | 1046 history()->restoreScrollPositionAndViewState(); |
| 1046 } | 1047 } |
| 1047 | 1048 |
| 1048 void FrameLoader::detachChildren() | 1049 void FrameLoader::detachChildren() |
| 1049 { | 1050 { |
| 1050 typedef Vector<RefPtr<Frame> > FrameVector; | 1051 typedef Vector<RefPtr<Frame> > FrameVector; |
| 1051 FrameVector childrenToDetach; | 1052 FrameVector childrenToDetach; |
| 1052 childrenToDetach.reserveCapacity(m_frame->tree().childCount()); | 1053 childrenToDetach.reserveCapacity(m_frame->tree().childCount()); |
| 1053 for (Frame* child = m_frame->tree().lastChild(); child; child = child->tree( ).previousSibling()) | 1054 for (Frame* child = m_frame->tree().lastChild(); child; child = child->tree( ).previousSibling()) |
| 1054 childrenToDetach.append(child); | 1055 childrenToDetach.append(child); |
| (...skipping 546 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1601 { | 1602 { |
| 1602 SandboxFlags flags = m_forcedSandboxFlags; | 1603 SandboxFlags flags = m_forcedSandboxFlags; |
| 1603 if (Frame* parentFrame = m_frame->tree().parent()) | 1604 if (Frame* parentFrame = m_frame->tree().parent()) |
| 1604 flags |= parentFrame->document()->sandboxFlags(); | 1605 flags |= parentFrame->document()->sandboxFlags(); |
| 1605 if (HTMLFrameOwnerElement* ownerElement = m_frame->ownerElement()) | 1606 if (HTMLFrameOwnerElement* ownerElement = m_frame->ownerElement()) |
| 1606 flags |= ownerElement->sandboxFlags(); | 1607 flags |= ownerElement->sandboxFlags(); |
| 1607 return flags; | 1608 return flags; |
| 1608 } | 1609 } |
| 1609 | 1610 |
| 1610 } // namespace WebCore | 1611 } // namespace WebCore |
| OLD | NEW |