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

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

Issue 14839007: Devirtualize Document class type checking (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Try again Created 7 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « Source/core/html/PluginDocument.h ('k') | Source/core/svg/SVGDocument.h » ('j') | 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 118 matching lines...) Expand 10 before | Expand all | Expand 10 after
129 frame->loader()->client()->redirectDataToPlugin(widget); 129 frame->loader()->client()->redirectDataToPlugin(widget);
130 // In a plugin document, the main resource is the plugin. If we have a null widget, that means 130 // In a plugin document, the main resource is the plugin. If we have a null widget, that means
131 // the loading of the plugin was cancelled, which gives us a null ma inResourceLoader(), so we 131 // the loading of the plugin was cancelled, which gives us a null ma inResourceLoader(), so we
132 // need to have this call in a null check of the widget or of mainRe sourceLoader(). 132 // need to have this call in a null check of the widget or of mainRe sourceLoader().
133 frame->loader()->activeDocumentLoader()->setMainResourceDataBufferin gPolicy(DoNotBufferData); 133 frame->loader()->activeDocumentLoader()->setMainResourceDataBufferin gPolicy(DoNotBufferData);
134 } 134 }
135 } 135 }
136 } 136 }
137 137
138 PluginDocument::PluginDocument(Frame* frame, const KURL& url) 138 PluginDocument::PluginDocument(Frame* frame, const KURL& url)
139 : HTMLDocument(frame, url) 139 : HTMLDocument(frame, url, PluginDocumentClass)
140 , m_shouldLoadPluginManually(true) 140 , m_shouldLoadPluginManually(true)
141 { 141 {
142 setCompatibilityMode(QuirksMode); 142 setCompatibilityMode(QuirksMode);
143 lockCompatibilityMode(); 143 lockCompatibilityMode();
144 } 144 }
145 145
146 PassRefPtr<DocumentParser> PluginDocument::createParser() 146 PassRefPtr<DocumentParser> PluginDocument::createParser()
147 { 147 {
148 return PluginDocumentParser::create(this); 148 return PluginDocumentParser::create(this);
149 } 149 }
(...skipping 27 matching lines...) Expand all
177 // with how many times we call beforeload on object elements. <rdar://proble m/8441094>. 177 // with how many times we call beforeload on object elements. <rdar://proble m/8441094>.
178 if (!shouldLoadPluginManually()) 178 if (!shouldLoadPluginManually())
179 return; 179 return;
180 180
181 DocumentLoader* documentLoader = frame()->loader()->activeDocumentLoader(); 181 DocumentLoader* documentLoader = frame()->loader()->activeDocumentLoader();
182 documentLoader->cancelMainResourceLoad(frame()->loader()->cancelledError(doc umentLoader->request())); 182 documentLoader->cancelMainResourceLoad(frame()->loader()->cancelledError(doc umentLoader->request()));
183 setShouldLoadPluginManually(false); 183 setShouldLoadPluginManually(false);
184 } 184 }
185 185
186 } 186 }
OLDNEW
« no previous file with comments | « Source/core/html/PluginDocument.h ('k') | Source/core/svg/SVGDocument.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698