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

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

Issue 2089063005: Schedule sibling invalidation sets for sibling insert/remove. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Removed minDirectAdjacent optimization. Created 4 years, 5 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 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
74 74
75 Element& host() const { DCHECK(parentOrShadowHostNode()); return *toElement( parentOrShadowHostNode()); } 75 Element& host() const { DCHECK(parentOrShadowHostNode()); return *toElement( parentOrShadowHostNode()); }
76 ElementShadow* owner() const { return host().shadow(); } 76 ElementShadow* owner() const { return host().shadow(); }
77 ShadowRootType type() const { return static_cast<ShadowRootType>(m_type); } 77 ShadowRootType type() const { return static_cast<ShadowRootType>(m_type); }
78 String mode() const { return (type() == ShadowRootType::V0 || type() == Shad owRootType::Open) ? "open" : "closed"; }; 78 String mode() const { return (type() == ShadowRootType::V0 || type() == Shad owRootType::Open) ? "open" : "closed"; };
79 79
80 bool isOpenOrV0() const { return type() == ShadowRootType::V0 || type() == S hadowRootType::Open; } 80 bool isOpenOrV0() const { return type() == ShadowRootType::V0 || type() == S hadowRootType::Open; }
81 bool isV1() const { return type() == ShadowRootType::Open || type() == Shado wRootType::Closed; } 81 bool isV1() const { return type() == ShadowRootType::Open || type() == Shado wRootType::Closed; }
82 82
83 void attach(const AttachContext& = AttachContext()) override; 83 void attach(const AttachContext& = AttachContext()) override;
84 void detach(const AttachContext& = AttachContext()) override;
84 85
85 InsertionNotificationRequest insertedInto(ContainerNode*) override; 86 InsertionNotificationRequest insertedInto(ContainerNode*) override;
86 void removedFrom(ContainerNode*) override; 87 void removedFrom(ContainerNode*) override;
87 88
88 // For V0 89 // For V0
89 ShadowRoot* youngerShadowRoot() const; 90 ShadowRoot* youngerShadowRoot() const;
90 ShadowRoot* olderShadowRoot() const; 91 ShadowRoot* olderShadowRoot() const;
91 ShadowRoot* olderShadowRootForBindings() const; 92 ShadowRoot* olderShadowRootForBindings() const;
92 void setYoungerShadowRoot(ShadowRoot&); 93 void setYoungerShadowRoot(ShadowRoot&);
93 void setOlderShadowRoot(ShadowRoot&); 94 void setOlderShadowRoot(ShadowRoot&);
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
176 177
177 DEFINE_NODE_TYPE_CASTS(ShadowRoot, isShadowRoot()); 178 DEFINE_NODE_TYPE_CASTS(ShadowRoot, isShadowRoot());
178 DEFINE_TYPE_CASTS(ShadowRoot, TreeScope, treeScope, treeScope->rootNode().isShad owRoot(), treeScope.rootNode().isShadowRoot()); 179 DEFINE_TYPE_CASTS(ShadowRoot, TreeScope, treeScope, treeScope->rootNode().isShad owRoot(), treeScope.rootNode().isShadowRoot());
179 DEFINE_TYPE_CASTS(TreeScope, ShadowRoot, shadowRoot, true, true); 180 DEFINE_TYPE_CASTS(TreeScope, ShadowRoot, shadowRoot, true, true);
180 181
181 CORE_EXPORT std::ostream& operator<<(std::ostream&, const ShadowRootType&); 182 CORE_EXPORT std::ostream& operator<<(std::ostream&, const ShadowRootType&);
182 183
183 } // namespace blink 184 } // namespace blink
184 185
185 #endif // ShadowRoot_h 186 #endif // ShadowRoot_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/dom/StyleEngine.cpp ('k') | third_party/WebKit/Source/core/dom/shadow/ShadowRoot.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698