OLD | NEW |
1 /** | 1 /** |
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
4 * (C) 2000 Stefan Schimanski (1Stein@gmx.de) | 4 * (C) 2000 Stefan Schimanski (1Stein@gmx.de) |
5 * Copyright (C) 2004, 2005, 2006 Apple Computer, Inc. | 5 * Copyright (C) 2004, 2005, 2006 Apple Computer, Inc. |
6 * | 6 * |
7 * This library is free software; you can redistribute it and/or | 7 * This library is free software; you can redistribute it and/or |
8 * modify it under the terms of the GNU Library General Public | 8 * modify it under the terms of the GNU Library General Public |
9 * License as published by the Free Software Foundation; either | 9 * License as published by the Free Software Foundation; either |
10 * version 2 of the License, or (at your option) any later version. | 10 * version 2 of the License, or (at your option) any later version. |
(...skipping 447 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
458 // when using fallback content. | 458 // when using fallback content. |
459 if (!layoutObject() || !layoutObject()->isEmbeddedObject()) | 459 if (!layoutObject() || !layoutObject()->isEmbeddedObject()) |
460 return LayoutEmbeddedItem(nullptr); | 460 return LayoutEmbeddedItem(nullptr); |
461 return LayoutEmbeddedItem(toLayoutEmbeddedObject(layoutObject())); | 461 return LayoutEmbeddedItem(toLayoutEmbeddedObject(layoutObject())); |
462 } | 462 } |
463 | 463 |
464 // We don't use m_url, as it may not be the final URL that the object loads, | 464 // We don't use m_url, as it may not be the final URL that the object loads, |
465 // depending on <param> values. | 465 // depending on <param> values. |
466 bool HTMLPlugInElement::allowedToLoadFrameURL(const String& url) { | 466 bool HTMLPlugInElement::allowedToLoadFrameURL(const String& url) { |
467 KURL completeURL = document().completeURL(url); | 467 KURL completeURL = document().completeURL(url); |
468 if (contentFrame() && protocolIsJavaScript(completeURL) && | 468 if (contentFrame() && completeURL.protocolIsJavaScript() && |
469 !document().getSecurityOrigin()->canAccess( | 469 !document().getSecurityOrigin()->canAccess( |
470 contentFrame()->securityContext()->getSecurityOrigin())) | 470 contentFrame()->securityContext()->getSecurityOrigin())) |
471 return false; | 471 return false; |
472 return document().frame()->isURLAllowed(completeURL); | 472 return document().frame()->isURLAllowed(completeURL); |
473 } | 473 } |
474 | 474 |
475 // We don't use m_url, or m_serviceType as they may not be the final values | 475 // We don't use m_url, or m_serviceType as they may not be the final values |
476 // that <object> uses depending on <param> values. | 476 // that <object> uses depending on <param> values. |
477 bool HTMLPlugInElement::wouldLoadAsNetscapePlugin(const String& url, | 477 bool HTMLPlugInElement::wouldLoadAsNetscapePlugin(const String& url, |
478 const String& serviceType) { | 478 const String& serviceType) { |
(...skipping 169 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
648 | 648 |
649 void HTMLPlugInElement::lazyReattachIfNeeded() { | 649 void HTMLPlugInElement::lazyReattachIfNeeded() { |
650 if (!useFallbackContent() && needsWidgetUpdate() && layoutObject() && | 650 if (!useFallbackContent() && needsWidgetUpdate() && layoutObject() && |
651 !isImageType()) { | 651 !isImageType()) { |
652 lazyReattachIfAttached(); | 652 lazyReattachIfAttached(); |
653 setPersistedPluginWidget(nullptr); | 653 setPersistedPluginWidget(nullptr); |
654 } | 654 } |
655 } | 655 } |
656 | 656 |
657 } // namespace blink | 657 } // namespace blink |
OLD | NEW |