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 768 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
779 if (!wasInSamePage && page) | 779 if (!wasInSamePage && page) |
780 page->chrome().focus(); | 780 page->chrome().focus(); |
781 return; | 781 return; |
782 } | 782 } |
783 | 783 |
784 setReferrerForFrameRequest(request.resourceRequest(), request.shouldSendRefe rrer(), request.originDocument()); | 784 setReferrerForFrameRequest(request.resourceRequest(), request.shouldSendRefe rrer(), request.originDocument()); |
785 | 785 |
786 FrameLoadType newLoadType = determineFrameLoadType(request); | 786 FrameLoadType newLoadType = determineFrameLoadType(request); |
787 NavigationPolicy policy = navigationPolicyForRequest(request); | 787 NavigationPolicy policy = navigationPolicyForRequest(request); |
788 if (shouldOpenInNewWindow(targetFrame.get(), request, policy)) { | 788 if (shouldOpenInNewWindow(targetFrame.get(), request, policy)) { |
789 if (policy == NavigationPolicyDownload) | 789 if (policy == NavigationPolicyDownload) { |
790 client()->loadURLExternally(request.resourceRequest(), NavigationPol icyDownload); | 790 client()->loadURLExternally(request.resourceRequest(), NavigationPol icyDownload); |
791 else | 791 } else { |
792 request.resourceRequest().setFrameType(WebURLRequest::FrameTypeAuxil iary); | |
jochen (gone - plz use gerrit)
2015/04/13 13:07:02
should this be in a different CL?
Mike West
2015/04/21 12:46:22
As long as you don't mind reviewing two CreateWind
| |
792 createWindowForRequest(request, *m_frame, policy, request.shouldSend Referrer()); | 793 createWindowForRequest(request, *m_frame, policy, request.shouldSend Referrer()); |
794 } | |
793 return; | 795 return; |
794 } | 796 } |
795 | 797 |
796 const KURL& url = request.resourceRequest().url(); | 798 const KURL& url = request.resourceRequest().url(); |
797 if (policy == NavigationPolicyCurrentTab && shouldPerformFragmentNavigation( request.formState(), request.resourceRequest().httpMethod(), newLoadType, url)) { | 799 if (policy == NavigationPolicyCurrentTab && shouldPerformFragmentNavigation( request.formState(), request.resourceRequest().httpMethod(), newLoadType, url)) { |
798 m_documentLoader->setNavigationType(determineNavigationType(newLoadType, false, request.triggeringEvent())); | 800 m_documentLoader->setNavigationType(determineNavigationType(newLoadType, false, request.triggeringEvent())); |
799 if (shouldTreatURLAsSameAsCurrent(url)) | 801 if (shouldTreatURLAsSameAsCurrent(url)) |
800 newLoadType = FrameLoadTypeRedirectWithLockedBackForwardList; | 802 newLoadType = FrameLoadTypeRedirectWithLockedBackForwardList; |
801 loadInSameDocument(url, nullptr, newLoadType, request.clientRedirect()); | 803 loadInSameDocument(url, nullptr, newLoadType, request.clientRedirect()); |
802 return; | 804 return; |
(...skipping 640 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1443 // FIXME: We need a way to propagate insecure requests policy flags to | 1445 // FIXME: We need a way to propagate insecure requests policy flags to |
1444 // out-of-process frames. For now, we'll always use default behavior. | 1446 // out-of-process frames. For now, we'll always use default behavior. |
1445 if (!parentFrame->isLocalFrame()) | 1447 if (!parentFrame->isLocalFrame()) |
1446 return nullptr; | 1448 return nullptr; |
1447 | 1449 |
1448 ASSERT(toLocalFrame(parentFrame)->document()); | 1450 ASSERT(toLocalFrame(parentFrame)->document()); |
1449 return toLocalFrame(parentFrame)->document()->insecureNavigationsToUpgrade() ; | 1451 return toLocalFrame(parentFrame)->document()->insecureNavigationsToUpgrade() ; |
1450 } | 1452 } |
1451 | 1453 |
1452 } // namespace blink | 1454 } // namespace blink |
OLD | NEW |