From 1bf1084f2b10c3b47fd1a588d85d21ed0eb41d0c Mon Sep 17 00:00:00 2001 From: Lorry Tar Creator Date: Tue, 27 Jun 2017 06:07:23 +0000 Subject: webkitgtk-2.16.5 --- Source/WebCore/html/HTMLFrameOwnerElement.h | 40 ++++++++++++++--------------- 1 file changed, 20 insertions(+), 20 deletions(-) (limited to 'Source/WebCore/html/HTMLFrameOwnerElement.h') diff --git a/Source/WebCore/html/HTMLFrameOwnerElement.h b/Source/WebCore/html/HTMLFrameOwnerElement.h index 4e4f973df..7b184b622 100644 --- a/Source/WebCore/html/HTMLFrameOwnerElement.h +++ b/Source/WebCore/html/HTMLFrameOwnerElement.h @@ -18,11 +18,11 @@ * */ -#ifndef HTMLFrameOwnerElement_h -#define HTMLFrameOwnerElement_h +#pragma once #include "HTMLElement.h" #include +#include namespace WebCore { @@ -36,8 +36,8 @@ public: virtual ~HTMLFrameOwnerElement(); Frame* contentFrame() const { return m_contentFrame; } - DOMWindow* contentWindow() const; - Document* contentDocument() const; + WEBCORE_EXPORT DOMWindow* contentWindow() const; + WEBCORE_EXPORT Document* contentDocument() const; void setContentFrame(Frame*); void clearContentFrame(); @@ -49,43 +49,41 @@ public: // RenderElement when using fallback content. RenderWidget* renderWidget() const; -#if ENABLE(SVG) - SVGDocument* getSVGDocument(ExceptionCode&) const; -#endif + ExceptionOr getSVGDocument() const; virtual ScrollbarMode scrollingMode() const { return ScrollbarAuto; } SandboxFlags sandboxFlags() const { return m_sandboxFlags; } - void scheduleSetNeedsStyleRecalc(StyleChangeType = FullStyleChange); + void scheduleinvalidateStyleAndLayerComposition(); + + virtual bool isURLAllowed(const URL&) const { return true; } protected: HTMLFrameOwnerElement(const QualifiedName& tagName, Document&); void setSandboxFlags(SandboxFlags); private: - virtual bool isKeyboardFocusable(KeyboardEvent*) const override; - virtual bool isFrameOwnerElement() const override { return true; } + bool isKeyboardFocusable(KeyboardEvent&) const override; + bool isFrameOwnerElement() const final { return true; } Frame* m_contentFrame; SandboxFlags m_sandboxFlags; }; -void isHTMLFrameOwnerElement(const HTMLFrameOwnerElement&); // Catch unnecessary runtime check of type known at compile time. -inline bool isHTMLFrameOwnerElement(const Node& node) { return node.isFrameOwnerElement(); } -NODE_TYPE_CASTS(HTMLFrameOwnerElement) - class SubframeLoadingDisabler { public: - explicit SubframeLoadingDisabler(ContainerNode& root) + explicit SubframeLoadingDisabler(ContainerNode* root) : m_root(root) { - disabledSubtreeRoots().add(&m_root); + if (m_root) + disabledSubtreeRoots().add(m_root); } ~SubframeLoadingDisabler() { - disabledSubtreeRoots().remove(&m_root); + if (m_root) + disabledSubtreeRoots().remove(m_root); } static bool canLoadFrame(HTMLFrameOwnerElement&); @@ -93,13 +91,15 @@ public: private: static HashCountedSet& disabledSubtreeRoots() { - DEFINE_STATIC_LOCAL(HashCountedSet, nodes, ()); + static NeverDestroyed> nodes; return nodes; } - ContainerNode& m_root; + ContainerNode* m_root; }; } // namespace WebCore -#endif // HTMLFrameOwnerElement_h +SPECIALIZE_TYPE_TRAITS_BEGIN(WebCore::HTMLFrameOwnerElement) + static bool isType(const WebCore::Node& node) { return node.isFrameOwnerElement(); } +SPECIALIZE_TYPE_TRAITS_END() -- cgit v1.2.1