OLD | NEW |
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 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
65 | 65 |
66 PluginView* pluginView() const; | 66 PluginView* pluginView() const; |
67 | 67 |
68 HTMLEmbedElement* m_embedElement; | 68 HTMLEmbedElement* m_embedElement; |
69 }; | 69 }; |
70 | 70 |
71 void PluginDocumentParser::createDocumentStructure() | 71 void PluginDocumentParser::createDocumentStructure() |
72 { | 72 { |
73 RefPtr<Element> rootElement = document()->createElement(htmlTag, false); | 73 RefPtr<Element> rootElement = document()->createElement(htmlTag, false); |
74 document()->appendChild(rootElement, IGNORE_EXCEPTION); | 74 document()->appendChild(rootElement, IGNORE_EXCEPTION); |
75 static_cast<HTMLHtmlElement*>(rootElement.get())->insertedByParser(); | 75 toHTMLHtmlElement(rootElement.get())->insertedByParser(); |
76 | 76 |
77 if (document()->frame() && document()->frame()->loader()) | 77 if (document()->frame() && document()->frame()->loader()) |
78 document()->frame()->loader()->dispatchDocumentElementAvailable(); | 78 document()->frame()->loader()->dispatchDocumentElementAvailable(); |
79 | 79 |
80 RefPtr<Element> body = document()->createElement(bodyTag, false); | 80 RefPtr<Element> body = document()->createElement(bodyTag, false); |
81 body->setAttribute(marginwidthAttr, "0"); | 81 body->setAttribute(marginwidthAttr, "0"); |
82 body->setAttribute(marginheightAttr, "0"); | 82 body->setAttribute(marginheightAttr, "0"); |
83 body->setAttribute(styleAttr, "background-color: rgb(38,38,38)"); | 83 body->setAttribute(styleAttr, "background-color: rgb(38,38,38)"); |
84 | 84 |
85 rootElement->appendChild(body, IGNORE_EXCEPTION); | 85 rootElement->appendChild(body, IGNORE_EXCEPTION); |
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
196 // with how many times we call beforeload on object elements. <rdar://proble
m/8441094>. | 196 // with how many times we call beforeload on object elements. <rdar://proble
m/8441094>. |
197 if (!shouldLoadPluginManually()) | 197 if (!shouldLoadPluginManually()) |
198 return; | 198 return; |
199 | 199 |
200 DocumentLoader* documentLoader = frame()->loader()->activeDocumentLoader(); | 200 DocumentLoader* documentLoader = frame()->loader()->activeDocumentLoader(); |
201 documentLoader->cancelMainResourceLoad(frame()->loader()->cancelledError(doc
umentLoader->request())); | 201 documentLoader->cancelMainResourceLoad(frame()->loader()->cancelledError(doc
umentLoader->request())); |
202 setShouldLoadPluginManually(false); | 202 setShouldLoadPluginManually(false); |
203 } | 203 } |
204 | 204 |
205 } | 205 } |
OLD | NEW |