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

Unified Diff: third_party/WebKit/Source/core/dom/Document.h

Issue 2002063003: Change "bool createdByParser" of createElement() to enum (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@cestate
Patch Set: Build fix Created 4 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/dom/Document.h
diff --git a/third_party/WebKit/Source/core/dom/Document.h b/third_party/WebKit/Source/core/dom/Document.h
index 2816210aa4d48655d719edabd21b46e1998617dd..bdb60e7dd9e24fab1094c4b67e2a2a2e6d75a53c 100644
--- a/third_party/WebKit/Source/core/dom/Document.h
+++ b/third_party/WebKit/Source/core/dom/Document.h
@@ -214,6 +214,14 @@ enum ShadowCascadeOrder {
ShadowCascadeV1
};
+enum CreateElementFlags {
yosin_UTC9 2016/05/24 08:53:53 Is this bit flag? If not, please use |enum class|
kojii 2016/05/24 09:49:14 Yes, this is a bit flag.
yosin_UTC9 2016/05/25 01:32:52 How about using |CreateRequester| or another good
kojii 2016/05/25 04:11:45 Done, added aliases. The sync flag is added to th
+ CreatedByParser = 1 << 0,
+ // Synchronous custom elements flag
+ // https://dom.spec.whatwg.org/#concept-create-element
+ SynchronousCustomElements = 0,
+ AsynchronousCustomElements = 1 << 1,
+};
+
using DocumentClassFlags = unsigned char;
class CORE_EXPORT Document : public ContainerNode, public TreeScope, public SecurityContext, public ExecutionContext, public Supplementable<Document> {
@@ -292,7 +300,7 @@ public:
Attr* createAttributeNS(const AtomicString& namespaceURI, const AtomicString& qualifiedName, ExceptionState&, bool shouldIgnoreNamespaceChecks = false);
Node* importNode(Node* importedNode, bool deep, ExceptionState&);
Element* createElementNS(const AtomicString& namespaceURI, const AtomicString& qualifiedName, ExceptionState&);
- Element* createElement(const QualifiedName&, bool createdByParser);
+ Element* createElement(const QualifiedName&, CreateElementFlags);
Element* elementFromPoint(int x, int y) const;
HeapVector<Member<Element>> elementsFromPoint(int x, int y) const;

Powered by Google App Engine
This is Rietveld 408576698