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

Side by Side Diff: Source/core/html/HTMLFrameOwnerElement.h

Issue 23618022: BrowserPlugin/WebView - Move plugin lifetime to DOM (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Fix mac compile issue. Created 7 years 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 | Annotate | Revision Log
OLDNEW
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
(...skipping 13 matching lines...) Expand all
24 #include "core/html/HTMLElement.h" 24 #include "core/html/HTMLElement.h"
25 #include "wtf/HashCountedSet.h" 25 #include "wtf/HashCountedSet.h"
26 26
27 namespace WebCore { 27 namespace WebCore {
28 28
29 class DOMWindow; 29 class DOMWindow;
30 class ExceptionState; 30 class ExceptionState;
31 class Frame; 31 class Frame;
32 class RenderPart; 32 class RenderPart;
33 class SVGDocument; 33 class SVGDocument;
34 class Widget;
34 35
35 class HTMLFrameOwnerElement : public HTMLElement { 36 class HTMLFrameOwnerElement : public HTMLElement {
36 public: 37 public:
37 virtual ~HTMLFrameOwnerElement(); 38 virtual ~HTMLFrameOwnerElement();
38 39
39 Frame* contentFrame() const { return m_contentFrame; } 40 Frame* contentFrame() const { return m_contentFrame; }
40 DOMWindow* contentWindow() const; 41 DOMWindow* contentWindow() const;
41 Document* contentDocument() const; 42 Document* contentDocument() const;
42 43
43 void setContentFrame(Frame&); 44 void setContentFrame(Frame&);
(...skipping 11 matching lines...) Expand all
55 virtual ScrollbarMode scrollingMode() const { return ScrollbarAuto; } 56 virtual ScrollbarMode scrollingMode() const { return ScrollbarAuto; }
56 57
57 SandboxFlags sandboxFlags() const { return m_sandboxFlags; } 58 SandboxFlags sandboxFlags() const { return m_sandboxFlags; }
58 59
59 virtual bool loadedNonEmptyDocument() const { return false; } 60 virtual bool loadedNonEmptyDocument() const { return false; }
60 virtual void didLoadNonEmptyDocument() { } 61 virtual void didLoadNonEmptyDocument() { }
61 62
62 virtual void renderFallbackContent() { } 63 virtual void renderFallbackContent() { }
63 64
64 virtual bool isObjectElement() const { return false; } 65 virtual bool isObjectElement() const { return false; }
66 void setWidget(PassRefPtr<Widget>);
67 Widget* widget() const;
68
69 class UpdateSuspendScope {
70 public:
71 UpdateSuspendScope();
72 ~UpdateSuspendScope();
73 };
65 74
66 protected: 75 protected:
67 HTMLFrameOwnerElement(const QualifiedName& tagName, Document&); 76 HTMLFrameOwnerElement(const QualifiedName& tagName, Document&);
68 void setSandboxFlags(SandboxFlags); 77 void setSandboxFlags(SandboxFlags);
69 78
70 bool loadOrRedirectSubframe(const KURL&, const AtomicString& frameName, bool lockBackForwardList); 79 bool loadOrRedirectSubframe(const KURL&, const AtomicString& frameName, bool lockBackForwardList);
71 80
72 private: 81 private:
73 virtual bool isKeyboardFocusable() const OVERRIDE; 82 virtual bool isKeyboardFocusable() const OVERRIDE;
74 virtual bool isFrameOwnerElement() const OVERRIDE { return true; } 83 virtual bool isFrameOwnerElement() const OVERRIDE { return true; }
75 84
76 Frame* m_contentFrame; 85 Frame* m_contentFrame;
86 RefPtr<Widget> m_widget;
77 SandboxFlags m_sandboxFlags; 87 SandboxFlags m_sandboxFlags;
78 }; 88 };
79 89
80 DEFINE_NODE_TYPE_CASTS(HTMLFrameOwnerElement, isFrameOwnerElement()); 90 DEFINE_NODE_TYPE_CASTS(HTMLFrameOwnerElement, isFrameOwnerElement());
81 91
82 class SubframeLoadingDisabler { 92 class SubframeLoadingDisabler {
83 public: 93 public:
84 explicit SubframeLoadingDisabler(Node& root) 94 explicit SubframeLoadingDisabler(Node& root)
85 : m_root(root) 95 : m_root(root)
86 { 96 {
(...skipping 20 matching lines...) Expand all
107 DEFINE_STATIC_LOCAL(HashCountedSet<Node*>, nodes, ()); 117 DEFINE_STATIC_LOCAL(HashCountedSet<Node*>, nodes, ());
108 return nodes; 118 return nodes;
109 } 119 }
110 120
111 Node& m_root; 121 Node& m_root;
112 }; 122 };
113 123
114 } // namespace WebCore 124 } // namespace WebCore
115 125
116 #endif // HTMLFrameOwnerElement_h 126 #endif // HTMLFrameOwnerElement_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698