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

Unified Diff: third_party/WebKit/Source/core/editing/serializers/MarkupFormatter.cpp

Issue 2804943002: Avoid duplicate functions/code in core/editing: endTag (Closed)
Patch Set: Created 3 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/editing/serializers/MarkupFormatter.cpp
diff --git a/third_party/WebKit/Source/core/editing/serializers/MarkupFormatter.cpp b/third_party/WebKit/Source/core/editing/serializers/MarkupFormatter.cpp
index b75932dce31894a9494252abb1ee4b76826a0c0a..ea8f5cb145e63463cc90b1a74f60d9bba176e713 100644
--- a/third_party/WebKit/Source/core/editing/serializers/MarkupFormatter.cpp
+++ b/third_party/WebKit/Source/core/editing/serializers/MarkupFormatter.cpp
@@ -37,6 +37,7 @@
#include "core/dom/DocumentFragment.h"
#include "core/dom/DocumentType.h"
#include "core/dom/ProcessingInstruction.h"
+#include "core/editing/EditingUtilities.h"
#include "core/editing/Editor.h"
#include "core/html/HTMLElement.h"
#include "core/html/HTMLTemplateElement.h"
@@ -178,13 +179,6 @@ void MarkupFormatter::appendStartMarkup(StringBuilder& result,
}
}
-static bool elementCannotHaveEndTag(const Node& node) {
- if (!node.isHTMLElement())
- return false;
-
- return !toHTMLElement(node).shouldSerializeEndTag();
-}
-
void MarkupFormatter::appendEndMarkup(StringBuilder& result,
const Element& element) {
if (shouldSelfClose(element) ||

Powered by Google App Engine
This is Rietveld 408576698