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

Unified Diff: third_party/WebKit/Source/core/frame/FrameOwner.h

Issue 1802953003: RemoteBridgeFrameOwner: keep better track of the attached frame (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Doing work in constructors is evil. Created 4 years, 9 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/WebKit/Source/core/frame/Frame.cpp ('k') | third_party/WebKit/Source/core/frame/RemoteFrame.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/frame/FrameOwner.h
diff --git a/third_party/WebKit/Source/core/frame/FrameOwner.h b/third_party/WebKit/Source/core/frame/FrameOwner.h
index 59cab0fe330d97a6a24505f89ab969fcf6e76eb9..4aa63f5cb14915775af4d577183f72e6ed4207da 100644
--- a/third_party/WebKit/Source/core/frame/FrameOwner.h
+++ b/third_party/WebKit/Source/core/frame/FrameOwner.h
@@ -12,6 +12,8 @@
namespace blink {
+class Frame;
+
// Oilpan: all FrameOwner instances are GCed objects. FrameOwner additionally
// derives from GarbageCollectedMixin so that Member<FrameOwner> references can
// be kept (e.g., Frame::m_owner.)
@@ -22,6 +24,9 @@ public:
virtual bool isLocal() const = 0;
+ virtual void setContentFrame(Frame&) = 0;
+ virtual void clearContentFrame() = 0;
+
virtual SandboxFlags getSandboxFlags() const = 0;
virtual void dispatchLoad() = 0;
@@ -34,6 +39,28 @@ public:
virtual int marginHeight() const = 0;
};
+class CORE_EXPORT DummyFrameOwner : public NoBaseWillBeGarbageCollectedFinalized<DummyFrameOwner>, public FrameOwner {
+ WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(DummyFrameOwner);
+public:
+ static PassOwnPtrWillBeRawPtr<DummyFrameOwner> create()
+ {
+ return adoptPtrWillBeNoop(new DummyFrameOwner);
+ }
+
+ DEFINE_INLINE_VIRTUAL_TRACE() { FrameOwner::trace(visitor); }
+
+ // FrameOwner overrides:
+ bool isLocal() const override { return false; }
+ void setContentFrame(Frame&) override { }
+ void clearContentFrame() override { }
+ SandboxFlags getSandboxFlags() const override { return SandboxNone; }
+ void dispatchLoad() override { }
+ void renderFallbackContent() override { }
+ ScrollbarMode scrollingMode() const override { return ScrollbarAuto; }
+ int marginWidth() const override { return -1; }
+ int marginHeight() const override { return -1; }
+};
+
} // namespace blink
#endif // FrameOwner_h
« no previous file with comments | « third_party/WebKit/Source/core/frame/Frame.cpp ('k') | third_party/WebKit/Source/core/frame/RemoteFrame.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698