Chromium Code Reviews| 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, 2008, 2009, 2011 Apple Inc. All rights reserv ed. | 5 * Copyright (C) 2004, 2005, 2006, 2008, 2009, 2011 Apple Inc. All rights reserv ed. |
| 6 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) | 6 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) |
| 7 * | 7 * |
| 8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
| 9 * modify it under the terms of the GNU Library General Public | 9 * modify it under the terms of the GNU Library General Public |
| 10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
| (...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 140 | 140 |
| 141 // FIXME: These should be joined into a PluginParameters class. | 141 // FIXME: These should be joined into a PluginParameters class. |
| 142 Vector<String> paramNames; | 142 Vector<String> paramNames; |
| 143 Vector<String> paramValues; | 143 Vector<String> paramValues; |
| 144 parametersForPlugin(paramNames, paramValues); | 144 parametersForPlugin(paramNames, paramValues); |
| 145 | 145 |
| 146 // FIXME: Can we not have layoutObject here now that beforeload events are g one? | 146 // FIXME: Can we not have layoutObject here now that beforeload events are g one? |
| 147 if (!layoutObject()) | 147 if (!layoutObject()) |
| 148 return; | 148 return; |
| 149 | 149 |
| 150 // Overwrites the URL and MIME type of a Flash embed to use an | 150 // Overwrites the URL and MIME type of a Flash embed to use an HTML5 embed |
|
pdr.
2016/08/11 23:21:53
I see on the bug that this will be very difficult
mlamouri (slow - plz ping)
2016/08/12 10:27:32
I've changed the ASSERT() to a CHECK().
FWIW, a r
| |
| 151 // HTML5 embed when possible. | 151 // when outside of a PluginDocument. |
| 152 KURL overridenUrl = document().frame()->loader().client()->overrideFlashEmbe dWithHTML(document().completeURL(m_url)); | 152 if (!document().isPluginDocument()) { |
|
pdr.
2016/08/11 23:21:53
Instead of a blacklist, can this be a whitelist? I
mlamouri (slow - plz ping)
2016/08/12 10:27:32
The issue is really that the PluginDocument is mak
| |
| 153 if (!overridenUrl.isEmpty()) { | 153 KURL overridenUrl = document().frame()->loader().client()->overrideFlash EmbedWithHTML(document().completeURL(m_url)); |
| 154 m_url = overridenUrl.getString(); | 154 if (!overridenUrl.isEmpty()) { |
| 155 m_serviceType = "text/html"; | 155 m_url = overridenUrl.getString(); |
| 156 m_serviceType = "text/html"; | |
| 157 } | |
| 156 } | 158 } |
| 157 | 159 |
| 158 requestObject(m_url, m_serviceType, paramNames, paramValues); | 160 requestObject(m_url, m_serviceType, paramNames, paramValues); |
| 159 } | 161 } |
| 160 | 162 |
| 161 bool HTMLEmbedElement::layoutObjectIsNeeded(const ComputedStyle& style) | 163 bool HTMLEmbedElement::layoutObjectIsNeeded(const ComputedStyle& style) |
| 162 { | 164 { |
| 163 if (isImageType()) | 165 if (isImageType()) |
| 164 return HTMLPlugInElement::layoutObjectIsNeeded(style); | 166 return HTMLPlugInElement::layoutObjectIsNeeded(style); |
| 165 | 167 |
| (...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 207 { | 209 { |
| 208 // http://www.whatwg.org/specs/web-apps/current-work/#exposed | 210 // http://www.whatwg.org/specs/web-apps/current-work/#exposed |
| 209 for (HTMLObjectElement* object = Traversal<HTMLObjectElement>::firstAncestor (*this); object; object = Traversal<HTMLObjectElement>::firstAncestor(*object)) { | 211 for (HTMLObjectElement* object = Traversal<HTMLObjectElement>::firstAncestor (*this); object; object = Traversal<HTMLObjectElement>::firstAncestor(*object)) { |
| 210 if (object->isExposed()) | 212 if (object->isExposed()) |
| 211 return false; | 213 return false; |
| 212 } | 214 } |
| 213 return true; | 215 return true; |
| 214 } | 216 } |
| 215 | 217 |
| 216 } // namespace blink | 218 } // namespace blink |
| OLD | NEW |