| Index: Source/core/html/HTMLPlugInElement.h
|
| diff --git a/Source/core/html/HTMLPlugInElement.h b/Source/core/html/HTMLPlugInElement.h
|
| index b03a5462abaf9c19f940833026c05d4d37b21eec..4d3ec12ee1cb544ca49c146c0846769309fbcab9 100644
|
| --- a/Source/core/html/HTMLPlugInElement.h
|
| +++ b/Source/core/html/HTMLPlugInElement.h
|
| @@ -45,6 +45,9 @@ class HTMLPlugInElement : public HTMLFrameOwnerElement {
|
| public:
|
| virtual ~HTMLPlugInElement();
|
| virtual void trace(Visitor*) OVERRIDE;
|
| +#if ENABLE(OILPAN)
|
| + virtual void disconnectContentFrame() OVERRIDE;
|
| +#endif
|
|
|
| void resetInstance();
|
| SharedPersistent<v8::Object>* pluginWrapper();
|
| @@ -143,7 +146,20 @@ private:
|
| // prevent confusing code which may assume that widget() != null
|
| // means the frame is active, we save off m_widget here while
|
| // the plugin is persisting but not being displayed.
|
| - RefPtr<Widget> m_persistedPluginWidget;
|
| + // ---
|
| + // Oilpan: a Persistent<> is used for finalization purposes.
|
| + // A renderer-less plugin element is not detached prior to
|
| + // finalization, so the required disposing of plugin container
|
| + // widgets that happen then won't. Instead, a Persistent is
|
| + // used to extend the lifetime of this persisted widget
|
| + // beyond the plugin element's, so that it can be disposed
|
| + // of by the plugin element's finalizer.
|
| + //
|
| + // To prevent a leak from that, the plugin container does not
|
| + // keep a strong reference back to the plugin element.
|
| + // Not pretty.
|
| + GC_PLUGIN_IGNORE("")
|
| + RefPtrWillBePersistent<Widget> m_persistedPluginWidget;
|
| };
|
|
|
| inline bool isHTMLPlugInElement(const HTMLElement& element)
|
|
|