Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(91)

Side by Side Diff: Source/web/WebLocalFrameImpl.cpp

Issue 927653005: Do not check for browser side navigation when loading a data url (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 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 893 matching lines...) Expand 10 before | Expand all | Expand 10 after
904 // If we are loading substitute data to replace an existing load, then 904 // If we are loading substitute data to replace an existing load, then
905 // inherit all of the properties of that original request. This way, 905 // inherit all of the properties of that original request. This way,
906 // reload will re-attempt the original request. It is essential that 906 // reload will re-attempt the original request. It is essential that
907 // we only do this when there is an unreachableURL since a non-empty 907 // we only do this when there is an unreachableURL since a non-empty
908 // unreachableURL informs FrameLoader::reload to load unreachableURL 908 // unreachableURL informs FrameLoader::reload to load unreachableURL
909 // instead of the currently loaded URL. 909 // instead of the currently loaded URL.
910 ResourceRequest request; 910 ResourceRequest request;
911 if (replace && !unreachableURL.isEmpty() && frame()->loader().provisionalDoc umentLoader()) 911 if (replace && !unreachableURL.isEmpty() && frame()->loader().provisionalDoc umentLoader())
912 request = frame()->loader().provisionalDocumentLoader()->originalRequest (); 912 request = frame()->loader().provisionalDocumentLoader()->originalRequest ();
913 request.setURL(baseURL); 913 request.setURL(baseURL);
914 request.setCheckForBrowserSideNavigation(false);
914 915
915 FrameLoadRequest frameRequest(0, request, SubstituteData(data, mimeType, tex tEncoding, unreachableURL)); 916 FrameLoadRequest frameRequest(0, request, SubstituteData(data, mimeType, tex tEncoding, unreachableURL));
916 ASSERT(frameRequest.substituteData().isValid()); 917 ASSERT(frameRequest.substituteData().isValid());
917 frameRequest.setLockBackForwardList(replace); 918 frameRequest.setLockBackForwardList(replace);
918 frame()->loader().load(frameRequest); 919 frame()->loader().load(frameRequest);
919 } 920 }
920 921
921 void WebLocalFrameImpl::loadHTMLString(const WebData& data, const WebURL& baseUR L, const WebURL& unreachableURL, bool replace) 922 void WebLocalFrameImpl::loadHTMLString(const WebData& data, const WebURL& baseUR L, const WebURL& unreachableURL, bool replace)
922 { 923 {
923 ASSERT(frame()); 924 ASSERT(frame());
(...skipping 1079 matching lines...) Expand 10 before | Expand all | Expand 10 after
2003 { 2004 {
2004 m_frameWidget = frameWidget; 2005 m_frameWidget = frameWidget;
2005 } 2006 }
2006 2007
2007 WebFrameWidgetImpl* WebLocalFrameImpl::frameWidget() const 2008 WebFrameWidgetImpl* WebLocalFrameImpl::frameWidget() const
2008 { 2009 {
2009 return m_frameWidget; 2010 return m_frameWidget;
2010 } 2011 }
2011 2012
2012 } // namespace blink 2013 } // namespace blink
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698