| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2006, 2007, 2009 Apple Inc. All rights reserved. | 2 * Copyright (C) 2006, 2007, 2009 Apple Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * This library is free software; you can redistribute it and/or | 4 * This library is free software; you can redistribute it and/or |
| 5 * modify it under the terms of the GNU Library General Public | 5 * modify it under the terms of the GNU Library General Public |
| 6 * License as published by the Free Software Foundation; either | 6 * License as published by the Free Software Foundation; either |
| 7 * version 2 of the License, or (at your option) any later version. | 7 * version 2 of the License, or (at your option) any later version. |
| 8 * | 8 * |
| 9 * This library is distributed in the hope that it will be useful, | 9 * This library is distributed in the hope that it will be useful, |
| 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 12 * Library General Public License for more details. | 12 * Library General Public License for more details. |
| 13 * | 13 * |
| 14 * You should have received a copy of the GNU Library General Public License | 14 * You should have received a copy of the GNU Library General Public License |
| 15 * along with this library; see the file COPYING.LIB. If not, write to | 15 * along with this library; see the file COPYING.LIB. If not, write to |
| 16 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | 16 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, |
| 17 * Boston, MA 02110-1301, USA. | 17 * Boston, MA 02110-1301, USA. |
| 18 * | 18 * |
| 19 */ | 19 */ |
| 20 | 20 |
| 21 #ifndef HTMLFrameOwnerElement_h | 21 #ifndef HTMLFrameOwnerElement_h |
| 22 #define HTMLFrameOwnerElement_h | 22 #define HTMLFrameOwnerElement_h |
| 23 | 23 |
| 24 #include "core/CoreExport.h" | 24 #include "core/CoreExport.h" |
| 25 #include "core/dom/Document.h" | 25 #include "core/dom/Document.h" |
| 26 #include "core/frame/FrameOwner.h" | 26 #include "core/frame/FrameOwner.h" |
| 27 #include "core/html/HTMLElement.h" | 27 #include "core/html/HTMLElement.h" |
| 28 #include "platform/heap/Handle.h" | 28 #include "platform/heap/Handle.h" |
| 29 #include "platform/scroll/ScrollTypes.h" | 29 #include "platform/scroll/ScrollTypes.h" |
| 30 #include "platform/weborigin/SecurityPolicy.h" |
| 30 #include "wtf/HashCountedSet.h" | 31 #include "wtf/HashCountedSet.h" |
| 31 | 32 |
| 32 namespace blink { | 33 namespace blink { |
| 33 | 34 |
| 34 class LocalDOMWindow; | 35 class LocalDOMWindow; |
| 35 class ExceptionState; | 36 class ExceptionState; |
| 36 class Frame; | 37 class Frame; |
| 37 class LayoutPart; | 38 class LayoutPart; |
| 38 class Widget; | 39 class Widget; |
| 39 | 40 |
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 87 protected: | 88 protected: |
| 88 HTMLFrameOwnerElement(const QualifiedName& tagName, Document&); | 89 HTMLFrameOwnerElement(const QualifiedName& tagName, Document&); |
| 89 void setSandboxFlags(SandboxFlags); | 90 void setSandboxFlags(SandboxFlags); |
| 90 | 91 |
| 91 bool loadOrRedirectSubframe(const KURL&, const AtomicString& frameName, bool
replaceCurrentItem); | 92 bool loadOrRedirectSubframe(const KURL&, const AtomicString& frameName, bool
replaceCurrentItem); |
| 92 | 93 |
| 93 private: | 94 private: |
| 94 bool isKeyboardFocusable() const override; | 95 bool isKeyboardFocusable() const override; |
| 95 bool isFrameOwnerElement() const final { return true; } | 96 bool isFrameOwnerElement() const final { return true; } |
| 96 | 97 |
| 98 virtual ReferrerPolicy referrerPolicyAttribute() { return ReferrerPolicyDefa
ult; } |
| 99 |
| 97 RawPtrWillBeMember<Frame> m_contentFrame; | 100 RawPtrWillBeMember<Frame> m_contentFrame; |
| 98 RefPtrWillBeMember<Widget> m_widget; | 101 RefPtrWillBeMember<Widget> m_widget; |
| 99 SandboxFlags m_sandboxFlags; | 102 SandboxFlags m_sandboxFlags; |
| 100 }; | 103 }; |
| 101 | 104 |
| 102 DEFINE_ELEMENT_TYPE_CASTS(HTMLFrameOwnerElement, isFrameOwnerElement()); | 105 DEFINE_ELEMENT_TYPE_CASTS(HTMLFrameOwnerElement, isFrameOwnerElement()); |
| 103 | 106 |
| 104 class SubframeLoadingDisabler { | 107 class SubframeLoadingDisabler { |
| 105 STACK_ALLOCATED(); | 108 STACK_ALLOCATED(); |
| 106 public: | 109 public: |
| (...skipping 23 matching lines...) Expand all Loading... |
| 130 static WillBeHeapHashCountedSet<RawPtrWillBeMember<Node>>& disabledSubtreeRo
ots(); | 133 static WillBeHeapHashCountedSet<RawPtrWillBeMember<Node>>& disabledSubtreeRo
ots(); |
| 131 | 134 |
| 132 RawPtrWillBeMember<Node> m_root; | 135 RawPtrWillBeMember<Node> m_root; |
| 133 }; | 136 }; |
| 134 | 137 |
| 135 DEFINE_TYPE_CASTS(HTMLFrameOwnerElement, FrameOwner, owner, owner->isLocal(), ow
ner.isLocal()); | 138 DEFINE_TYPE_CASTS(HTMLFrameOwnerElement, FrameOwner, owner, owner->isLocal(), ow
ner.isLocal()); |
| 136 | 139 |
| 137 } // namespace blink | 140 } // namespace blink |
| 138 | 141 |
| 139 #endif // HTMLFrameOwnerElement_h | 142 #endif // HTMLFrameOwnerElement_h |
| OLD | NEW |