From 3a74795a56e92313c1b33a54500917794ba09b72 Mon Sep 17 00:00:00 2001 From: "Matt A. Tobin" Date: Fri, 17 Apr 2020 07:05:27 -0400 Subject: Bug 1411878 - Support Element.shadowRoot and Element.assignedSlot / TextNode.assignedSlot on closed shadow root Tag #1375 --- dom/base/nsIContent.h | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'dom/base/nsIContent.h') diff --git a/dom/base/nsIContent.h b/dom/base/nsIContent.h index f368497f4..8da0ba7f2 100644 --- a/dom/base/nsIContent.h +++ b/dom/base/nsIContent.h @@ -724,6 +724,15 @@ public: */ virtual void SetAssignedSlot(mozilla::dom::HTMLSlotElement* aSlot) = 0; + /** + * Gets the assigned slot associated with this content based on parent's + * shadow root mode. Returns null if parent's shadow root is "closed". + * https://dom.spec.whatwg.org/#dom-slotable-assignedslot + * + * @return The assigned slot element or null. + */ + mozilla::dom::HTMLSlotElement* GetAssignedSlotByMode() const; + /** * Gets the insertion parent element of the XBL binding. * The insertion parent is our one true parent in the transformed DOM. -- cgit v1.2.3