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

Side by Side Diff: third_party/WebKit/Source/core/dom/shadow/ShadowRoot.h

Issue 2697923005: Remove unnecessary override of Node#cloneNode in ShadowRoot's WebIDL (Closed)
Patch Set: updated {mac,win} global-interface-listing-expected.txt Created 3 years, 10 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Google Inc. All rights reserved. 2 * Copyright (C) 2011 Google 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 are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Neither the name of Google Inc. nor the names of its 10 * * Neither the name of Google Inc. nor the names of its
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after
133 void didChangeHostChildSlotName(const AtomicString& oldValue, 133 void didChangeHostChildSlotName(const AtomicString& oldValue,
134 const AtomicString& newValue); 134 const AtomicString& newValue);
135 135
136 void distributeV1(); 136 void distributeV1();
137 137
138 Element* activeElement() const; 138 Element* activeElement() const;
139 139
140 String innerHTML() const; 140 String innerHTML() const;
141 void setInnerHTML(const String&, ExceptionState& = ASSERT_NO_EXCEPTION); 141 void setInnerHTML(const String&, ExceptionState& = ASSERT_NO_EXCEPTION);
142 142
143 Node* cloneNode(bool, ExceptionState&); 143 Node* cloneNode(bool, ExceptionState&) override;
144 144
145 void setDelegatesFocus(bool flag) { m_delegatesFocus = flag; } 145 void setDelegatesFocus(bool flag) { m_delegatesFocus = flag; }
146 bool delegatesFocus() const { return m_delegatesFocus; } 146 bool delegatesFocus() const { return m_delegatesFocus; }
147 147
148 bool containsShadowRoots() const { return m_childShadowRootCount; } 148 bool containsShadowRoots() const { return m_childShadowRootCount; }
149 149
150 StyleSheetList& styleSheets(); 150 StyleSheetList& styleSheets();
151 void setStyleSheets(StyleSheetList* styleSheetList) { 151 void setStyleSheets(StyleSheetList* styleSheetList) {
152 m_styleSheetList = styleSheetList; 152 m_styleSheetList = styleSheetList;
153 ScriptWrappableVisitor::writeBarrier(this, m_styleSheetList); 153 ScriptWrappableVisitor::writeBarrier(this, m_styleSheetList);
(...skipping 11 matching lines...) Expand all
165 ShadowRootRareDataV0& ensureShadowRootRareDataV0(); 165 ShadowRootRareDataV0& ensureShadowRootRareDataV0();
166 SlotAssignment& ensureSlotAssignment(); 166 SlotAssignment& ensureSlotAssignment();
167 167
168 void addChildShadowRoot() { ++m_childShadowRootCount; } 168 void addChildShadowRoot() { ++m_childShadowRootCount; }
169 void removeChildShadowRoot() { 169 void removeChildShadowRoot() {
170 DCHECK_GT(m_childShadowRootCount, 0u); 170 DCHECK_GT(m_childShadowRootCount, 0u);
171 --m_childShadowRootCount; 171 --m_childShadowRootCount;
172 } 172 }
173 void invalidateDescendantInsertionPoints(); 173 void invalidateDescendantInsertionPoints();
174 174
175 // ShadowRoots should never be cloned.
176 Node* cloneNode(bool) override { return nullptr; }
177
178 Member<ShadowRootRareDataV0> m_shadowRootRareDataV0; 175 Member<ShadowRootRareDataV0> m_shadowRootRareDataV0;
179 Member<StyleSheetList> m_styleSheetList; 176 Member<StyleSheetList> m_styleSheetList;
180 Member<SlotAssignment> m_slotAssignment; 177 Member<SlotAssignment> m_slotAssignment;
181 unsigned m_childShadowRootCount : 13; 178 unsigned m_childShadowRootCount : 13;
182 unsigned m_type : 2; 179 unsigned m_type : 2;
183 unsigned m_registeredWithParentShadowRoot : 1; 180 unsigned m_registeredWithParentShadowRoot : 1;
184 unsigned m_descendantInsertionPointsIsValid : 1; 181 unsigned m_descendantInsertionPointsIsValid : 1;
185 unsigned m_delegatesFocus : 1; 182 unsigned m_delegatesFocus : 1;
186 }; 183 };
187 184
(...skipping 14 matching lines...) Expand all
202 treeScope, 199 treeScope,
203 treeScope->rootNode().isShadowRoot(), 200 treeScope->rootNode().isShadowRoot(),
204 treeScope.rootNode().isShadowRoot()); 201 treeScope.rootNode().isShadowRoot());
205 DEFINE_TYPE_CASTS(TreeScope, ShadowRoot, shadowRoot, true, true); 202 DEFINE_TYPE_CASTS(TreeScope, ShadowRoot, shadowRoot, true, true);
206 203
207 CORE_EXPORT std::ostream& operator<<(std::ostream&, const ShadowRootType&); 204 CORE_EXPORT std::ostream& operator<<(std::ostream&, const ShadowRootType&);
208 205
209 } // namespace blink 206 } // namespace blink
210 207
211 #endif // ShadowRoot_h 208 #endif // ShadowRoot_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/dom/Text.cpp ('k') | third_party/WebKit/Source/core/dom/shadow/ShadowRoot.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698