diff options
author | Steve Block <steveblock@google.com> | 2009-11-05 09:23:40 +0000 |
---|---|---|
committer | Steve Block <steveblock@google.com> | 2009-11-10 22:41:12 +0000 |
commit | cac0f67c402d107cdb10971b95719e2ff9c7c76b (patch) | |
tree | d182c7f87211c6f201a5f038e332336493ebdbe7 /WebCore/dom/Document.h | |
parent | 4b2ef0f288e7c6c4602f621b7a0e9feed304b70e (diff) | |
download | external_webkit-cac0f67c402d107cdb10971b95719e2ff9c7c76b.zip external_webkit-cac0f67c402d107cdb10971b95719e2ff9c7c76b.tar.gz external_webkit-cac0f67c402d107cdb10971b95719e2ff9c7c76b.tar.bz2 |
Merge webkit.org at r50258 : Initial merge by git.
Change-Id: I1a9e1dc4ed654b69174ad52a4f031a07240f37b0
Diffstat (limited to 'WebCore/dom/Document.h')
-rw-r--r-- | WebCore/dom/Document.h | 21 |
1 files changed, 16 insertions, 5 deletions
diff --git a/WebCore/dom/Document.h b/WebCore/dom/Document.h index fc2eea0..9f5785e 100644 --- a/WebCore/dom/Document.h +++ b/WebCore/dom/Document.h @@ -71,6 +71,7 @@ namespace WebCore { class HitTestRequest; class HTMLCanvasElement; class HTMLCollection; + class HTMLAllCollection; class HTMLDocument; class HTMLElement; class HTMLFormElement; @@ -79,6 +80,7 @@ namespace WebCore { class HTMLMapElement; class InspectorTimelineAgent; class IntPoint; + class DOMWrapperWorld; class JSNode; class MouseEventWithHitTestResults; class NodeFilter; @@ -315,12 +317,13 @@ public: PassRefPtr<HTMLCollection> links(); PassRefPtr<HTMLCollection> forms(); PassRefPtr<HTMLCollection> anchors(); - PassRefPtr<HTMLCollection> all(); PassRefPtr<HTMLCollection> objects(); PassRefPtr<HTMLCollection> scripts(); PassRefPtr<HTMLCollection> windowNamedItems(const String& name); PassRefPtr<HTMLCollection> documentNamedItems(const String& name); + PassRefPtr<HTMLAllCollection> all(); + // Find first anchor with the given name. // First searches for an element with the given ID, but if that fails, then looks // for an anchor with the given name. ID matching is always case sensitive, but @@ -473,7 +476,6 @@ public: void write(const String& text, Document* ownerDocument = 0); void writeln(const String& text, Document* ownerDocument = 0); void finishParsing(); - void clear(); bool wellFormed() const { return m_wellFormed; } @@ -615,7 +617,8 @@ public: ANIMATIONEND_LISTENER = 0x100, ANIMATIONSTART_LISTENER = 0x200, ANIMATIONITERATION_LISTENER = 0x400, - TRANSITIONEND_LISTENER = 0x800 + TRANSITIONEND_LISTENER = 0x800, + BEFORELOAD_LISTENER = 0x1000 }; bool hasListenerType(ListenerType listenerType) const { return (m_listenerTypes & listenerType); } @@ -832,7 +835,15 @@ public: virtual void postTask(PassRefPtr<Task>); // Executes the task on context's thread asynchronously. typedef HashMap<WebCore::Node*, JSNode*> JSWrapperCache; - JSWrapperCache& wrapperCache() { return m_wrapperCache; } + typedef HashMap<DOMWrapperWorld*, JSWrapperCache*> JSWrapperCacheMap; + JSWrapperCacheMap& wrapperCacheMap() { return m_wrapperCacheMap; } + JSWrapperCache* getWrapperCache(DOMWrapperWorld* world) + { + if (JSWrapperCache* wrapperCache = m_wrapperCacheMap.get(world)) + return wrapperCache; + return createWrapperCache(world); + } + JSWrapperCache* createWrapperCache(DOMWrapperWorld*); virtual void finishedParsing(); @@ -1162,7 +1173,7 @@ private: unsigned m_numNodeListCaches; - JSWrapperCache m_wrapperCache; + JSWrapperCacheMap m_wrapperCacheMap; #if ENABLE(DATABASE) RefPtr<DatabaseThread> m_databaseThread; |