Index: Source/web/WebFrameWidgetImpl.h |
diff --git a/Source/web/WebFrameWidgetImpl.h b/Source/web/WebFrameWidgetImpl.h |
index e7a0a592752384c98623ce1cc31b50a1aa032aa2..28d9525666a893acc74808f96b782659a219bfa3 100644 |
--- a/Source/web/WebFrameWidgetImpl.h |
+++ b/Source/web/WebFrameWidgetImpl.h |
@@ -58,9 +58,9 @@ class WebLayerTreeView; |
class WebMouseEvent; |
class WebMouseWheelEvent; |
-class WebFrameWidgetImpl final : public WebFrameWidget |
- , public PageWidgetEventHandler |
- , public RefCounted<WebFrameWidgetImpl> { |
+class WebFrameWidgetImpl final : public RefCountedWillBeGarbageCollectedFinalized<WebFrameWidgetImpl> |
+ , public WebFrameWidget |
+ , public PageWidgetEventHandler { |
public: |
static WebFrameWidgetImpl* create(WebWidgetClient*, WebLocalFrame*); |
static HashSet<WebFrameWidgetImpl*>& allInstances(); |
@@ -148,9 +148,15 @@ public: |
ScrollDirection*, |
ScrollGranularity*); |
+ DECLARE_TRACE(); |
+ |
private: |
friend class WebFrameWidget; // For WebFrameWidget::create. |
+#if ENABLE(OILPAN) |
+ friend class GarbageCollectedFinalized<WebFrameWidgetImpl>; |
+#else |
friend class WTF::RefCounted<WebFrameWidgetImpl>; |
+#endif |
explicit WebFrameWidgetImpl(WebWidgetClient*, WebLocalFrame*); |
~WebFrameWidgetImpl(); |
@@ -185,12 +191,12 @@ private: |
// WebFrameWidget is associated with a subtree of the frame tree, corresponding to a maximal |
// connected tree of LocalFrames. This member points to the root of that subtree. |
- WebLocalFrameImpl* m_localRoot; |
+ RawPtrWillBeMember<WebLocalFrameImpl> m_localRoot; |
WebSize m_size; |
// If set, the (plugin) node which has mouse capture. |
- RefPtrWillBePersistent<Node> m_mouseCaptureNode; |
+ RefPtrWillBeMember<Node> m_mouseCaptureNode; |
RefPtr<UserGestureToken> m_mouseCaptureGestureToken; |
WebLayerTreeView* m_layerTreeView; |
@@ -204,6 +210,10 @@ private: |
bool m_ignoreInputEvents; |
static const WebInputEvent* m_currentInputEvent; |
+ |
+#if ENABLE(OILPAN) |
+ SelfKeepAlive<WebFrameWidgetImpl> m_selfKeepAlive; |
+#endif |
}; |
DEFINE_TYPE_CASTS(WebFrameWidgetImpl, WebFrameWidget, widget, widget->forSubframe(), widget.forSubframe()); |