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

Side by Side Diff: WebCore/loader/SubframeLoader.cpp

Issue 3551010: Merge 66992 - 2010-09-08 Andy Estes <aestes@apple.com>... (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/517/
Patch Set: Created 10 years, 2 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 | « WebCore/loader/SubframeLoader.h ('k') | 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) 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserved.
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 * 7 *
8 * Redistribution and use in source and binary forms, with or without 8 * Redistribution and use in source and binary forms, with or without
9 * modification, are permitted provided that the following conditions 9 * modification, are permitted provided that the following conditions
10 * are met: 10 * are met:
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 80
81 Frame* frame = loadOrRedirectSubframe(ownerElement, url, frameName, lockHist ory, lockBackForwardList); 81 Frame* frame = loadOrRedirectSubframe(ownerElement, url, frameName, lockHist ory, lockBackForwardList);
82 if (!frame) 82 if (!frame)
83 return false; 83 return false;
84 84
85 if (!scriptURL.isEmpty()) 85 if (!scriptURL.isEmpty())
86 frame->script()->executeIfJavaScriptURL(scriptURL); 86 frame->script()->executeIfJavaScriptURL(scriptURL);
87 87
88 return true; 88 return true;
89 } 89 }
90
91 bool SubframeLoader::resourceWillUsePlugin(const String& url, const String& mime Type)
92 {
93 KURL completedURL;
94 if (!url.isEmpty())
95 completedURL = completeURL(url);
96 bool useFallback;
97 return shouldUsePlugin(completedURL, mimeType, false, useFallback);
98 }
90 99
91 bool SubframeLoader::requestObject(HTMLPlugInImageElement* ownerElement, const S tring& url, const AtomicString& frameName, 100 bool SubframeLoader::requestObject(HTMLPlugInImageElement* ownerElement, const S tring& url, const AtomicString& frameName,
92 const String& mimeType, const Vector<String>& paramNames, const Vector<Strin g>& paramValues) 101 const String& mimeType, const Vector<String>& paramNames, const Vector<Strin g>& paramValues)
93 { 102 {
94 if (url.isEmpty() && mimeType.isEmpty()) 103 if (url.isEmpty() && mimeType.isEmpty())
95 return false; 104 return false;
96 105
97 if (!m_frame->script()->xssAuditor()->canLoadObject(url)) { 106 if (!m_frame->script()->xssAuditor()->canLoadObject(url)) {
98 // It is unsafe to honor the request for this object. 107 // It is unsafe to honor the request for this object.
99 return false; 108 return false;
(...skipping 263 matching lines...) Expand 10 before | Expand all | Expand 10 after
363 return true; 372 return true;
364 } 373 }
365 374
366 KURL SubframeLoader::completeURL(const String& url) const 375 KURL SubframeLoader::completeURL(const String& url) const
367 { 376 {
368 ASSERT(m_frame->document()); 377 ASSERT(m_frame->document());
369 return m_frame->document()->completeURL(url); 378 return m_frame->document()->completeURL(url);
370 } 379 }
371 380
372 } // namespace WebCore 381 } // namespace WebCore
OLDNEW
« no previous file with comments | « WebCore/loader/SubframeLoader.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698