Commit 0bc2431e authored by kdecker's avatar kdecker

        Reviewed by andersca.

        Fixed: <rdar://problem/4701326>21.2 ms launch time regression spent in +[WebPluginDatabase installedPlugins]

        * dom/DOMImplementation.cpp:
        (WebCore::DOMImplementation::createDocument): Added a guard clause for text/html which used to be in WebKit before a lot of the 
        loader plumbing was moved to WebCore.  Pinging the plug-in database to ask it if it supports a given mime type has the side 
        effect of reading from disk on first call, therefore such a check should be a last resort.  


git-svn-id: svn://svn.chromium.org/blink/trunk@18813 bbb929c8-8fbe-4397-9dbb-9b2b20218538
parent c652a6b4
2007-01-12 Kevin Decker <kdecker@apple.com>
Reviewed by andersca.
Fixed: <rdar://problem/4701326>21.2 ms launch time regression spent in +[WebPluginDatabase installedPlugins]
* dom/DOMImplementation.cpp:
(WebCore::DOMImplementation::createDocument): Added a guard clause for text/html which used to be in WebKit before a lot of the
loader plumbing was moved to WebCore. Pinging the plug-in database to ask it if it supports a given mime type has the side
effect of reading from disk on first call, therefore such a check should be a last resort.
2007-01-12 Mitz Pettel <mitz@webkit.org> 2007-01-12 Mitz Pettel <mitz@webkit.org>
Reviewed by Darin. Reviewed by Darin.
......
...@@ -342,6 +342,10 @@ PassRefPtr<HTMLDocument> DOMImplementation::createHTMLDocument(const String& tit ...@@ -342,6 +342,10 @@ PassRefPtr<HTMLDocument> DOMImplementation::createHTMLDocument(const String& tit
PassRefPtr<Document> DOMImplementation::createDocument(const String& type, FrameView* view, bool inViewSourceMode) PassRefPtr<Document> DOMImplementation::createDocument(const String& type, FrameView* view, bool inViewSourceMode)
{ {
if (inViewSourceMode)
return new HTMLViewSourceDocument(this, view);
if (type == "text/html")
return new HTMLDocument(this, view);
#ifdef SVG_SUPPORT #ifdef SVG_SUPPORT
if (type == "image/svg+xml") if (type == "image/svg+xml")
return new SVGDocument(this, view); return new SVGDocument(this, view);
...@@ -356,8 +360,6 @@ PassRefPtr<Document> DOMImplementation::createDocument(const String& type, Frame ...@@ -356,8 +360,6 @@ PassRefPtr<Document> DOMImplementation::createDocument(const String& type, Frame
return new ImageDocument(this, view); return new ImageDocument(this, view);
if (PlugInInfoStore::supportsMIMEType(type)) if (PlugInInfoStore::supportsMIMEType(type))
return new PluginDocument(this, view); return new PluginDocument(this, view);
if (inViewSourceMode)
return new HTMLViewSourceDocument(this, view);
return new HTMLDocument(this, view); return new HTMLDocument(this, view);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment