summaryrefslogtreecommitdiff
path: root/Libraries/LibWeb/Loader
diff options
context:
space:
mode:
authorAndreas Kling <kling@serenityos.org>2020-06-25 23:50:35 +0200
committerAndreas Kling <kling@serenityos.org>2020-06-26 00:53:25 +0200
commit6293d1a13c987bcaaa95e316899fa8097cd45e80 (patch)
tree6778bc4e25a2f7ac885cd705c2e3ce7d62d80a44 /Libraries/LibWeb/Loader
parent6c783dbf625149fc5e8a69c51283d082b6787a68 (diff)
downloadserenity-6293d1a13c987bcaaa95e316899fa8097cd45e80.zip
LibWeb+Browser: Remove old HTML parser :^)
The new parser is now used everywhere and it's working pretty well!
Diffstat (limited to 'Libraries/LibWeb/Loader')
-rw-r--r--Libraries/LibWeb/Loader/FrameLoader.cpp4
-rw-r--r--Libraries/LibWeb/Loader/FrameLoader.h4
2 files changed, 1 insertions, 7 deletions
diff --git a/Libraries/LibWeb/Loader/FrameLoader.cpp b/Libraries/LibWeb/Loader/FrameLoader.cpp
index 927d229f55..98b5141167 100644
--- a/Libraries/LibWeb/Loader/FrameLoader.cpp
+++ b/Libraries/LibWeb/Loader/FrameLoader.cpp
@@ -28,6 +28,7 @@
#include <LibGemini/Document.h>
#include <LibGfx/ImageDecoder.h>
#include <LibMarkdown/Document.h>
+#include <LibWeb/DOM/Document.h>
#include <LibWeb/DOM/ElementFactory.h>
#include <LibWeb/DOM/Text.h>
#include <LibWeb/Frame/Frame.h>
@@ -35,7 +36,6 @@
#include <LibWeb/Loader/ResourceLoader.h>
#include <LibWeb/Page.h>
#include <LibWeb/Parser/HTMLDocumentParser.h>
-#include <LibWeb/Parser/HTMLParser.h>
namespace Web {
@@ -130,8 +130,6 @@ RefPtr<Document> FrameLoader::create_document_from_mime_type(const ByteBuffer& d
if (mime_type == "text/gemini")
return create_gemini_document(data, url);
if (mime_type == "text/html") {
- if (m_use_old_parser)
- return parse_html_document(data, url, encoding);
HTMLDocumentParser parser(data, encoding);
parser.run(url);
return parser.document();
diff --git a/Libraries/LibWeb/Loader/FrameLoader.h b/Libraries/LibWeb/Loader/FrameLoader.h
index 261abb5942..2cad2654c0 100644
--- a/Libraries/LibWeb/Loader/FrameLoader.h
+++ b/Libraries/LibWeb/Loader/FrameLoader.h
@@ -43,8 +43,6 @@ public:
Frame& frame() { return m_frame; }
const Frame& frame() const { return m_frame; }
- void set_use_old_parser(bool b) { m_use_old_parser = b; }
-
private:
// ^ResourceClient
virtual void resource_did_load() override;
@@ -54,8 +52,6 @@ private:
RefPtr<Document> create_document_from_mime_type(const ByteBuffer&, const URL&, const String& mime_type, const String& encoding);
Frame& m_frame;
-
- bool m_use_old_parser { false };
};
}