summaryrefslogtreecommitdiffstats
path: root/WebCore/html/HTMLFrameElementBase.h
diff options
context:
space:
mode:
Diffstat (limited to 'WebCore/html/HTMLFrameElementBase.h')
-rw-r--r--WebCore/html/HTMLFrameElementBase.h22
1 files changed, 12 insertions, 10 deletions
diff --git a/WebCore/html/HTMLFrameElementBase.h b/WebCore/html/HTMLFrameElementBase.h
index 1b6e2a3..ae41e75 100644
--- a/WebCore/html/HTMLFrameElementBase.h
+++ b/WebCore/html/HTMLFrameElementBase.h
@@ -50,15 +50,10 @@ protected:
bool isURLAllowed() const;
virtual void parseMappedAttribute(Attribute*);
-
virtual void insertedIntoDocument();
- virtual void removedFromDocument();
-
virtual void attach();
private:
- virtual bool canLazyAttach() { return false; }
-
virtual bool supportsFocus() const;
virtual void setFocus(bool);
@@ -67,7 +62,7 @@ private:
virtual void setName();
virtual void willRemove();
- void checkAttachedTimerFired(Timer<HTMLFrameElementBase>*);
+ void checkInDocumentTimerFired(Timer<HTMLFrameElementBase>*);
void updateOnReparenting();
bool viewSourceMode() const { return m_viewSource; }
@@ -85,12 +80,19 @@ private:
int m_marginWidth;
int m_marginHeight;
- Timer<HTMLFrameElementBase> m_checkAttachedTimer;
+ // This is a performance optimization some call "magic iframe" which avoids
+ // tearing down the frame hierarchy when a web page calls adoptNode on a
+ // frame owning element but does not immediately insert it into the new
+ // document before JavaScript yields to WebCore. If the element is not yet
+ // in a document by the time this timer fires, the frame hierarchy teardown
+ // will continue. This can also be seen as implementation of:
+ // "Removing an iframe from a Document does not cause its browsing context
+ // to be discarded. Indeed, an iframe's browsing context can survive its
+ // original parent Document if its iframe is moved to another Document."
+ // From HTML5: http://www.whatwg.org/specs/web-apps/current-work/multipage/the-iframe-element.html#the-iframe-element
+ Timer<HTMLFrameElementBase> m_checkInDocumentTimer;
bool m_viewSource;
-
- bool m_shouldOpenURLAfterAttach;
-
bool m_remainsAliveOnRemovalFromTree;
};