diff options
author | Matt A. Tobin <email@mattatobin.com> | 2020-06-13 08:23:21 -0400 |
---|---|---|
committer | Matt A. Tobin <email@mattatobin.com> | 2020-06-13 08:23:21 -0400 |
commit | 5e7917e2c8bd50754535652014c1de0054841912 (patch) | |
tree | ead6813f00c5ff538adad2b2aa8406732ffeb2b4 /dom/base/DocumentOrShadowRoot.h | |
parent | 43725c7264ca3f63de348d1d1596ce1fe9e64d2d (diff) | |
download | UXP-5e7917e2c8bd50754535652014c1de0054841912.tar UXP-5e7917e2c8bd50754535652014c1de0054841912.tar.gz UXP-5e7917e2c8bd50754535652014c1de0054841912.tar.lz UXP-5e7917e2c8bd50754535652014c1de0054841912.tar.xz UXP-5e7917e2c8bd50754535652014c1de0054841912.zip |
Bug 1429656 - Implement ShadowRoot.activeElement
Tag #1375
Diffstat (limited to 'dom/base/DocumentOrShadowRoot.h')
-rw-r--r-- | dom/base/DocumentOrShadowRoot.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/dom/base/DocumentOrShadowRoot.h b/dom/base/DocumentOrShadowRoot.h index 59be0c2a9..2092cd54f 100644 --- a/dom/base/DocumentOrShadowRoot.h +++ b/dom/base/DocumentOrShadowRoot.h @@ -116,6 +116,15 @@ public: ~DocumentOrShadowRoot() = default; protected: + nsIContent* Retarget(nsIContent* aContent) const; + + /** + * If focused element's subtree root is this document or shadow root, return + * focused element, otherwise, get the shadow host recursively until the + * shadow host's subtree root is this document or shadow root. + */ + Element* GetRetargetedFocusedElement(); + nsTArray<RefPtr<mozilla::StyleSheet>> mStyleSheets; RefPtr<mozilla::dom::StyleSheetList> mDOMStyleSheets; |