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

Side by Side Diff: third_party/WebKit/Source/core/html/PluginDocument.cpp

Issue 2238983002: Do not try to use an HTML embed instead of a Flash one inside a PluginDocument. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: review comments Created 4 years, 4 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 | « third_party/WebKit/Source/core/html/HTMLEmbedElement.cpp ('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, 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2008 Apple 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 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after
171 } 171 }
172 172
173 DocumentParser* PluginDocument::createParser() 173 DocumentParser* PluginDocument::createParser()
174 { 174 {
175 return PluginDocumentParser::create(this); 175 return PluginDocumentParser::create(this);
176 } 176 }
177 177
178 Widget* PluginDocument::pluginWidget() 178 Widget* PluginDocument::pluginWidget()
179 { 179 {
180 if (m_pluginNode && m_pluginNode->layoutObject()) { 180 if (m_pluginNode && m_pluginNode->layoutObject()) {
181 ASSERT(m_pluginNode->layoutObject()->isEmbeddedObject()); 181 CHECK(m_pluginNode->layoutObject()->isEmbeddedObject());
182 return toLayoutEmbeddedObject(m_pluginNode->layoutObject())->widget(); 182 return toLayoutEmbeddedObject(m_pluginNode->layoutObject())->widget();
183 } 183 }
184 return 0; 184 return 0;
185 } 185 }
186 186
187 Node* PluginDocument::pluginNode() 187 Node* PluginDocument::pluginNode()
188 { 188 {
189 return m_pluginNode.get(); 189 return m_pluginNode.get();
190 } 190 }
191 191
192 void PluginDocument::detachLayoutTree(const AttachContext& context) 192 void PluginDocument::detachLayoutTree(const AttachContext& context)
193 { 193 {
194 // Release the plugin node so that we don't have a circular reference. 194 // Release the plugin node so that we don't have a circular reference.
195 m_pluginNode = nullptr; 195 m_pluginNode = nullptr;
196 HTMLDocument::detachLayoutTree(context); 196 HTMLDocument::detachLayoutTree(context);
197 } 197 }
198 198
199 DEFINE_TRACE(PluginDocument) 199 DEFINE_TRACE(PluginDocument)
200 { 200 {
201 visitor->trace(m_pluginNode); 201 visitor->trace(m_pluginNode);
202 HTMLDocument::trace(visitor); 202 HTMLDocument::trace(visitor);
203 } 203 }
204 204
205 } // namespace blink 205 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/html/HTMLEmbedElement.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698