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

Side by Side Diff: Source/core/dom/Document.cpp

Issue 334283004: Rename DOMWindow to LocalDOMWindow (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase Created 6 years, 6 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/core/dom/Document.h ('k') | Source/core/dom/ExecutionContext.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * (C) 2001 Dirk Mueller (mueller@kde.org) 4 * (C) 2001 Dirk Mueller (mueller@kde.org)
5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org) 5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org)
6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2011, 2012 Apple Inc. All r ights reserved. 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2011, 2012 Apple Inc. All r ights reserved.
7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/) 7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/)
8 * Copyright (C) 2008, 2009, 2011, 2012 Google Inc. All rights reserved. 8 * Copyright (C) 2008, 2009, 2011, 2012 Google Inc. All rights reserved.
9 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) 9 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies)
10 * Copyright (C) Research In Motion Limited 2010-2011. All rights reserved. 10 * Copyright (C) Research In Motion Limited 2010-2011. All rights reserved.
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 #include "core/editing/FrameSelection.h" 101 #include "core/editing/FrameSelection.h"
102 #include "core/editing/SpellChecker.h" 102 #include "core/editing/SpellChecker.h"
103 #include "core/events/BeforeUnloadEvent.h" 103 #include "core/events/BeforeUnloadEvent.h"
104 #include "core/events/Event.h" 104 #include "core/events/Event.h"
105 #include "core/events/EventFactory.h" 105 #include "core/events/EventFactory.h"
106 #include "core/events/EventListener.h" 106 #include "core/events/EventListener.h"
107 #include "core/events/HashChangeEvent.h" 107 #include "core/events/HashChangeEvent.h"
108 #include "core/events/PageTransitionEvent.h" 108 #include "core/events/PageTransitionEvent.h"
109 #include "core/events/ScopedEventQueue.h" 109 #include "core/events/ScopedEventQueue.h"
110 #include "core/fetch/ResourceFetcher.h" 110 #include "core/fetch/ResourceFetcher.h"
111 #include "core/frame/DOMWindow.h" 111 #include "core/frame/LocalDOMWindow.h"
112 #include "core/frame/FrameConsole.h" 112 #include "core/frame/FrameConsole.h"
113 #include "core/frame/FrameHost.h" 113 #include "core/frame/FrameHost.h"
114 #include "core/frame/FrameView.h" 114 #include "core/frame/FrameView.h"
115 #include "core/frame/History.h" 115 #include "core/frame/History.h"
116 #include "core/frame/LocalFrame.h" 116 #include "core/frame/LocalFrame.h"
117 #include "core/frame/Settings.h" 117 #include "core/frame/Settings.h"
118 #include "core/frame/csp/ContentSecurityPolicy.h" 118 #include "core/frame/csp/ContentSecurityPolicy.h"
119 #include "core/html/DocumentNameCollection.h" 119 #include "core/html/DocumentNameCollection.h"
120 #include "core/html/HTMLAllCollection.h" 120 #include "core/html/HTMLAllCollection.h"
121 #include "core/html/HTMLAnchorElement.h" 121 #include "core/html/HTMLAnchorElement.h"
(...skipping 728 matching lines...) Expand 10 before | Expand all | Expand 10 after
850 return m_importsController->loaderFor(*this); 850 return m_importsController->loaderFor(*this);
851 } 851 }
852 852
853 bool Document::haveImportsLoaded() const 853 bool Document::haveImportsLoaded() const
854 { 854 {
855 if (!m_importsController) 855 if (!m_importsController)
856 return true; 856 return true;
857 return !m_importsController->shouldBlockScriptExecution(*this); 857 return !m_importsController->shouldBlockScriptExecution(*this);
858 } 858 }
859 859
860 DOMWindow* Document::executingWindow() 860 LocalDOMWindow* Document::executingWindow()
861 { 861 {
862 if (DOMWindow* owningWindow = domWindow()) 862 if (LocalDOMWindow* owningWindow = domWindow())
863 return owningWindow; 863 return owningWindow;
864 if (HTMLImportsController* import = this->importsController()) 864 if (HTMLImportsController* import = this->importsController())
865 return import->master()->domWindow(); 865 return import->master()->domWindow();
866 return 0; 866 return 0;
867 } 867 }
868 868
869 LocalFrame* Document::executingFrame() 869 LocalFrame* Document::executingFrame()
870 { 870 {
871 DOMWindow* window = executingWindow(); 871 LocalDOMWindow* window = executingWindow();
872 if (!window) 872 if (!window)
873 return 0; 873 return 0;
874 return window->frame(); 874 return window->frame();
875 } 875 }
876 876
877 PassRefPtrWillBeRawPtr<DocumentFragment> Document::createDocumentFragment() 877 PassRefPtrWillBeRawPtr<DocumentFragment> Document::createDocumentFragment()
878 { 878 {
879 return DocumentFragment::create(*this); 879 return DocumentFragment::create(*this);
880 } 880 }
881 881
(...skipping 958 matching lines...) Expand 10 before | Expand all | Expand 10 after
1840 // FIXME: This executes media query listeners which runs script, instead the script 1840 // FIXME: This executes media query listeners which runs script, instead the script
1841 // should run at raf timing in ScriptedAnimationController just like resize events. 1841 // should run at raf timing in ScriptedAnimationController just like resize events.
1842 evaluateMediaQueryListIfNeeded(); 1842 evaluateMediaQueryListIfNeeded();
1843 1843
1844 updateUseShadowTreesIfNeeded(); 1844 updateUseShadowTreesIfNeeded();
1845 updateDistributionIfNeeded(); 1845 updateDistributionIfNeeded();
1846 updateStyleInvalidationIfNeeded(); 1846 updateStyleInvalidationIfNeeded();
1847 1847
1848 // FIXME: We should update style on our ancestor chain before proceeding 1848 // FIXME: We should update style on our ancestor chain before proceeding
1849 // however doing so currently causes several tests to crash, as LocalFrame:: setDocument calls Document::attach 1849 // however doing so currently causes several tests to crash, as LocalFrame:: setDocument calls Document::attach
1850 // before setting the DOMWindow on the LocalFrame, or the SecurityOrigin on the document. The attach, in turn 1850 // before setting the LocalDOMWindow on the LocalFrame, or the SecurityOrigi n on the document. The attach, in turn
1851 // resolves style (here) and then when we resolve style on the parent chain, we may end up 1851 // resolves style (here) and then when we resolve style on the parent chain, we may end up
1852 // re-attaching our containing iframe, which when asked HTMLFrameElementBase ::isURLAllowed 1852 // re-attaching our containing iframe, which when asked HTMLFrameElementBase ::isURLAllowed
1853 // hits a null-dereference due to security code always assuming the document has a SecurityOrigin. 1853 // hits a null-dereference due to security code always assuming the document has a SecurityOrigin.
1854 1854
1855 if (m_elemSheet && m_elemSheet->contents()->usesRemUnits()) 1855 if (m_elemSheet && m_elemSheet->contents()->usesRemUnits())
1856 m_styleEngine->setUsesRemUnit(true); 1856 m_styleEngine->setUsesRemUnit(true);
1857 1857
1858 updateStyle(change); 1858 updateStyle(change);
1859 1859
1860 // As a result of the style recalculation, the currently hovered element mig ht have been 1860 // As a result of the style recalculation, the currently hovered element mig ht have been
(...skipping 345 matching lines...) Expand 10 before | Expand all | Expand 10 after
2206 stopActiveDOMObjects(); 2206 stopActiveDOMObjects();
2207 2207
2208 // FIXME: consider using ActiveDOMObject. 2208 // FIXME: consider using ActiveDOMObject.
2209 if (m_scriptedAnimationController) 2209 if (m_scriptedAnimationController)
2210 m_scriptedAnimationController->clearDocumentPointer(); 2210 m_scriptedAnimationController->clearDocumentPointer();
2211 m_scriptedAnimationController.clear(); 2211 m_scriptedAnimationController.clear();
2212 2212
2213 if (svgExtensions()) 2213 if (svgExtensions())
2214 accessSVGExtensions().pauseAnimations(); 2214 accessSVGExtensions().pauseAnimations();
2215 2215
2216 // FIXME: This shouldn't be needed once DOMWindow becomes ExecutionContext. 2216 // FIXME: This shouldn't be needed once LocalDOMWindow becomes ExecutionCont ext.
2217 if (m_domWindow) 2217 if (m_domWindow)
2218 m_domWindow->clearEventQueue(); 2218 m_domWindow->clearEventQueue();
2219 2219
2220 if (m_renderView) 2220 if (m_renderView)
2221 m_renderView->setIsInWindow(false); 2221 m_renderView->setIsInWindow(false);
2222 2222
2223 if (m_frame) { 2223 if (m_frame) {
2224 FrameView* view = m_frame->view(); 2224 FrameView* view = m_frame->view();
2225 if (view) 2225 if (view)
2226 view->detachCustomScrollbars(); 2226 view->detachCustomScrollbars();
(...skipping 19 matching lines...) Expand all
2246 // callers of Document::detach(). 2246 // callers of Document::detach().
2247 m_frame = 0; 2247 m_frame = 0;
2248 2248
2249 if (m_mediaQueryMatcher) 2249 if (m_mediaQueryMatcher)
2250 m_mediaQueryMatcher->documentDestroyed(); 2250 m_mediaQueryMatcher->documentDestroyed();
2251 2251
2252 lifecycleNotifier().notifyDocumentWasDetached(); 2252 lifecycleNotifier().notifyDocumentWasDetached();
2253 m_lifecycle.advanceTo(DocumentLifecycle::Stopped); 2253 m_lifecycle.advanceTo(DocumentLifecycle::Stopped);
2254 #if ENABLE(OILPAN) 2254 #if ENABLE(OILPAN)
2255 // This mirrors the clearing of the document object's touch 2255 // This mirrors the clearing of the document object's touch
2256 // handlers that happens when the DOMWindow is destructed in a 2256 // handlers that happens when the LocalDOMWindow is destructed in a
2257 // non-Oilpan setting (DOMWindow::removeAllEventListeners()), 2257 // non-Oilpan setting (LocalDOMWindow::removeAllEventListeners()),
2258 // except that it is now done during detach instead. 2258 // except that it is now done during detach instead.
2259 didClearTouchEventHandlers(this); 2259 didClearTouchEventHandlers(this);
2260 2260
2261 // Done with the window, explicitly clear to hasten its 2261 // Done with the window, explicitly clear to hasten its
2262 // destruction. 2262 // destruction.
2263 clearDOMWindow(); 2263 clearDOMWindow();
2264 #endif 2264 #endif
2265 } 2265 }
2266 2266
2267 void Document::prepareForDestruction() 2267 void Document::prepareForDestruction()
2268 { 2268 {
2269 m_markers->prepareForDestruction(); 2269 m_markers->prepareForDestruction();
2270 disconnectDescendantFrames(); 2270 disconnectDescendantFrames();
2271 2271
2272 // The process of disconnecting descendant frames could have already detache d us. 2272 // The process of disconnecting descendant frames could have already detache d us.
2273 if (!isActive()) 2273 if (!isActive())
2274 return; 2274 return;
2275 2275
2276 if (DOMWindow* window = this->domWindow()) 2276 if (LocalDOMWindow* window = this->domWindow())
2277 window->willDetachDocumentFromFrame(); 2277 window->willDetachDocumentFromFrame();
2278 detach(); 2278 detach();
2279 } 2279 }
2280 2280
2281 void Document::removeAllEventListeners() 2281 void Document::removeAllEventListeners()
2282 { 2282 {
2283 ContainerNode::removeAllEventListeners(); 2283 ContainerNode::removeAllEventListeners();
2284 2284
2285 if (DOMWindow* domWindow = this->domWindow()) 2285 if (LocalDOMWindow* domWindow = this->domWindow())
2286 domWindow->removeAllEventListeners(); 2286 domWindow->removeAllEventListeners();
2287 } 2287 }
2288 2288
2289 void Document::clearAXObjectCache() 2289 void Document::clearAXObjectCache()
2290 { 2290 {
2291 ASSERT(topDocument() == this); 2291 ASSERT(topDocument() == this);
2292 // Clear the cache member variable before calling delete because attempts 2292 // Clear the cache member variable before calling delete because attempts
2293 // are made to access it during destruction. 2293 // are made to access it during destruction.
2294 m_axObjectCache.clear(); 2294 m_axObjectCache.clear();
2295 } 2295 }
(...skipping 242 matching lines...) Expand 10 before | Expand all | Expand 10 after
2538 bool wasLocationChangePending = frame() && frame()->navigationScheduler().lo cationChangePending(); 2538 bool wasLocationChangePending = frame() && frame()->navigationScheduler().lo cationChangePending();
2539 bool doload = !parsing() && m_parser && !processingLoadEvent() && !wasLocati onChangePending; 2539 bool doload = !parsing() && m_parser && !processingLoadEvent() && !wasLocati onChangePending;
2540 2540
2541 // If the load was blocked because of a pending location change and the loca tion change triggers a same document 2541 // If the load was blocked because of a pending location change and the loca tion change triggers a same document
2542 // navigation, don't fire load events after the same document navigation com pletes (unless there's an explicit open). 2542 // navigation, don't fire load events after the same document navigation com pletes (unless there's an explicit open).
2543 m_loadEventProgress = LoadEventTried; 2543 m_loadEventProgress = LoadEventTried;
2544 2544
2545 if (!doload) 2545 if (!doload)
2546 return; 2546 return;
2547 2547
2548 // The call to dispatchWindowLoadEvent can detach the DOMWindow and cause it (and its 2548 // The call to dispatchWindowLoadEvent can detach the LocalDOMWindow and cau se it (and its
2549 // attached Document) to be destroyed. 2549 // attached Document) to be destroyed.
2550 RefPtrWillBeRawPtr<DOMWindow> protectedWindow(this->domWindow()); 2550 RefPtrWillBeRawPtr<LocalDOMWindow> protectedWindow(this->domWindow());
2551 2551
2552 m_loadEventProgress = LoadEventInProgress; 2552 m_loadEventProgress = LoadEventInProgress;
2553 2553
2554 ScriptableDocumentParser* parser = scriptableDocumentParser(); 2554 ScriptableDocumentParser* parser = scriptableDocumentParser();
2555 m_wellFormed = parser && parser->wellFormed(); 2555 m_wellFormed = parser && parser->wellFormed();
2556 2556
2557 // We have to clear the parser, in case someone document.write()s from the 2557 // We have to clear the parser, in case someone document.write()s from the
2558 // onLoad event handler, as in Radar 3206524. 2558 // onLoad event handler, as in Radar 3206524.
2559 detachParser(); 2559 detachParser();
2560 2560
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after
2669 RefPtrWillBeRawPtr<Document> protect(this); 2669 RefPtrWillBeRawPtr<Document> protect(this);
2670 if (m_parser) 2670 if (m_parser)
2671 m_parser->stopParsing(); 2671 m_parser->stopParsing();
2672 2672
2673 if (m_loadEventProgress >= LoadEventTried && m_loadEventProgress <= UnloadEv entInProgress) { 2673 if (m_loadEventProgress >= LoadEventTried && m_loadEventProgress <= UnloadEv entInProgress) {
2674 Element* currentFocusedElement = focusedElement(); 2674 Element* currentFocusedElement = focusedElement();
2675 if (isHTMLInputElement(currentFocusedElement)) 2675 if (isHTMLInputElement(currentFocusedElement))
2676 toHTMLInputElement(*currentFocusedElement).endEditing(); 2676 toHTMLInputElement(*currentFocusedElement).endEditing();
2677 if (m_loadEventProgress < PageHideInProgress) { 2677 if (m_loadEventProgress < PageHideInProgress) {
2678 m_loadEventProgress = PageHideInProgress; 2678 m_loadEventProgress = PageHideInProgress;
2679 if (DOMWindow* window = domWindow()) 2679 if (LocalDOMWindow* window = domWindow())
2680 window->dispatchEvent(PageTransitionEvent::create(EventTypeNames ::pagehide, false), this); 2680 window->dispatchEvent(PageTransitionEvent::create(EventTypeNames ::pagehide, false), this);
2681 if (!m_frame) 2681 if (!m_frame)
2682 return; 2682 return;
2683 2683
2684 // The DocumentLoader (and thus its DocumentLoadTiming) might get de stroyed 2684 // The DocumentLoader (and thus its DocumentLoadTiming) might get de stroyed
2685 // while dispatching the event, so protect it to prevent writing the end 2685 // while dispatching the event, so protect it to prevent writing the end
2686 // time into freed memory. 2686 // time into freed memory.
2687 RefPtr<DocumentLoader> documentLoader = m_frame->loader().provision alDocumentLoader(); 2687 RefPtr<DocumentLoader> documentLoader = m_frame->loader().provision alDocumentLoader();
2688 m_loadEventProgress = UnloadEventInProgress; 2688 m_loadEventProgress = UnloadEventInProgress;
2689 RefPtrWillBeRawPtr<Event> unloadEvent(Event::create(EventTypeNames:: unload)); 2689 RefPtrWillBeRawPtr<Event> unloadEvent(Event::create(EventTypeNames:: unload));
(...skipping 1181 matching lines...) Expand 10 before | Expand all | Expand 10 after
3871 } 3871 }
3872 3872
3873 if (m_frame) 3873 if (m_frame)
3874 m_frame->selection().didSplitTextNode(oldNode); 3874 m_frame->selection().didSplitTextNode(oldNode);
3875 3875
3876 // FIXME: This should update markers for spelling and grammar checking. 3876 // FIXME: This should update markers for spelling and grammar checking.
3877 } 3877 }
3878 3878
3879 void Document::setWindowAttributeEventListener(const AtomicString& eventType, Pa ssRefPtr<EventListener> listener) 3879 void Document::setWindowAttributeEventListener(const AtomicString& eventType, Pa ssRefPtr<EventListener> listener)
3880 { 3880 {
3881 DOMWindow* domWindow = this->domWindow(); 3881 LocalDOMWindow* domWindow = this->domWindow();
3882 if (!domWindow) 3882 if (!domWindow)
3883 return; 3883 return;
3884 domWindow->setAttributeEventListener(eventType, listener); 3884 domWindow->setAttributeEventListener(eventType, listener);
3885 } 3885 }
3886 3886
3887 EventListener* Document::getWindowAttributeEventListener(const AtomicString& eve ntType) 3887 EventListener* Document::getWindowAttributeEventListener(const AtomicString& eve ntType)
3888 { 3888 {
3889 DOMWindow* domWindow = this->domWindow(); 3889 LocalDOMWindow* domWindow = this->domWindow();
3890 if (!domWindow) 3890 if (!domWindow)
3891 return 0; 3891 return 0;
3892 return domWindow->getAttributeEventListener(eventType); 3892 return domWindow->getAttributeEventListener(eventType);
3893 } 3893 }
3894 3894
3895 EventQueue* Document::eventQueue() const 3895 EventQueue* Document::eventQueue() const
3896 { 3896 {
3897 if (!m_domWindow) 3897 if (!m_domWindow)
3898 return 0; 3898 return 0;
3899 return m_domWindow->eventQueue(); 3899 return m_domWindow->eventQueue();
(...skipping 1161 matching lines...) Expand 10 before | Expand all | Expand 10 after
5061 { 5061 {
5062 if (!isContextThread()) { 5062 if (!isContextThread()) {
5063 m_taskRunner->postTask(AddConsoleMessageTask::create(source, level, mess age)); 5063 m_taskRunner->postTask(AddConsoleMessageTask::create(source, level, mess age));
5064 return; 5064 return;
5065 } 5065 }
5066 5066
5067 if (m_frame) 5067 if (m_frame)
5068 m_frame->console().addMessage(source, level, message, String(), 0, 0, nu llptr, 0, requestIdentifier); 5068 m_frame->console().addMessage(source, level, message, String(), 0, 0, nu llptr, 0, requestIdentifier);
5069 } 5069 }
5070 5070
5071 // FIXME(crbug.com/305497): This should be removed after ExecutionContext-DOMWin dow migration. 5071 // FIXME(crbug.com/305497): This should be removed after ExecutionContext-LocalD OMWindow migration.
5072 void Document::postTask(PassOwnPtr<ExecutionContextTask> task) 5072 void Document::postTask(PassOwnPtr<ExecutionContextTask> task)
5073 { 5073 {
5074 m_taskRunner->postTask(task); 5074 m_taskRunner->postTask(task);
5075 } 5075 }
5076 5076
5077 void Document::tasksWereSuspended() 5077 void Document::tasksWereSuspended()
5078 { 5078 {
5079 scriptRunner()->suspend(); 5079 scriptRunner()->suspend();
5080 5080
5081 if (m_parser) 5081 if (m_parser)
5082 m_parser->suspendScheduledTasks(); 5082 m_parser->suspendScheduledTasks();
5083 if (m_scriptedAnimationController) 5083 if (m_scriptedAnimationController)
5084 m_scriptedAnimationController->suspend(); 5084 m_scriptedAnimationController->suspend();
5085 } 5085 }
5086 5086
5087 void Document::tasksWereResumed() 5087 void Document::tasksWereResumed()
5088 { 5088 {
5089 scriptRunner()->resume(); 5089 scriptRunner()->resume();
5090 5090
5091 if (m_parser) 5091 if (m_parser)
5092 m_parser->resumeScheduledTasks(); 5092 m_parser->resumeScheduledTasks();
5093 if (m_scriptedAnimationController) 5093 if (m_scriptedAnimationController)
5094 m_scriptedAnimationController->resume(); 5094 m_scriptedAnimationController->resume();
5095 5095
5096 MutationObserver::resumeSuspendedObservers(); 5096 MutationObserver::resumeSuspendedObservers();
5097 } 5097 }
5098 5098
5099 // FIXME: suspendScheduledTasks(), resumeScheduledTasks(), tasksNeedSuspension() 5099 // FIXME: suspendScheduledTasks(), resumeScheduledTasks(), tasksNeedSuspension()
5100 // should be moved to DOMWindow once it inherits ExecutionContext 5100 // should be moved to LocalDOMWindow once it inherits ExecutionContext
5101 void Document::suspendScheduledTasks() 5101 void Document::suspendScheduledTasks()
5102 { 5102 {
5103 ExecutionContext::suspendScheduledTasks(); 5103 ExecutionContext::suspendScheduledTasks();
5104 m_taskRunner->suspend(); 5104 m_taskRunner->suspend();
5105 } 5105 }
5106 5106
5107 void Document::resumeScheduledTasks() 5107 void Document::resumeScheduledTasks()
5108 { 5108 {
5109 ExecutionContext::resumeScheduledTasks(); 5109 ExecutionContext::resumeScheduledTasks();
5110 m_taskRunner->resume(); 5110 m_taskRunner->resume();
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after
5244 m_scriptedAnimationController->cancelCallback(id); 5244 m_scriptedAnimationController->cancelCallback(id);
5245 } 5245 }
5246 5246
5247 void Document::serviceScriptedAnimations(double monotonicAnimationStartTime) 5247 void Document::serviceScriptedAnimations(double monotonicAnimationStartTime)
5248 { 5248 {
5249 if (!m_scriptedAnimationController) 5249 if (!m_scriptedAnimationController)
5250 return; 5250 return;
5251 m_scriptedAnimationController->serviceScriptedAnimations(monotonicAnimationS tartTime); 5251 m_scriptedAnimationController->serviceScriptedAnimations(monotonicAnimationS tartTime);
5252 } 5252 }
5253 5253
5254 PassRefPtrWillBeRawPtr<Touch> Document::createTouch(DOMWindow* window, EventTarg et* target, int identifier, double pageX, double pageY, double screenX, double s creenY, double radiusX, double radiusY, float rotationAngle, float force) const 5254 PassRefPtrWillBeRawPtr<Touch> Document::createTouch(LocalDOMWindow* window, Even tTarget* target, int identifier, double pageX, double pageY, double screenX, dou ble screenY, double radiusX, double radiusY, float rotationAngle, float force) c onst
5255 { 5255 {
5256 // Match behavior from when these types were integers, and avoid surprises f rom someone explicitly 5256 // Match behavior from when these types were integers, and avoid surprises f rom someone explicitly
5257 // passing Infinity/NaN. 5257 // passing Infinity/NaN.
5258 if (!std::isfinite(pageX)) 5258 if (!std::isfinite(pageX))
5259 pageX = 0; 5259 pageX = 0;
5260 if (!std::isfinite(pageY)) 5260 if (!std::isfinite(pageY))
5261 pageY = 0; 5261 pageY = 0;
5262 if (!std::isfinite(screenX)) 5262 if (!std::isfinite(screenX))
5263 screenX = 0; 5263 screenX = 0;
5264 if (!std::isfinite(screenY)) 5264 if (!std::isfinite(screenY))
(...skipping 599 matching lines...) Expand 10 before | Expand all | Expand 10 after
5864 visitor->trace(m_compositorPendingAnimations); 5864 visitor->trace(m_compositorPendingAnimations);
5865 visitor->trace(m_contextDocument); 5865 visitor->trace(m_contextDocument);
5866 visitor->registerWeakMembers<Document, &Document::clearWeakMembers>(this); 5866 visitor->registerWeakMembers<Document, &Document::clearWeakMembers>(this);
5867 DocumentSupplementable::trace(visitor); 5867 DocumentSupplementable::trace(visitor);
5868 TreeScope::trace(visitor); 5868 TreeScope::trace(visitor);
5869 ContainerNode::trace(visitor); 5869 ContainerNode::trace(visitor);
5870 ExecutionContext::trace(visitor); 5870 ExecutionContext::trace(visitor);
5871 } 5871 }
5872 5872
5873 } // namespace WebCore 5873 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/core/dom/Document.h ('k') | Source/core/dom/ExecutionContext.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698