WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
[patch]
Patch
bug-94987-20121123130329.patch (text/plain), 72.26 KB, created by
Robert Flack
on 2012-11-23 10:05:46 PST
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Robert Flack
Created:
2012-11-23 10:05:46 PST
Size:
72.26 KB
patch
obsolete
>Subversion Revision: 135502 >diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog >index f10d147f7a8530df6ee0d65ba256d16f03e6a2a2..5b114e446bc2e1ffb94ff2c499fb34420c332811 100644 >--- a/Source/WebCore/ChangeLog >+++ b/Source/WebCore/ChangeLog >@@ -1,3 +1,96 @@ >+2012-11-22 Robert Flack <flackr@chromium.org> >+ >+ Add systemTime to DOM events >+ https://bugs.webkit.org/show_bug.cgi?id=94987 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Adds a systemTime property to DOM events which exposes the platform event >+ timestamp consistent with Performance.now() timestamps discussed on >+ http://lists.w3.org/Archives/Public/public-web-perf/2012Oct/0046.html and >+ http://lists.webkit.org/pipermail/webkit-dev/2012-October/022574.html >+ >+ Test: platform/chromium/fast/dom/event-systemTime-basic.html >+ >+ * WebCore.exp.in: >+ * WebCore.order: >+ * bindings/generic/RuntimeEnabledFeatures.cpp: >+ (WebCore): >+ * bindings/generic/RuntimeEnabledFeatures.h: >+ (RuntimeEnabledFeatures): >+ (WebCore::RuntimeEnabledFeatures::eventSystemTimeEnabled): >+ (WebCore::RuntimeEnabledFeatures::setEventSystemTimeEnabled): >+ * dom/Document.cpp: >+ (WebCore::Document::monotonicTimeToZeroBasedDocumentTimeMilliseconds): >+ * dom/Document.h: >+ (Document): >+ * dom/Event.cpp: >+ (WebCore::Event::Event): >+ * dom/Event.h: >+ (WebCore::Event::systemTime): >+ (Event): >+ * dom/Event.idl: >+ * dom/KeyboardEvent.cpp: >+ (WebCore::KeyboardEvent::KeyboardEvent): >+ * dom/KeyboardEvent.h: >+ (WebCore::KeyboardEvent::create): >+ (KeyboardEvent): >+ * dom/MouseEvent.cpp: >+ (WebCore::MouseEvent::create): >+ (WebCore::MouseEvent::MouseEvent): >+ (WebCore::SimulatedMouseEvent::SimulatedMouseEvent): >+ * dom/MouseEvent.h: >+ (WebCore::MouseEvent::create): >+ (MouseEvent): >+ * dom/MouseRelatedEvent.cpp: >+ (WebCore::MouseRelatedEvent::MouseRelatedEvent): >+ * dom/MouseRelatedEvent.h: >+ (MouseRelatedEvent): >+ * dom/Node.cpp: >+ (WebCore::Node::dispatchKeyEvent): >+ (WebCore::Node::dispatchMouseEvent): >+ (WebCore::Node::dispatchWheelEvent): >+ * dom/ScriptedAnimationController.cpp: >+ (WebCore::ScriptedAnimationController::serviceScriptedAnimations): >+ * dom/TouchEvent.cpp: >+ (WebCore::TouchEvent::TouchEvent): >+ (WebCore::TouchEvent::initTouchEvent): >+ * dom/TouchEvent.h: >+ (WebCore::TouchEvent::create): >+ (TouchEvent): >+ * dom/UIEvent.cpp: >+ (WebCore::UIEvent::UIEvent): >+ * dom/UIEvent.h: >+ (UIEvent): >+ * dom/UIEventWithKeyState.h: >+ (WebCore::UIEventWithKeyState::UIEventWithKeyState): >+ * dom/WheelEvent.cpp: >+ (WebCore::WheelEvent::WheelEvent): >+ (WebCore::WheelEventDispatchMediator::create): >+ (WebCore::WheelEventDispatchMediator::WheelEventDispatchMediator): >+ * dom/WheelEvent.h: >+ (WebCore::WheelEvent::create): >+ (WheelEvent): >+ (WheelEventDispatchMediator): >+ * loader/DocumentLoadTiming.cpp: >+ (WebCore::DocumentLoadTiming::monotonicTimeToZeroBasedDocumentTimeMilliseconds): >+ * loader/DocumentLoadTiming.h: >+ (DocumentLoadTiming): >+ * page/EventHandler.cpp: >+ (WebCore::EventHandler::dispatchDragEvent): >+ (WebCore::EventHandler::keyEvent): >+ (WebCore::EventHandler::handleTouchEvent): >+ * page/Performance.cpp: >+ (WebCore::Performance::now): >+ * page/PerformanceResourceTiming.cpp: >+ (WebCore::monotonicTimeToDocumentMilliseconds): >+ * testing/Internals.cpp: >+ (WebCore::Internals::navigationStartTime): >+ (WebCore): >+ (WebCore::Internals::dispatchPlatformMouseEvent): >+ * testing/Internals.h: >+ * testing/Internals.idl: >+ > 2012-11-22 Kentaro Hara <haraken@chromium.org> > > [V8] Rename toWebCoreStringWithNullOrUndefinedCheck() with toWebCoreStringWithUndefinedOrNullCheck() >diff --git a/Source/WebKit/chromium/ChangeLog b/Source/WebKit/chromium/ChangeLog >index d4d3171f017f390a6c89e20866aca944f57eea64..cdfb08f23ec21190ef4fe127eec335ff9782cbb4 100644 >--- a/Source/WebKit/chromium/ChangeLog >+++ b/Source/WebKit/chromium/ChangeLog >@@ -1,3 +1,25 @@ >+2012-11-22 Robert Flack <flackr@chromium.org> >+ >+ Add systemTime to DOM events >+ https://bugs.webkit.org/show_bug.cgi?id=94987 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Adds a systemTime property to DOM events which exposes the platform event >+ timestamp consistent with Performance.now() timestamps discussed on >+ http://lists.w3.org/Archives/Public/public-web-perf/2012Oct/0046.html and >+ http://lists.webkit.org/pipermail/webkit-dev/2012-October/022574.html >+ >+ * features.gypi: >+ * public/WebRuntimeFeatures.h: >+ (WebRuntimeFeatures): >+ * src/WebInputEventConversion.cpp: >+ (WebKit::PlatformKeyboardEventBuilder::PlatformKeyboardEventBuilder): >+ * src/WebRuntimeFeatures.cpp: >+ (WebKit::WebRuntimeFeatures::enableEventSystemTime): >+ (WebKit): >+ (WebKit::WebRuntimeFeatures::isEventSystemTimeEnabled): >+ > 2012-11-21 Tien-Ren Chen <trchen@chromium.org> > > [chromium] Device scale factor should be no-op when applyDeviceScaleFactorInCompositor == 0 >diff --git a/Source/WebKit/mac/ChangeLog b/Source/WebKit/mac/ChangeLog >index 86f91b3007a6687d56d5bfe4c6a64fbbb3a12485..fdda6f322af91f98d1ed9843de5e8b035e16b2e4 100644 >--- a/Source/WebKit/mac/ChangeLog >+++ b/Source/WebKit/mac/ChangeLog >@@ -1,3 +1,18 @@ >+2012-11-22 Robert Flack <flackr@chromium.org> >+ >+ Add systemTime to DOM events >+ https://bugs.webkit.org/show_bug.cgi?id=94987 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Adds a systemTime property to DOM events which exposes the platform event >+ timestamp consistent with Performance.now() timestamps discussed on >+ http://lists.w3.org/Archives/Public/public-web-perf/2012Oct/0046.html and >+ http://lists.webkit.org/pipermail/webkit-dev/2012-October/022574.html >+ >+ * WebView/WebPDFView.mm: >+ (-[WebPDFView PDFViewWillClickOnLink:withURL:]): >+ > 2012-11-21 Allan Sandfeld Jensen <allan.jensen@digia.com> > > Disambiguate innerNodeFramePoint and mainFramePoint >diff --git a/Source/WebKit2/ChangeLog b/Source/WebKit2/ChangeLog >index e411e91a88c11900eac6ebe23efa9304eb4b0a41..eacd9e33ee663329f9894c62e73cd0d6f42feb72 100644 >--- a/Source/WebKit2/ChangeLog >+++ b/Source/WebKit2/ChangeLog >@@ -1,3 +1,20 @@ >+2012-11-22 Robert Flack <flackr@chromium.org> >+ >+ Add systemTime to DOM events >+ https://bugs.webkit.org/show_bug.cgi?id=94987 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Adds a systemTime property to DOM events which exposes the platform event >+ timestamp consistent with Performance.now() timestamps discussed on >+ http://lists.w3.org/Archives/Public/public-web-perf/2012Oct/0046.html and >+ http://lists.webkit.org/pipermail/webkit-dev/2012-October/022574.html >+ >+ * WebProcess/WebPage/WebPage.cpp: >+ (WebKit::WebPage::linkClicked): >+ * win/WebKit2.def: >+ * win/WebKit2CFLite.def: >+ > 2012-11-22 Eunmi Lee <eunmi15.lee@samsung.com> > > [EFL][WK2] Correct the parameters of WebPlatformTouchPoint. >diff --git a/Source/WebCore/WebCore.exp.in b/Source/WebCore/WebCore.exp.in >index 99a044bb3ad6c08cabcf18f61fad0277c20691c4..cda4afa62ae1cd58a0a2c547882ba9a0c3959d86 100644 >--- a/Source/WebCore/WebCore.exp.in >+++ b/Source/WebCore/WebCore.exp.in >@@ -71,8 +71,8 @@ __ZN7WebCore10CredentialC1ERKN3WTF6StringES4_NS_21CredentialPersistenceE > __ZN7WebCore10CredentialC1Ev > __ZN7WebCore10FloatPointC1ERKNS_8IntPointE > __ZN7WebCore10JSDocument6s_infoE >-__ZN7WebCore10MouseEvent6createERKN3WTF12AtomicStringENS1_10PassRefPtrINS_9DOMWindowEEERKNS_18PlatformMouseEventEiNS5_INS_4NodeEEE >-__ZN7WebCore10MouseEventC1ERKN3WTF12AtomicStringEbbNS1_10PassRefPtrINS_9DOMWindowEEEiiiiibbbbtNS5_INS_11EventTargetEEENS5_INS_9ClipboardEEEb >+__ZN7WebCore10MouseEvent6createERKN3WTF12AtomicStringENS1_10PassRefPtrINS_9DOMWindowEEERKNS_18PlatformMouseEventEiNS5_INS_4NodeEEEd >+__ZN7WebCore10MouseEventC1ERKN3WTF12AtomicStringEbbNS1_10PassRefPtrINS_9DOMWindowEEEiiiiibbbbtNS5_INS_11EventTargetEEENS5_INS_9ClipboardEEEbd > __ZN7WebCore10RenderView10compositorEv > __ZN7WebCore10ScrollView17setUseFixedLayoutEb > __ZN7WebCore10ScrollView18setFixedLayoutSizeERKNS_7IntSizeE >@@ -224,7 +224,7 @@ __ZN7WebCore13IdentifierRep3getEPKc > __ZN7WebCore13IdentifierRep3getEi > __ZN7WebCore13JSHTMLElement6s_infoE > __ZN7WebCore13KeyboardEventC1ERKN3WTF12AtomicStringEbbPNS_9DOMWindowERKNS1_6StringEjbbbbb >-__ZN7WebCore13KeyboardEventC1ERKNS_21PlatformKeyboardEventEPNS_9DOMWindowE >+__ZN7WebCore13KeyboardEventC1ERKNS_21PlatformKeyboardEventEPNS_9DOMWindowEd > __ZN7WebCore13QualifiedNameD1Ev > __ZN7WebCore13ResourceErrorC1EP7NSError > __ZN7WebCore13ResourceErrorC1EP9__CFError >@@ -498,6 +498,7 @@ __ZN7WebCore17ViewportArguments19deprecatedTargetDPIE > __ZN7WebCore17cacheDOMStructureEPNS_17JSDOMGlobalObjectEPN3JSC9StructureEPKNS2_9ClassInfoE > __ZN7WebCore17openTemporaryFileERKN3WTF6StringERi > __ZN7WebCore17userVisibleStringEP5NSURL >+__ZNK7WebCore8Document48monotonicTimeToZeroBasedDocumentTimeMillisecondsEd > __ZN7WebCore18DOMWindowExtensionC1EPNS_5FrameEPNS_15DOMWrapperWorldE > __ZN7WebCore18HTMLContentElement6createEPNS_8DocumentE > __ZN7WebCore10Pasteboard17generalPasteboardEv >@@ -563,6 +564,7 @@ __ZN7WebCore20DictationAlternativeC1Ejjy > __ZN7WebCore20DictationAlternativeC1Ev > __ZN7WebCore20DisplaySleepDisablerC1EPKc > __ZN7WebCore20DisplaySleepDisablerD1Ev >+__ZN7WebCore4Node18dispatchMouseEventERKNS_18PlatformMouseEventERKN3WTF12AtomicStringEiPS0_ > __ZN7WebCore20NodeRenderingContextC1EPNS_4NodeE > __ZN7WebCore20NodeRenderingContextD1Ev > __ZN7WebCore20RenderEmbeddedObject29setPluginUnavailabilityReasonENS0_26PluginUnavailabilityReasonE >@@ -917,6 +919,7 @@ __ZN7WebCore8Document27removeMediaCanStartListenerEPNS_21MediaCanStartListenerE > __ZN7WebCore8Document36updateLayoutIgnorePendingStylesheetsEv > __ZN7WebCore8Document4headEv > __ZN7WebCore8Document8iconURLsEv >+__ZNK7WebCore8Document6loaderEv > __ZN7WebCore8FormData6createEPKvm > __ZN7WebCore8FormDataD1Ev > __ZN7WebCore8Gradient12addColorStopEfRKNS_5ColorE >diff --git a/Source/WebCore/WebCore.order b/Source/WebCore/WebCore.order >index f432060d2ae59d9f2bcc7933944a889001d9d512..30cf5e788b28aad601fddb7999910dba68bf6faf 100644 >--- a/Source/WebCore/WebCore.order >+++ b/Source/WebCore/WebCore.order >@@ -6376,7 +6376,7 @@ __ZN7WebCore9FrameView25resetDeferredRepaintDelayEv > __ZN7WebCore12EventHandler26updateMouseEventTargetNodeEPNS_4NodeERKNS_18PlatformMouseEventEb > __ZNK7WebCore17ScrollAnimatorMac23mouseEnteredContentAreaEv > __ZN7WebCore4Node18dispatchMouseEventERKNS_18PlatformMouseEventERKN3WTF12AtomicStringEiPS0_ >-__ZN7WebCore10MouseEvent6createERKN3WTF12AtomicStringENS1_10PassRefPtrINS_9DOMWindowEEERKNS_18PlatformMouseEventEiNS5_INS_4NodeEEE >+__ZN7WebCore10MouseEvent6createERKN3WTF12AtomicStringENS1_10PassRefPtrINS_9DOMWindowEEERKNS_18PlatformMouseEventEiNS5_INS_4NodeEEEd > __ZN7WebCore26MouseEventDispatchMediatorC1EN3WTF10PassRefPtrINS_10MouseEventEEE > __ZN7WebCore21EventDispatchMediatorC2EN3WTF10PassRefPtrINS_5EventEEE > __ZNK7WebCore26MouseEventDispatchMediator13dispatchEventEPNS_15EventDispatcherE >@@ -13980,8 +13980,8 @@ __ZN7WebCore12EventHandler18accessKeyModifiersEv > __ZNK7WebCore12EventHandler38needsKeyboardEventDisambiguationQuirksEv > __ZN7WebCore21PlatformKeyboardEventC2ERKS0_ > __ZN7WebCore21PlatformKeyboardEvent24disambiguateKeyDownEventENS0_4TypeEb >-__ZN7WebCore13KeyboardEventC1ERKNS_21PlatformKeyboardEventEPNS_9DOMWindowE >-__ZN7WebCore13KeyboardEventC2ERKNS_21PlatformKeyboardEventEPNS_9DOMWindowE >+__ZN7WebCore13KeyboardEventC1ERKNS_21PlatformKeyboardEventEPNS_9DOMWindowEd >+__ZN7WebCore13KeyboardEventC2ERKNS_21PlatformKeyboardEventEPNS_9DOMWindowEd > __ZN7WebCore6Editor24handleInputMethodKeydownEPNS_13KeyboardEventE > __ZNK3JSC8Bindings17ObjCRuntimeObject23getInternalObjCInstanceEv > __ZNK7WebCore13KeyboardEvent15isKeyboardEventEv >@@ -15316,8 +15316,8 @@ __ZNK7WebCore14DragController13draggableNodeEPKNS_5FrameEPNS_4NodeERKNS_8IntPoin > __ZNK7WebCore12EventHandler22dragHysteresisExceededERKNS_8IntPointE > __ZNK7WebCore12EventHandler23createDraggingClipboardEv > __ZN7WebCore12EventHandler17dispatchDragEventERKN3WTF12AtomicStringEPNS_4NodeERKNS_18PlatformMouseEventEPNS_9ClipboardE >-__ZN7WebCore10MouseEvent6createERKN3WTF12AtomicStringEbbNS1_10PassRefPtrINS_9DOMWindowEEEiiiiibbbbtNS5_INS_11EventTargetEEENS5_INS_9ClipboardEEEb >-__ZN7WebCore10MouseEventC1ERKN3WTF12AtomicStringEbbNS1_10PassRefPtrINS_9DOMWindowEEEiiiiibbbbtNS5_INS_11EventTargetEEENS5_INS_9ClipboardEEEb >+__ZN7WebCore10MouseEvent6createERKN3WTF12AtomicStringEbbNS1_10PassRefPtrINS_9DOMWindowEEEiiiiibbbbtNS5_INS_11EventTargetEEENS5_INS_9ClipboardEEEbd >+__ZN7WebCore10MouseEventC1ERKN3WTF12AtomicStringEbbNS1_10PassRefPtrINS_9DOMWindowEEEiiiiibbbbtNS5_INS_11EventTargetEEENS5_INS_9ClipboardEEEbd > __ZNK7WebCore9Clipboard15sourceOperationEv > __ZN7WebCoreL14dragOpFromIEOpERKN3WTF6StringE > __ZN7WebCore14DragController9startDragEPNS_5FrameERKNS_9DragStateENS_13DragOperationERKNS_18PlatformMouseEventERKNS_8IntPointE >diff --git a/Source/WebCore/bindings/generic/RuntimeEnabledFeatures.cpp b/Source/WebCore/bindings/generic/RuntimeEnabledFeatures.cpp >index ea3679e2d0370b502134698d4fc2acaf305b878b..616b3873ced4687ee001520098ee7e42f890ab01 100644 >--- a/Source/WebCore/bindings/generic/RuntimeEnabledFeatures.cpp >+++ b/Source/WebCore/bindings/generic/RuntimeEnabledFeatures.cpp >@@ -228,6 +228,10 @@ bool RuntimeEnabledFeatures::isInputTypeWeekEnabled = true; > bool RuntimeEnabledFeatures::isDialogElementEnabled = false; > #endif > >+#if ENABLE(EVENT_SYSTEM_TIME) >+bool RuntimeEnabledFeatures::isEventSystemTimeEnabled = false; >+#endif >+ > #if ENABLE(REQUEST_AUTOCOMPLETE) > bool RuntimeEnabledFeatures::isRequestAutocompleteEnabled = false; > #endif >diff --git a/Source/WebCore/bindings/generic/RuntimeEnabledFeatures.h b/Source/WebCore/bindings/generic/RuntimeEnabledFeatures.h >index bb95ce8456cb923cb903004a1faef6fe79831b44..cc02cb63ff0ae377dfe15a8514f6b0f2a0eac6dc 100644 >--- a/Source/WebCore/bindings/generic/RuntimeEnabledFeatures.h >+++ b/Source/WebCore/bindings/generic/RuntimeEnabledFeatures.h >@@ -251,6 +251,11 @@ public: > // The lang attribute support is incomplete and should only be turned on for tests. > static void setLangAttributeAwareFormControlUIEnabled(bool isEnabled) { isLangAttributeAwareFormControlUIEnabled = isEnabled; } > >+#if ENABLE(EVENT_SYSTEM_TIME) >+ static bool eventSystemTimeEnabled() { return isEventSystemTimeEnabled; } >+ static void setEventSystemTimeEnabled(bool isEnabled) { isEventSystemTimeEnabled = isEnabled; } >+#endif >+ > #if ENABLE(REQUEST_AUTOCOMPLETE) > static bool requestAutocompleteEnabled() { return isRequestAutocompleteEnabled; } > static void setRequestAutocompleteEnabled(bool isEnabled) { isRequestAutocompleteEnabled = isEnabled; } >@@ -353,6 +358,10 @@ private: > static bool isDialogElementEnabled; > #endif > >+#if ENABLE(EVENT_SYSTEM_TIME) >+ static bool isEventSystemTimeEnabled; >+#endif >+ > #if ENABLE(REQUEST_AUTOCOMPLETE) > static bool isRequestAutocompleteEnabled; > #endif >diff --git a/Source/WebCore/dom/Document.cpp b/Source/WebCore/dom/Document.cpp >index 436903418e9f5c97bac547c1f21a2cec1ce5074d..ea2b49c6298e084f326956417c38e1d2ac91da2b 100644 >--- a/Source/WebCore/dom/Document.cpp >+++ b/Source/WebCore/dom/Document.cpp >@@ -5485,6 +5485,13 @@ void Document::removeFromTopLayer(Element* element) > } > #endif > >+double Document::monotonicTimeToZeroBasedDocumentTimeMilliseconds(double monotonicTime) const >+{ >+ if (!loader() || !loader()->timing()) >+ return 0; >+ return loader()->timing()->monotonicTimeToZeroBasedDocumentTimeMilliseconds(monotonicTime); >+} >+ > #if ENABLE(POINTER_LOCK) > void Document::webkitExitPointerLock() > { >diff --git a/Source/WebCore/dom/Document.h b/Source/WebCore/dom/Document.h >index 343b0db578f4de9b0c52d17639d75b509e606c4a..00e0fff1237ef68fa6939e9abc6fe6c02fc2286e 100644 >--- a/Source/WebCore/dom/Document.h >+++ b/Source/WebCore/dom/Document.h >@@ -1174,6 +1174,8 @@ public: > const Vector<RefPtr<Element> >& topLayerElements() const { return m_topLayerElements; } > #endif > >+ double monotonicTimeToZeroBasedDocumentTimeMilliseconds(double monotonicTime) const; >+ > protected: > Document(Frame*, const KURL&, bool isXHTML, bool isHTML); > >diff --git a/Source/WebCore/dom/Event.cpp b/Source/WebCore/dom/Event.cpp >index c1e609ff40a0611a72c2c7c11081512beb28dc55..2257ab662b9cbea9cdee425cb1b7a83956b8ff6f 100644 >--- a/Source/WebCore/dom/Event.cpp >+++ b/Source/WebCore/dom/Event.cpp >@@ -51,10 +51,11 @@ Event::Event() > , m_eventPhase(0) > , m_currentTarget(0) > , m_createTime(convertSecondsToDOMTimeStamp(currentTime())) >+ , m_systemTime(0) > { > } > >-Event::Event(const AtomicString& eventType, bool canBubbleArg, bool cancelableArg) >+Event::Event(const AtomicString& eventType, bool canBubbleArg, bool cancelableArg, double systemTime) > : m_type(eventType) > , m_canBubble(canBubbleArg) > , m_cancelable(cancelableArg) >@@ -66,6 +67,7 @@ Event::Event(const AtomicString& eventType, bool canBubbleArg, bool cancelableAr > , m_eventPhase(0) > , m_currentTarget(0) > , m_createTime(convertSecondsToDOMTimeStamp(currentTime())) >+ , m_systemTime(systemTime) > { > } > >@@ -81,6 +83,7 @@ Event::Event(const AtomicString& eventType, const EventInit& initializer) > , m_eventPhase(0) > , m_currentTarget(0) > , m_createTime(convertSecondsToDOMTimeStamp(currentTime())) >+ , m_systemTime(0) > { > } > >diff --git a/Source/WebCore/dom/Event.h b/Source/WebCore/dom/Event.h >index 36f029356aafcb071c31f03016167597f6d25db8..ca40f4b8cac3ffb83a7d8fa4116f1dd8f06fad44 100644 >--- a/Source/WebCore/dom/Event.h >+++ b/Source/WebCore/dom/Event.h >@@ -106,6 +106,7 @@ public: > bool bubbles() const { return m_canBubble; } > bool cancelable() const { return m_cancelable; } > DOMTimeStamp timeStamp() const { return m_createTime; } >+ double systemTime() const { return m_systemTime; } > > void stopPropagation() { m_propagationStopped = true; } > void stopImmediatePropagation() { m_immediatePropagationStopped = true; } >@@ -167,7 +168,7 @@ public: > > protected: > Event(); >- Event(const AtomicString& type, bool canBubble, bool cancelable); >+ Event(const AtomicString& type, bool canBubble, bool cancelable, double systemTime = 0); > Event(const AtomicString& type, const EventInit&); > > virtual void receivedTarget(); >@@ -188,6 +189,7 @@ private: > EventTarget* m_currentTarget; > RefPtr<EventTarget> m_target; > DOMTimeStamp m_createTime; >+ double m_systemTime; > > RefPtr<Event> m_underlyingEvent; > }; >diff --git a/Source/WebCore/dom/Event.idl b/Source/WebCore/dom/Event.idl >index a9af04689e525b123d49d1448a94fb4e1464a175..3fa5a71b1d500510bbc542cac0720cb924fbb16e 100644 >--- a/Source/WebCore/dom/Event.idl >+++ b/Source/WebCore/dom/Event.idl >@@ -59,6 +59,7 @@ > [InitializedByEventConstructor] readonly attribute boolean bubbles; > [InitializedByEventConstructor] readonly attribute boolean cancelable; > readonly attribute DOMTimeStamp timeStamp; >+ [Conditional=EVENT_SYSTEM_TIME, V8EnabledAtRuntime=eventSystemTime] readonly attribute double systemTime; > > void stopPropagation(); > void preventDefault(); >diff --git a/Source/WebCore/dom/KeyboardEvent.cpp b/Source/WebCore/dom/KeyboardEvent.cpp >index 1c6119f5ba3cbe2d7b2c16368cb222200fb56d36..71475fe641ecbc6dc67314882af5e26707a54092 100644 >--- a/Source/WebCore/dom/KeyboardEvent.cpp >+++ b/Source/WebCore/dom/KeyboardEvent.cpp >@@ -98,9 +98,8 @@ KeyboardEvent::KeyboardEvent() > { > } > >-KeyboardEvent::KeyboardEvent(const PlatformKeyboardEvent& key, AbstractView* view) >- : UIEventWithKeyState(eventTypeForKeyboardEventType(key.type()), >- true, true, view, 0, key.ctrlKey(), key.altKey(), key.shiftKey(), key.metaKey()) >+KeyboardEvent::KeyboardEvent(const PlatformKeyboardEvent& key, AbstractView* view, double timeStamp) >+ : UIEventWithKeyState(eventTypeForKeyboardEventType(key.type()), true, true, view, 0, key.ctrlKey(), key.altKey(), key.shiftKey(), key.metaKey(), timeStamp) > , m_keyEvent(adoptPtr(new PlatformKeyboardEvent(key))) > , m_keyIdentifier(key.keyIdentifier()) > , m_keyLocation(keyLocationCode(key)) >diff --git a/Source/WebCore/dom/KeyboardEvent.h b/Source/WebCore/dom/KeyboardEvent.h >index 1537410bebb60bf819b0e3a8a3012620565d8811..1c369901d6730b761920a692c68b50f009d482e4 100644 >--- a/Source/WebCore/dom/KeyboardEvent.h >+++ b/Source/WebCore/dom/KeyboardEvent.h >@@ -59,9 +59,9 @@ namespace WebCore { > { > return adoptRef(new KeyboardEvent); > } >- static PassRefPtr<KeyboardEvent> create(const PlatformKeyboardEvent& platformEvent, AbstractView* view) >+ static PassRefPtr<KeyboardEvent> create(const PlatformKeyboardEvent& platformEvent, AbstractView* view, double systemTime = 0) > { >- return adoptRef(new KeyboardEvent(platformEvent, view)); >+ return adoptRef(new KeyboardEvent(platformEvent, view, systemTime)); > } > static PassRefPtr<KeyboardEvent> create(const AtomicString& type, bool canBubble, bool cancelable, AbstractView* view, > const String& keyIdentifier, unsigned keyLocation, >@@ -99,7 +99,7 @@ namespace WebCore { > > private: > KeyboardEvent(); >- KeyboardEvent(const PlatformKeyboardEvent&, AbstractView*); >+ KeyboardEvent(const PlatformKeyboardEvent&, AbstractView*, double systemTime); > KeyboardEvent(const AtomicString& type, bool canBubble, bool cancelable, AbstractView*, > const String& keyIdentifier, unsigned keyLocation, > bool ctrlKey, bool altKey, bool shiftKey, bool metaKey, bool altGraphKey); >diff --git a/Source/WebCore/dom/MouseEvent.cpp b/Source/WebCore/dom/MouseEvent.cpp >index 9e92c27136ccf90dbe3b7b260b5bb67aea4456ab..3f4da96704bb5a8445749fe86c1c68e5e3d47212 100644 >--- a/Source/WebCore/dom/MouseEvent.cpp >+++ b/Source/WebCore/dom/MouseEvent.cpp >@@ -32,7 +32,7 @@ > > namespace WebCore { > >-PassRefPtr<MouseEvent> MouseEvent::create(const AtomicString& eventType, PassRefPtr<AbstractView> view, const PlatformMouseEvent& event, int detail, PassRefPtr<Node> relatedTarget) >+PassRefPtr<MouseEvent> MouseEvent::create(const AtomicString& eventType, PassRefPtr<AbstractView> view, const PlatformMouseEvent& event, int detail, PassRefPtr<Node> relatedTarget, double systemTime) > { > ASSERT(event.type() == PlatformEvent::MouseMoved || event.button() != NoButton); > >@@ -44,7 +44,7 @@ PassRefPtr<MouseEvent> MouseEvent::create(const AtomicString& eventType, PassRef > event.movementDelta().x(), event.movementDelta().y(), > #endif > event.ctrlKey(), event.altKey(), event.shiftKey(), event.metaKey(), event.button(), >- relatedTarget, 0, false); >+ relatedTarget, 0, false, systemTime); > } > > MouseEvent::MouseEvent() >@@ -54,19 +54,21 @@ MouseEvent::MouseEvent() > } > > MouseEvent::MouseEvent(const AtomicString& eventType, bool canBubble, bool cancelable, PassRefPtr<AbstractView> view, >- int detail, int screenX, int screenY, int pageX, int pageY, >+ int detail, int screenX, int screenY, int pageX, int pageY, > #if ENABLE(POINTER_LOCK) > int movementX, int movementY, > #endif >- bool ctrlKey, bool altKey, bool shiftKey, bool metaKey, >- unsigned short button, PassRefPtr<EventTarget> relatedTarget, >- PassRefPtr<Clipboard> clipboard, bool isSimulated) >+ bool ctrlKey, bool altKey, bool shiftKey, bool metaKey, >+ unsigned short button, PassRefPtr<EventTarget> relatedTarget, >+ PassRefPtr<Clipboard> clipboard, bool isSimulated, >+ double systemTime) > : MouseRelatedEvent(eventType, canBubble, cancelable, view, detail, IntPoint(screenX, screenY), > IntPoint(pageX, pageY), > #if ENABLE(POINTER_LOCK) > IntPoint(movementX, movementY), > #endif >- ctrlKey, altKey, shiftKey, metaKey, isSimulated) >+ ctrlKey, altKey, shiftKey, metaKey, isSimulated, >+ systemTime) > , m_button(button == (unsigned short)-1 ? 0 : button) > , m_buttonDown(button != (unsigned short)-1) > , m_relatedTarget(relatedTarget) >@@ -190,9 +192,9 @@ SimulatedMouseEvent::~SimulatedMouseEvent() > SimulatedMouseEvent::SimulatedMouseEvent(const AtomicString& eventType, PassRefPtr<AbstractView> view, PassRefPtr<Event> underlyingEvent) > : MouseEvent(eventType, true, true, view, 0, 0, 0, 0, 0, > #if ENABLE(POINTER_LOCK) >- 0, 0, >+ 0, 0, > #endif >- false, false, false, false, 0, 0, 0, true) >+ false, false, false, false, 0, 0, 0, true, 0) > { > if (UIEventWithKeyState* keyStateEvent = findEventWithKeyState(underlyingEvent.get())) { > m_ctrlKey = keyStateEvent->ctrlKey(); >diff --git a/Source/WebCore/dom/MouseEvent.h b/Source/WebCore/dom/MouseEvent.h >index a1c7922b9c7d74f2b8d164e84089ecd457a8cc5e..30467799e7d8d82416d21d379a08702df6282b88 100644 >--- a/Source/WebCore/dom/MouseEvent.h >+++ b/Source/WebCore/dom/MouseEvent.h >@@ -46,15 +46,15 @@ class PlatformMouseEvent; > int movementX, int movementY, > #endif > bool ctrlKey, bool altKey, bool shiftKey, bool metaKey, unsigned short button, >- PassRefPtr<EventTarget> relatedTarget, PassRefPtr<Clipboard> clipboard = 0, bool isSimulated = false) >+ PassRefPtr<EventTarget> relatedTarget, PassRefPtr<Clipboard> clipboard = 0, bool isSimulated = false, double systemTime = 0) > { > return adoptRef(new MouseEvent(type, canBubble, cancelable, view, detail, screenX, screenY, pageX, pageY, > #if ENABLE(POINTER_LOCK) > movementX, movementY, > #endif >- ctrlKey, altKey, shiftKey, metaKey, button, relatedTarget, clipboard, isSimulated)); >+ ctrlKey, altKey, shiftKey, metaKey, button, relatedTarget, clipboard, isSimulated, systemTime)); > } >- static PassRefPtr<MouseEvent> create(const AtomicString& eventType, PassRefPtr<AbstractView>, const PlatformMouseEvent&, int detail, PassRefPtr<Node> relatedTarget); >+ static PassRefPtr<MouseEvent> create(const AtomicString& eventType, PassRefPtr<AbstractView>, const PlatformMouseEvent&, int detail, PassRefPtr<Node> relatedTarget, double systemTime); > > virtual ~MouseEvent(); > >@@ -87,12 +87,12 @@ class PlatformMouseEvent; > > protected: > MouseEvent(const AtomicString& type, bool canBubble, bool cancelable, PassRefPtr<AbstractView>, >- int detail, int screenX, int screenY, int pageX, int pageY, >+ int detail, int screenX, int screenY, int pageX, int pageY, > #if ENABLE(POINTER_LOCK) >- int movementX, int movementY, >+ int movementX, int movementY, > #endif >- bool ctrlKey, bool altKey, bool shiftKey, bool metaKey, unsigned short button, >- PassRefPtr<EventTarget> relatedTarget, PassRefPtr<Clipboard> clipboard, bool isSimulated); >+ bool ctrlKey, bool altKey, bool shiftKey, bool metaKey, unsigned short button, >+ PassRefPtr<EventTarget> relatedTarget, PassRefPtr<Clipboard>, bool isSimulated, double systemTime); > > protected: > MouseEvent(); >diff --git a/Source/WebCore/dom/MouseRelatedEvent.cpp b/Source/WebCore/dom/MouseRelatedEvent.cpp >index 801aa671d1c7888211107dbd1c0659eb1334e4c9..dcce7f0e57c14ca4a9da17d9c180eb6b73927961 100644 >--- a/Source/WebCore/dom/MouseRelatedEvent.cpp >+++ b/Source/WebCore/dom/MouseRelatedEvent.cpp >@@ -52,13 +52,14 @@ static LayoutSize contentsScrollOffset(AbstractView* abstractView) > return LayoutSize(frameView->scrollX() / scaleFactor, frameView->scrollY() / scaleFactor); > } > >-MouseRelatedEvent::MouseRelatedEvent(const AtomicString& eventType, bool canBubble, bool cancelable, PassRefPtr<AbstractView> abstractView, >- int detail, const IntPoint& screenLocation, const IntPoint& windowLocation, >+MouseRelatedEvent::MouseRelatedEvent( >+ const AtomicString& eventType, bool canBubble, bool cancelable, PassRefPtr<AbstractView> abstractView, >+ int detail, const IntPoint& screenLocation, const IntPoint& windowLocation, > #if ENABLE(POINTER_LOCK) >- const IntPoint& movementDelta, >+ const IntPoint& movementDelta, > #endif >- bool ctrlKey, bool altKey, bool shiftKey, bool metaKey, bool isSimulated) >- : UIEventWithKeyState(eventType, canBubble, cancelable, abstractView, detail, ctrlKey, altKey, shiftKey, metaKey) >+ bool ctrlKey, bool altKey, bool shiftKey, bool metaKey, bool isSimulated, double systemTime) >+ : UIEventWithKeyState(eventType, canBubble, cancelable, abstractView, detail, ctrlKey, altKey, shiftKey, metaKey, systemTime) > , m_screenLocation(screenLocation) > #if ENABLE(POINTER_LOCK) > , m_movementDelta(movementDelta) >diff --git a/Source/WebCore/dom/MouseRelatedEvent.h b/Source/WebCore/dom/MouseRelatedEvent.h >index a2de9a4b6aa29d6a945fd107df1dc9a1f093ad8d..57225689ad010f65ab220e0d4f78a0e721326b8a 100644 >--- a/Source/WebCore/dom/MouseRelatedEvent.h >+++ b/Source/WebCore/dom/MouseRelatedEvent.h >@@ -62,12 +62,13 @@ namespace WebCore { > > protected: > MouseRelatedEvent(); >- MouseRelatedEvent(const AtomicString& type, bool canBubble, bool cancelable, PassRefPtr<AbstractView>, >- int detail, const IntPoint& screenLocation, const IntPoint& windowLocation, >+ MouseRelatedEvent( >+ const AtomicString& type, bool canBubble, bool cancelable, PassRefPtr<AbstractView>, >+ int detail, const IntPoint& screenLocation, const IntPoint& windowLocation, > #if ENABLE(POINTER_LOCK) >- const IntPoint& movementDelta, >+ const IntPoint& movementDelta, > #endif >- bool ctrlKey, bool altKey, bool shiftKey, bool metaKey, bool isSimulated = false); >+ bool ctrlKey, bool altKey, bool shiftKey, bool metaKey, bool isSimulated = false, double systemTime = 0); > > void initCoordinates(); > void initCoordinates(const LayoutPoint& clientLocation); >diff --git a/Source/WebCore/dom/Node.cpp b/Source/WebCore/dom/Node.cpp >index bdeb6e243c69eb904dc5884114eac5af3d771eb0..0ab060a5679d438bb0bb040bd2ed4e382eca1256 100644 >--- a/Source/WebCore/dom/Node.cpp >+++ b/Source/WebCore/dom/Node.cpp >@@ -45,6 +45,7 @@ > #include "DOMImplementation.h" > #include "DOMSettableTokenList.h" > #include "Document.h" >+#include "DocumentLoader.h" > #include "DocumentType.h" > #include "DynamicNodeList.h" > #include "Element.h" >@@ -76,6 +77,7 @@ > #include "NodeRareData.h" > #include "NodeRenderingContext.h" > #include "Page.h" >+#include "PlatformKeyboardEvent.h" > #include "PlatformMouseEvent.h" > #include "PlatformWheelEvent.h" > #include "ProcessingInstruction.h" >@@ -2601,13 +2603,13 @@ bool Node::dispatchDOMActivateEvent(int detail, PassRefPtr<Event> underlyingEven > > bool Node::dispatchKeyEvent(const PlatformKeyboardEvent& event) > { >- return EventDispatcher::dispatchEvent(this, KeyboardEventDispatchMediator::create(KeyboardEvent::create(event, document()->defaultView()))); >+ return EventDispatcher::dispatchEvent(this, KeyboardEventDispatchMediator::create(KeyboardEvent::create(event, document()->defaultView(), document()->monotonicTimeToZeroBasedDocumentTimeMilliseconds(event.timestamp())))); > } > > bool Node::dispatchMouseEvent(const PlatformMouseEvent& event, const AtomicString& eventType, > int detail, Node* relatedTarget) > { >- return EventDispatcher::dispatchEvent(this, MouseEventDispatchMediator::create(MouseEvent::create(eventType, document()->defaultView(), event, detail, relatedTarget))); >+ return EventDispatcher::dispatchEvent(this, MouseEventDispatchMediator::create(MouseEvent::create(eventType, document()->defaultView(), event, detail, relatedTarget, document()->monotonicTimeToZeroBasedDocumentTimeMilliseconds(event.timestamp())))); > } > > #if ENABLE(GESTURE_EVENTS) >@@ -2638,7 +2640,7 @@ bool Node::dispatchBeforeLoadEvent(const String& sourceURL) > > bool Node::dispatchWheelEvent(const PlatformWheelEvent& event) > { >- return EventDispatcher::dispatchEvent(this, WheelEventDispatchMediator::create(event, document()->defaultView())); >+ return EventDispatcher::dispatchEvent(this, WheelEventDispatchMediator::create(event, document()->defaultView(), document()->monotonicTimeToZeroBasedDocumentTimeMilliseconds(event.timestamp()))); > } > > void Node::dispatchFocusEvent(PassRefPtr<Node> oldFocusedNode) >diff --git a/Source/WebCore/dom/ScriptedAnimationController.cpp b/Source/WebCore/dom/ScriptedAnimationController.cpp >index 2f7862bdd4a149967062a0250e42cc30ef0b98d8..0b1f06048b321f61b8b8603cdb3dbb89ebb326ed 100644 >--- a/Source/WebCore/dom/ScriptedAnimationController.cpp >+++ b/Source/WebCore/dom/ScriptedAnimationController.cpp >@@ -113,7 +113,7 @@ void ScriptedAnimationController::serviceScriptedAnimations(double monotonicTime > if (!m_callbacks.size() || m_suspendCount || (m_document->settings() && !m_document->settings()->requestAnimationFrameEnabled())) > return; > >- double highResNowMs = 1000.0 * m_document->loader()->timing()->monotonicTimeToZeroBasedDocumentTime(monotonicTimeNow); >+ double highResNowMs = m_document->monotonicTimeToZeroBasedDocumentTimeMilliseconds(monotonicTimeNow); > > // First, generate a list of callbacks to consider. Callbacks registered from this point > // on are considered only for the "next" frame, not this one. >diff --git a/Source/WebCore/dom/TouchEvent.cpp b/Source/WebCore/dom/TouchEvent.cpp >index a58f1dcc9e238ebea462cfa5b659476e1b6036b3..49fc947fbec077bc1d62ce755a529bb954c69b54 100644 >--- a/Source/WebCore/dom/TouchEvent.cpp >+++ b/Source/WebCore/dom/TouchEvent.cpp >@@ -42,13 +42,15 @@ TouchEvent::TouchEvent() > TouchEvent::TouchEvent(TouchList* touches, TouchList* targetTouches, > TouchList* changedTouches, const AtomicString& type, > PassRefPtr<AbstractView> view, int screenX, int screenY, int pageX, int pageY, >- bool ctrlKey, bool altKey, bool shiftKey, bool metaKey) >+ bool ctrlKey, bool altKey, bool shiftKey, bool metaKey, >+ double systemTime) > : MouseRelatedEvent(type, true, true, view, 0, IntPoint(screenX, screenY), > IntPoint(pageX, pageY), > #if ENABLE(POINTER_LOCK) > IntPoint(0, 0), > #endif >- ctrlKey, altKey, shiftKey, metaKey) >+ ctrlKey, altKey, shiftKey, metaKey, false, >+ systemTime) > , m_touches(touches) > , m_targetTouches(targetTouches) > , m_changedTouches(changedTouches) >@@ -86,7 +88,6 @@ void TouchEvent::initTouchEvent(TouchList* touches, TouchList* targetTouches, > m_doubleTap = false; > m_touchHold = false; > #endif >- > } > > const AtomicString& TouchEvent::interfaceName() const >diff --git a/Source/WebCore/dom/TouchEvent.h b/Source/WebCore/dom/TouchEvent.h >index b2e5b2ee346bd800752db19d6e82814503c84c77..ee45584ad0644a14ec7a2d800e3f4172b526785a 100644 >--- a/Source/WebCore/dom/TouchEvent.h >+++ b/Source/WebCore/dom/TouchEvent.h >@@ -47,11 +47,12 @@ public: > TouchList* targetTouches, TouchList* changedTouches, > const AtomicString& type, PassRefPtr<AbstractView> view, > int screenX, int screenY, int pageX, int pageY, >- bool ctrlKey, bool altKey, bool shiftKey, bool metaKey) >+ bool ctrlKey, bool altKey, bool shiftKey, bool metaKey, >+ double systemTime) > { > return adoptRef(new TouchEvent(touches, targetTouches, changedTouches, > type, view, screenX, screenY, pageX, pageY, >- ctrlKey, altKey, shiftKey, metaKey)); >+ ctrlKey, altKey, shiftKey, metaKey, systemTime)); > } > > void initTouchEvent(TouchList* touches, TouchList* targetTouches, >@@ -79,7 +80,8 @@ private: > TouchList* changedTouches, const AtomicString& type, > PassRefPtr<AbstractView>, int screenX, int screenY, int pageX, > int pageY, >- bool ctrlKey, bool altKey, bool shiftKey, bool metaKey); >+ bool ctrlKey, bool altKey, bool shiftKey, bool metaKey, >+ double systemTime); > > RefPtr<TouchList> m_touches; > RefPtr<TouchList> m_targetTouches; >diff --git a/Source/WebCore/dom/UIEvent.cpp b/Source/WebCore/dom/UIEvent.cpp >index 367372670ed8dd055497e8ada4449daefd423d43..02c7e549528f6be5b2bb2a0ccbd095dce6c0fcc7 100644 >--- a/Source/WebCore/dom/UIEvent.cpp >+++ b/Source/WebCore/dom/UIEvent.cpp >@@ -35,8 +35,8 @@ UIEvent::UIEvent() > { > } > >-UIEvent::UIEvent(const AtomicString& eventType, bool canBubbleArg, bool cancelableArg, PassRefPtr<AbstractView> viewArg, int detailArg) >- : Event(eventType, canBubbleArg, cancelableArg) >+UIEvent::UIEvent(const AtomicString& eventType, bool canBubbleArg, bool cancelableArg, PassRefPtr<AbstractView> viewArg, int detailArg, double systemTime) >+ : Event(eventType, canBubbleArg, cancelableArg, systemTime) > , m_view(viewArg) > , m_detail(detailArg) > { >diff --git a/Source/WebCore/dom/UIEvent.h b/Source/WebCore/dom/UIEvent.h >index 207eb7b04f6be638621abeba0c42ac85303e5aba..a2140e814bb9e965683fa6f547babd2adb073ffb 100644 >--- a/Source/WebCore/dom/UIEvent.h >+++ b/Source/WebCore/dom/UIEvent.h >@@ -65,7 +65,7 @@ namespace WebCore { > > protected: > UIEvent(); >- UIEvent(const AtomicString& type, bool canBubble, bool cancelable, PassRefPtr<AbstractView>, int detail); >+ UIEvent(const AtomicString& type, bool canBubble, bool cancelable, PassRefPtr<AbstractView>, int detail, double systemTime = 0); > > private: > RefPtr<AbstractView> m_view; >diff --git a/Source/WebCore/dom/UIEventWithKeyState.h b/Source/WebCore/dom/UIEventWithKeyState.h >index 414161a7d062afae7d6350d5ca1bde0cd54f29fd..2ea790d72ac52c2b4d75b7e8c35703b9b7121ca6 100644 >--- a/Source/WebCore/dom/UIEventWithKeyState.h >+++ b/Source/WebCore/dom/UIEventWithKeyState.h >@@ -44,9 +44,8 @@ namespace WebCore { > { > } > >- UIEventWithKeyState(const AtomicString& type, bool canBubble, bool cancelable, PassRefPtr<AbstractView> view, >- int detail, bool ctrlKey, bool altKey, bool shiftKey, bool metaKey) >- : UIEvent(type, canBubble, cancelable, view, detail) >+ UIEventWithKeyState(const AtomicString& type, bool canBubble, bool cancelable, PassRefPtr<AbstractView> view, int detail, bool ctrlKey, bool altKey, bool shiftKey, bool metaKey, double systemTime = 0) >+ : UIEvent(type, canBubble, cancelable, view, detail, systemTime) > , m_ctrlKey(ctrlKey) > , m_altKey(altKey) > , m_shiftKey(shiftKey) >diff --git a/Source/WebCore/dom/WheelEvent.cpp b/Source/WebCore/dom/WheelEvent.cpp >index e76c33ace9e6f6f053218ef41e2ff22d2beec918..fbe07b1caad4ac991a06719eff94309a429f62e8 100644 >--- a/Source/WebCore/dom/WheelEvent.cpp >+++ b/Source/WebCore/dom/WheelEvent.cpp >@@ -37,18 +37,13 @@ WheelEvent::WheelEvent() > { > } > >-WheelEvent::WheelEvent(const FloatPoint& wheelTicks, const FloatPoint& rawDelta, >- Granularity granularity, PassRefPtr<AbstractView> view, >- const IntPoint& screenLocation, const IntPoint& pageLocation, >- bool ctrlKey, bool altKey, bool shiftKey, bool metaKey, >- bool directionInvertedFromDevice) >+WheelEvent::WheelEvent(const FloatPoint& wheelTicks, const FloatPoint& rawDelta, Granularity granularity, PassRefPtr<AbstractView> view, const IntPoint& screenLocation, const IntPoint& pageLocation, bool ctrlKey, bool altKey, bool shiftKey, bool metaKey, bool directionInvertedFromDevice, double systemTime) > : MouseEvent(eventNames().mousewheelEvent, >- true, true, view, 0, screenLocation.x(), screenLocation.y(), >- pageLocation.x(), pageLocation.y(), >+ true, true, view, 0, screenLocation.x(), screenLocation.y(), pageLocation.x(), pageLocation.y(), > #if ENABLE(POINTER_LOCK) >- 0, 0, >+ 0, 0, > #endif >- ctrlKey, altKey, shiftKey, metaKey, 0, 0, 0, false) >+ ctrlKey, altKey, shiftKey, metaKey, 0, 0, 0, false, systemTime) > , m_wheelDelta(IntPoint(static_cast<int>(wheelTicks.x() * tickMultiplier), static_cast<int>(wheelTicks.y() * tickMultiplier))) > , m_rawDelta(roundedIntPoint(rawDelta)) > , m_granularity(granularity) >@@ -104,19 +99,19 @@ inline static WheelEvent::Granularity granularity(const PlatformWheelEvent& even > return event.granularity() == ScrollByPageWheelEvent ? WheelEvent::Page : WheelEvent::Pixel; > } > >-PassRefPtr<WheelEventDispatchMediator> WheelEventDispatchMediator::create(const PlatformWheelEvent& event, PassRefPtr<AbstractView> view) >+PassRefPtr<WheelEventDispatchMediator> WheelEventDispatchMediator::create(const PlatformWheelEvent& event, PassRefPtr<AbstractView> view, double systemTime) > { >- return adoptRef(new WheelEventDispatchMediator(event, view)); >+ return adoptRef(new WheelEventDispatchMediator(event, view, systemTime)); > } > >-WheelEventDispatchMediator::WheelEventDispatchMediator(const PlatformWheelEvent& event, PassRefPtr<AbstractView> view) >+WheelEventDispatchMediator::WheelEventDispatchMediator(const PlatformWheelEvent& event, PassRefPtr<AbstractView> view, double systemTime) > { > if (!(event.deltaX() || event.deltaY())) > return; > > setEvent(WheelEvent::create(FloatPoint(event.wheelTicksX(), event.wheelTicksY()), FloatPoint(event.deltaX(), event.deltaY()), > granularity(event), view, event.globalPosition(), event.position(), >- event.ctrlKey(), event.altKey(), event.shiftKey(), event.metaKey(), event.directionInvertedFromDevice())); >+ event.ctrlKey(), event.altKey(), event.shiftKey(), event.metaKey(), event.directionInvertedFromDevice(), systemTime)); > } > > WheelEvent* WheelEventDispatchMediator::event() const >diff --git a/Source/WebCore/dom/WheelEvent.h b/Source/WebCore/dom/WheelEvent.h >index 13576890d831c3e896f0be3f011375d9111fc8ce..0abd1a897ccc4fa0a1c0920ec2d691a4d0ca1db6 100644 >--- a/Source/WebCore/dom/WheelEvent.h >+++ b/Source/WebCore/dom/WheelEvent.h >@@ -41,13 +41,10 @@ namespace WebCore { > { > return adoptRef(new WheelEvent); > } >- static PassRefPtr<WheelEvent> create(const FloatPoint& wheelTicks, >- const FloatPoint& rawDelta, Granularity granularity, PassRefPtr<AbstractView> view, >- const IntPoint& screenLocation, const IntPoint& pageLocation, >- bool ctrlKey, bool altKey, bool shiftKey, bool metaKey, bool directionInvertedFromDevice) >+ static PassRefPtr<WheelEvent> create(const FloatPoint& wheelTicks, const FloatPoint& rawDelta, Granularity granularity, PassRefPtr<AbstractView> view, const IntPoint& screenLocation, const IntPoint& pageLocation, bool ctrlKey, bool altKey, bool shiftKey, bool metaKey, bool directionInvertedFromDevice, double systemTime) > { > return adoptRef(new WheelEvent(wheelTicks, rawDelta, granularity, view, >- screenLocation, pageLocation, ctrlKey, altKey, shiftKey, metaKey, directionInvertedFromDevice)); >+ screenLocation, pageLocation, ctrlKey, altKey, shiftKey, metaKey, directionInvertedFromDevice, systemTime)); > } > > void initWheelEvent(int rawDeltaX, int rawDeltaY, PassRefPtr<AbstractView>, >@@ -74,10 +71,7 @@ namespace WebCore { > > private: > WheelEvent(); >- WheelEvent(const FloatPoint& wheelTicks, const FloatPoint& rawDelta, >- Granularity, PassRefPtr<AbstractView>, >- const IntPoint& screenLocation, const IntPoint& pageLocation, >- bool ctrlKey, bool altKey, bool shiftKey, bool metaKey, bool directionInvertedFromDevice); >+ WheelEvent(const FloatPoint& wheelTicks, const FloatPoint& rawDelta, Granularity, PassRefPtr<AbstractView>, const IntPoint& screenLocation, const IntPoint& pageLocation, bool ctrlKey, bool altKey, bool shiftKey, bool metaKey, bool directionInvertedFromDevice, double systemTime); > > IntPoint m_wheelDelta; > IntPoint m_rawDelta; >@@ -87,9 +81,9 @@ namespace WebCore { > > class WheelEventDispatchMediator : public EventDispatchMediator { > public: >- static PassRefPtr<WheelEventDispatchMediator> create(const PlatformWheelEvent&, PassRefPtr<AbstractView>); >+ static PassRefPtr<WheelEventDispatchMediator> create(const PlatformWheelEvent&, PassRefPtr<AbstractView>, double systemTime = 0); > private: >- WheelEventDispatchMediator(const PlatformWheelEvent&, PassRefPtr<AbstractView>); >+ WheelEventDispatchMediator(const PlatformWheelEvent&, PassRefPtr<AbstractView>, double systemTime); > WheelEvent* event() const; > virtual bool dispatchEvent(EventDispatcher*) const; > }; >diff --git a/Source/WebCore/loader/DocumentLoadTiming.cpp b/Source/WebCore/loader/DocumentLoadTiming.cpp >index 4b22f723bf847223589ae5764f7fc8bab102dd36..7c9f165af4d6d7182ae14199924987e3d076cc47 100644 >--- a/Source/WebCore/loader/DocumentLoadTiming.cpp >+++ b/Source/WebCore/loader/DocumentLoadTiming.cpp >@@ -54,11 +54,11 @@ DocumentLoadTiming::DocumentLoadTiming() > { > } > >-double DocumentLoadTiming::monotonicTimeToZeroBasedDocumentTime(double monotonicTime) const >+double DocumentLoadTiming::monotonicTimeToZeroBasedDocumentTimeMilliseconds(double monotonicTime) const > { > if (!monotonicTime) > return 0.0; >- return monotonicTime - m_referenceMonotonicTime; >+ return (monotonicTime - m_referenceMonotonicTime) * 1000.0; > } > > double DocumentLoadTiming::monotonicTimeToPseudoWallTime(double monotonicTime) const >diff --git a/Source/WebCore/loader/DocumentLoadTiming.h b/Source/WebCore/loader/DocumentLoadTiming.h >index 64494330d506c87ef99124b2369b875e482f5e50..88e4d51874c5a1d58fdeed7610e83725dbcec399 100644 >--- a/Source/WebCore/loader/DocumentLoadTiming.h >+++ b/Source/WebCore/loader/DocumentLoadTiming.h >@@ -37,7 +37,7 @@ class DocumentLoadTiming { > public: > DocumentLoadTiming(); > >- double monotonicTimeToZeroBasedDocumentTime(double) const; >+ double monotonicTimeToZeroBasedDocumentTimeMilliseconds(double) const; > double monotonicTimeToPseudoWallTime(double) const; > > void markNavigationStart(); >diff --git a/Source/WebCore/page/EventHandler.cpp b/Source/WebCore/page/EventHandler.cpp >index ac50de5c65c2e7533cfb7b2802bd6f4a1af1d526..230faf9827e7e040001e07e31708716336d7d642 100644 >--- a/Source/WebCore/page/EventHandler.cpp >+++ b/Source/WebCore/page/EventHandler.cpp >@@ -37,6 +37,7 @@ > #include "CursorList.h" > #include "Document.h" > #include "DocumentEventQueue.h" >+#include "DocumentLoader.h" > #include "DragController.h" > #include "DragState.h" > #include "Editor.h" >@@ -2025,7 +2026,8 @@ bool EventHandler::dispatchDragEvent(const AtomicString& eventType, Node* dragTa > event.movementDelta().x(), event.movementDelta().y(), > #endif > event.ctrlKey(), event.altKey(), event.shiftKey(), event.metaKey(), >- 0, 0, clipboard); >+ 0, 0, clipboard, false, >+ m_frame->document()->monotonicTimeToZeroBasedDocumentTimeMilliseconds(event.timestamp())); > > ExceptionCode ec; > dragTarget->dispatchEvent(me.get(), ec); >@@ -3103,7 +3105,7 @@ bool EventHandler::keyEvent(const PlatformKeyboardEvent& initialKeyEvent) > PlatformKeyboardEvent keyDownEvent = initialKeyEvent; > if (keyDownEvent.type() != PlatformEvent::RawKeyDown) > keyDownEvent.disambiguateKeyDownEvent(PlatformEvent::RawKeyDown, backwardCompatibilityMode); >- RefPtr<KeyboardEvent> keydown = KeyboardEvent::create(keyDownEvent, m_frame->document()->defaultView()); >+ RefPtr<KeyboardEvent> keydown = KeyboardEvent::create(keyDownEvent, m_frame->document()->defaultView(), m_frame->document()->monotonicTimeToZeroBasedDocumentTimeMilliseconds(initialKeyEvent.timestamp())); > if (matchedAnAccessKey) > keydown->setDefaultPrevented(true); > keydown->setTarget(node); >@@ -3126,7 +3128,7 @@ bool EventHandler::keyEvent(const PlatformKeyboardEvent& initialKeyEvent) > > if (handledByInputMethod) { > keyDownEvent.setWindowsVirtualKeyCode(CompositionEventKeyCode); >- keydown = KeyboardEvent::create(keyDownEvent, m_frame->document()->defaultView()); >+ keydown = KeyboardEvent::create(keyDownEvent, m_frame->document()->defaultView(), m_frame->document()->monotonicTimeToZeroBasedDocumentTimeMilliseconds(initialKeyEvent.timestamp())); > keydown->setTarget(node); > keydown->setDefaultHandled(); > } >@@ -3150,7 +3152,7 @@ bool EventHandler::keyEvent(const PlatformKeyboardEvent& initialKeyEvent) > keyPressEvent.disambiguateKeyDownEvent(PlatformEvent::Char, backwardCompatibilityMode); > if (keyPressEvent.text().isEmpty()) > return keydownResult; >- RefPtr<KeyboardEvent> keypress = KeyboardEvent::create(keyPressEvent, m_frame->document()->defaultView()); >+ RefPtr<KeyboardEvent> keypress = KeyboardEvent::create(keyPressEvent, m_frame->document()->defaultView(), m_frame->document()->monotonicTimeToZeroBasedDocumentTimeMilliseconds(initialKeyEvent.timestamp())); > keypress->setTarget(node); > if (keydownResult) > keypress->setDefaultPrevented(true); >@@ -3901,10 +3903,11 @@ bool EventHandler::handleTouchEvent(const PlatformTouchEvent& event) > RefPtr<TouchList> targetTouches(isTouchCancelEvent ? emptyList : touchesByTarget.get(touchEventTarget)); > ASSERT(targetTouches); > >+ Document* doc = touchEventTarget->toNode()->document(); > RefPtr<TouchEvent> touchEvent = > TouchEvent::create(effectiveTouches.get(), targetTouches.get(), changedTouches[state].m_touches.get(), >- stateName, touchEventTarget->toNode()->document()->defaultView(), >- 0, 0, 0, 0, event.ctrlKey(), event.altKey(), event.shiftKey(), event.metaKey()); >+ stateName, doc->defaultView(), 0, 0, 0, 0, event.ctrlKey(), event.altKey(), event.shiftKey(), event.metaKey(), >+ doc->monotonicTimeToZeroBasedDocumentTimeMilliseconds(event.timestamp())); > ExceptionCode ec = 0; > touchEventTarget->dispatchEvent(touchEvent.get(), ec); > swallowedEvent = swallowedEvent || touchEvent->defaultPrevented() || touchEvent->defaultHandled(); >diff --git a/Source/WebCore/page/Performance.cpp b/Source/WebCore/page/Performance.cpp >index e6871b7b7d9d6016e27e5e6a815b0292b64c79d0..21d51e55d853547f5b312b3ded3b667b11bfddc4 100644 >--- a/Source/WebCore/page/Performance.cpp >+++ b/Source/WebCore/page/Performance.cpp >@@ -250,7 +250,7 @@ void Performance::webkitClearMeasures(const String& measureName) > > double Performance::now() const > { >- return 1000.0 * m_frame->document()->loader()->timing()->monotonicTimeToZeroBasedDocumentTime(monotonicallyIncreasingTime()); >+ return m_frame->document()->monotonicTimeToZeroBasedDocumentTimeMilliseconds(monotonicallyIncreasingTime()); > } > > } // namespace WebCore >diff --git a/Source/WebCore/page/PerformanceResourceTiming.cpp b/Source/WebCore/page/PerformanceResourceTiming.cpp >index df1dc76ec1d25ddc3c164131eace610439222d19..f323ecc9d8578c54b7c63f87aff1696e54aa6f7d 100644 >--- a/Source/WebCore/page/PerformanceResourceTiming.cpp >+++ b/Source/WebCore/page/PerformanceResourceTiming.cpp >@@ -47,7 +47,7 @@ namespace WebCore { > double monotonicTimeToDocumentMilliseconds(Document* document, double seconds) > { > ASSERT(seconds >= 0.0); >- return document->loader()->timing()->monotonicTimeToZeroBasedDocumentTime(seconds) * 1000.0; >+ return document->monotonicTimeToZeroBasedDocumentTimeMilliseconds(seconds); > } > > PerformanceResourceTiming::PerformanceResourceTiming(const AtomicString& initiatorType, const ResourceRequest& request, const ResourceResponse& response, double initiationTime, double finishTime, Document* requestingDocument) >diff --git a/Source/WebCore/testing/Internals.cpp b/Source/WebCore/testing/Internals.cpp >index ea794b77298234cc1673078e3d1fbf9e484eeadd..eefd3177e335d5bf37fed115454552c9804c7f42 100644 >--- a/Source/WebCore/testing/Internals.cpp >+++ b/Source/WebCore/testing/Internals.cpp >@@ -35,6 +35,8 @@ > #include "DOMStringList.h" > #include "DOMWindow.h" > #include "Document.h" >+#include "DocumentLoadTiming.h" >+#include "DocumentLoader.h" > #include "DocumentMarker.h" > #include "DocumentMarkerController.h" > #include "Element.h" >@@ -1525,6 +1527,24 @@ PassRefPtr<DOMStringList> Internals::getReferencedFilePaths() const > return stringList.release(); > } > >+double Internals::navigationStartTime(Document* document, ExceptionCode& ec) const >+{ >+ if (!document) { >+ ec = INVALID_ACCESS_ERR; >+ return 0; >+ } >+ return document->loader()->timing()->navigationStart(); >+} >+ >+void Internals::dispatchPlatformMouseEvent(Node* node, int x, int y, double platformTimeStamp, ExceptionCode& ec) >+{ >+ if (!node) { >+ ec = INVALID_ACCESS_ERR; >+ return; >+ } >+ node->dispatchMouseEvent(PlatformMouseEvent(IntPoint(x, y), IntPoint(x, y), WebCore::LeftButton, WebCore::PlatformEvent::MouseReleased, 1, false, false, false, false, platformTimeStamp), "click"); >+} >+ > void Internals::startTrackingRepaints(Document* document, ExceptionCode& ec) > { > if (!document || !document->view()) { >diff --git a/Source/WebCore/testing/Internals.h b/Source/WebCore/testing/Internals.h >index 68e65e4cb9d141b1d3a8cf618c4a89d00e5053b5..b6c98051411aea89e1d39604276d940ca667c3bb 100644 >--- a/Source/WebCore/testing/Internals.h >+++ b/Source/WebCore/testing/Internals.h >@@ -245,6 +245,10 @@ public: > > PassRefPtr<DOMStringList> getReferencedFilePaths() const; > >+ double navigationStartTime(Document*, ExceptionCode&) const; >+ >+ void dispatchPlatformMouseEvent(Node*, int x, int y, double platformTimeStamp, ExceptionCode&); >+ > void startTrackingRepaints(Document*, ExceptionCode&); > void stopTrackingRepaints(Document*, ExceptionCode&); > >diff --git a/Source/WebCore/testing/Internals.idl b/Source/WebCore/testing/Internals.idl >index 703bea3aaaad17b70b18d999237e563d5482e84f..3f3d3cd8ac47025213c109256257880b7858c05a 100644 >--- a/Source/WebCore/testing/Internals.idl >+++ b/Source/WebCore/testing/Internals.idl >@@ -210,6 +210,10 @@ > > DOMString[] getReferencedFilePaths(); > >+ double navigationStartTime(in Document document) raises (DOMException); >+ >+ void dispatchPlatformMouseEvent(in Node node, in long x, in long y, in double platformTimeStamp) raises (DOMException); >+ > // These functions both reset the tracked repaint rects. They are inteded to be used in the following order: > // startTrackingRepaints, repaintRectsAsText, stopTrackingRepaints. > void startTrackingRepaints(in Document document) raises (DOMException); >diff --git a/Source/WebKit/chromium/features.gypi b/Source/WebKit/chromium/features.gypi >index 4f43106d38751d4f7589dd72db3ce2e4f1d4ca1f..2739eb084b0ab5f79b3dcefc1ab5964893d4ddb0 100644 >--- a/Source/WebKit/chromium/features.gypi >+++ b/Source/WebKit/chromium/features.gypi >@@ -61,6 +61,7 @@ > 'ENABLE_DOWNLOAD_ATTRIBUTE=1', > 'ENABLE_DRAGGABLE_REGION=1', > 'ENABLE_ENCRYPTED_MEDIA=1', >+ 'ENABLE_EVENT_SYSTEM_TIME=1', > 'ENABLE_FILE_SYSTEM=1', > 'ENABLE_FILTERS=1', > 'ENABLE_FULLSCREEN_API=1', >diff --git a/Source/WebKit/chromium/public/WebRuntimeFeatures.h b/Source/WebKit/chromium/public/WebRuntimeFeatures.h >index 2f6ef1ce4ea094fd1bca4f128da34e52a50975ab..9d9987813ed6793a05d118a96790d27573415d88 100644 >--- a/Source/WebKit/chromium/public/WebRuntimeFeatures.h >+++ b/Source/WebKit/chromium/public/WebRuntimeFeatures.h >@@ -46,6 +46,9 @@ public: > WEBKIT_EXPORT static void enableDatabase(bool); > WEBKIT_EXPORT static bool isDatabaseEnabled(); > >+ WEBKIT_EXPORT static void enableEventSystemTime(bool); >+ WEBKIT_EXPORT static bool isEventSystemTimeEnabled(); >+ > WEBKIT_EXPORT static void enableLocalStorage(bool); > WEBKIT_EXPORT static bool isLocalStorageEnabled(); > >diff --git a/Source/WebKit/chromium/src/WebInputEventConversion.cpp b/Source/WebKit/chromium/src/WebInputEventConversion.cpp >index 5cf24d0c1aa37eea6f382b0b29103f7596b2e39e..fd2c23b1b38b7faebde2d1322437ba0135d1e623 100644 >--- a/Source/WebKit/chromium/src/WebInputEventConversion.cpp >+++ b/Source/WebKit/chromium/src/WebInputEventConversion.cpp >@@ -240,6 +240,7 @@ PlatformKeyboardEventBuilder::PlatformKeyboardEventBuilder(const WebKeyboardEven > m_nativeVirtualKeyCode = e.nativeKeyCode; > m_isKeypad = (e.modifiers & WebInputEvent::IsKeyPad); > m_isSystemKey = e.isSystemKey; >+ m_timestamp = e.timeStampSeconds; > > m_modifiers = 0; > if (e.modifiers & WebInputEvent::ShiftKey) >diff --git a/Source/WebKit/chromium/src/WebRuntimeFeatures.cpp b/Source/WebKit/chromium/src/WebRuntimeFeatures.cpp >index a195de29290800c0503f118b0b36371f0b2846c9..2edbbde6b21095137c28f372fa395d9a905b1279 100644 >--- a/Source/WebKit/chromium/src/WebRuntimeFeatures.cpp >+++ b/Source/WebKit/chromium/src/WebRuntimeFeatures.cpp >@@ -58,6 +58,22 @@ bool WebRuntimeFeatures::isDatabaseEnabled() > #endif > } > >+void WebRuntimeFeatures::enableEventSystemTime(bool enable) >+{ >+#if ENABLE(EVENT_SYSTEM_TIME) >+ RuntimeEnabledFeatures::setEventSystemTimeEnabled(enable); >+#endif >+} >+ >+bool WebRuntimeFeatures::isEventSystemTimeEnabled() >+{ >+#if ENABLE(EVENT_SYSTEM_TIME) >+ return RuntimeEnabledFeatures::eventSystemTimeEnabled(); >+#else >+ return false; >+#endif >+} >+ > // FIXME: Remove the ability to enable this feature at runtime. > void WebRuntimeFeatures::enableLocalStorage(bool enable) > { >diff --git a/Source/WebKit/mac/WebView/WebPDFView.mm b/Source/WebKit/mac/WebView/WebPDFView.mm >index 92a3f963fab0a2cf0315f069e618277d80ba189a..620707db231f3a1679215ef414f80b98ddf16034 100644 >--- a/Source/WebKit/mac/WebView/WebPDFView.mm >+++ b/Source/WebKit/mac/WebView/WebPDFView.mm >@@ -48,6 +48,7 @@ > #import "WebView.h" > #import "WebViewInternal.h" > #import <PDFKit/PDFKit.h> >+#import <WebCore/DocumentLoader.h> > #import <WebCore/EventNames.h> > #import <WebCore/FormState.h> > #import <WebCore/Frame.h> >@@ -943,6 +944,7 @@ static BOOL isFrameInRange(WebFrame *frame, DOMRange *range) > if (!URL) > return; > >+ Frame* frame = core([dataSource webFrame]); > NSWindow *window = [sender window]; > NSEvent *nsEvent = [window currentEvent]; > const int noButton = -1; >@@ -974,11 +976,10 @@ static BOOL isFrameInRange(WebFrame *frame, DOMRange *range) > [nsEvent modifierFlags] & NSAlternateKeyMask, > [nsEvent modifierFlags] & NSShiftKeyMask, > [nsEvent modifierFlags] & NSCommandKeyMask, >- button, 0, 0, true); >+ button, 0, 0, true, frame->document()->monotonicTimeToZeroBasedDocumentTimeMilliseconds([nsEvent timestamp])); > } > > // Call to the frame loader because this is where our security checks are made. >- Frame* frame = core([dataSource webFrame]); > frame->loader()->loadFrameRequest(FrameLoadRequest(frame->document()->securityOrigin(), ResourceRequest(URL)), false, false, event.get(), 0, MaybeSendReferrer); > } > >diff --git a/Source/WebKit2/WebProcess/WebPage/WebPage.cpp b/Source/WebKit2/WebProcess/WebPage/WebPage.cpp >index c91c73ed100d293a55dc1acac1d940d86390fe88..852be5d7416e852b040b1d614adf52275c357bfc 100644 >--- a/Source/WebKit2/WebProcess/WebPage/WebPage.cpp >+++ b/Source/WebKit2/WebProcess/WebPage/WebPage.cpp >@@ -871,7 +871,7 @@ void WebPage::linkClicked(const String& url, const WebMouseEvent& event) > > RefPtr<Event> coreEvent; > if (event.type() != WebEvent::NoType) >- coreEvent = MouseEvent::create(eventNames().clickEvent, frame->document()->defaultView(), platform(event), 0, 0); >+ coreEvent = MouseEvent::create(eventNames().clickEvent, frame->document()->defaultView(), platform(event), 0, 0, frame->document()->monotonicTimeToZeroBasedDocumentTimeMilliseconds(event.timestamp())); > > frame->loader()->loadFrameRequest(FrameLoadRequest(frame->document()->securityOrigin(), ResourceRequest(url)), > false, false, coreEvent.get(), 0, MaybeSendReferrer); >diff --git a/Source/WebKit2/win/WebKit2.def b/Source/WebKit2/win/WebKit2.def >index 8416b91019a976962cf9ffc038d6f88c527ce015..aa9faee297469a8485342f3e8a2db94722ec31dd 100644 >--- a/Source/WebKit2/win/WebKit2.def >+++ b/Source/WebKit2/win/WebKit2.def >@@ -175,6 +175,7 @@ EXPORTS > ?create@ShadowRoot@WebCore@@SA?AV?$PassRefPtr@VShadowRoot@WebCore@@@WTF@@PAVElement@2@AAH@Z > ?createWrapper@WebCore@@YA?AVJSValue@JSC@@PAVExecState@3@PAVJSDOMGlobalObject@1@PAVNode@1@@Z > ?deserialize@SerializedScriptValue@WebCore@@QAE?AVJSValue@JSC@@PAVExecState@4@PAVJSGlobalObject@4@PAV?$Vector@V?$RefPtr@VMessagePort@WebCore@@@WTF@@$00@WTF@@W4SerializationErrorMode@2@@Z >+ ?dispatchMouseEvent@Node@WebCore@@QAE_NABVPlatformMouseEvent@2@ABVAtomicString@WTF@@HPAV12@@Z > ?documentState@HistoryItem@WebCore@@QBEABV?$Vector@VString@WTF@@$0A@@WTF@@XZ > ?ensureSelectFeatureSetCollected@ElementShadow@WebCore@@QAEXXZ > ?equal@WTF@@YA_NPBVStringImpl@1@PBE@Z >@@ -204,6 +205,7 @@ EXPORTS > ?nextSibling@ComposedShadowTreeWalker@WebCore@@QAEXXZ > ?firstChild@ComposedShadowTreeWalker@WebCore@@QAEXXZ > ?lastChild@ComposedShadowTreeWalker@WebCore@@QAEXXZ >+ ?loader@Document@WebCore@@QBEPAVDocumentLoader@2@XZ > ?next@ComposedShadowTreeWalker@WebCore@@QAEXXZ > ?previous@ComposedShadowTreeWalker@WebCore@@QAEXXZ > ?number@String@WTF@@SA?AV12@_J@Z >diff --git a/Source/WebKit2/win/WebKit2CFLite.def b/Source/WebKit2/win/WebKit2CFLite.def >index 003fc8b6d24e7ae414c47e2e5a73fac90e7de57c..78903159cd74de669ef9c89e7ff6a765ab8710c2 100644 >--- a/Source/WebKit2/win/WebKit2CFLite.def >+++ b/Source/WebKit2/win/WebKit2CFLite.def >@@ -169,6 +169,7 @@ EXPORTS > ?create@ShadowRoot@WebCore@@SA?AV?$PassRefPtr@VShadowRoot@WebCore@@@WTF@@PAVElement@2@AAH@Z > ?createWrapper@WebCore@@YA?AVJSValue@JSC@@PAVExecState@3@PAVJSDOMGlobalObject@1@PAVNode@1@@Z > ?deserialize@SerializedScriptValue@WebCore@@QAE?AVJSValue@JSC@@PAVExecState@4@PAVJSGlobalObject@4@PAV?$Vector@V?$RefPtr@VMessagePort@WebCore@@@WTF@@$00@WTF@@W4SerializationErrorMode@2@@Z >+ ?dispatchMouseEvent@Node@WebCore@@QAE_NABVPlatformMouseEvent@2@ABVAtomicString@WTF@@HPAV12@@Z > ?documentState@HistoryItem@WebCore@@QBEABV?$Vector@VString@WTF@@$0A@@WTF@@XZ > ?ensureSelectFeatureSetCollected@ElementShadow@WebCore@@QAEXXZ > ?equal@WTF@@YA_NPBVStringImpl@1@PBE@Z >@@ -197,6 +198,7 @@ EXPORTS > ?nextSibling@ComposedShadowTreeWalker@WebCore@@QAEXXZ > ?firstChild@ComposedShadowTreeWalker@WebCore@@QAEXXZ > ?lastChild@ComposedShadowTreeWalker@WebCore@@QAEXXZ >+ ?loader@Document@WebCore@@QBEPAVDocumentLoader@2@XZ > ?next@ComposedShadowTreeWalker@WebCore@@QAEXXZ > ?previous@ComposedShadowTreeWalker@WebCore@@QAEXXZ > ?number@String@WTF@@SA?AV12@_J@Z >diff --git a/Source/autotools/symbols.filter b/Source/autotools/symbols.filter >index c18745c4629be9b67a8937b1f9211dea2e072a95..702294ee63bc33b7d2346bcce58feb115bb7d577 100644 >--- a/Source/autotools/symbols.filter >+++ b/Source/autotools/symbols.filter >@@ -40,6 +40,7 @@ _ZN7WebCore5Range6createEN3WTF10PassRefPtrINS_8DocumentEEENS2_INS_4NodeEEEiS6_i; > _ZN7WebCore5RangeD1Ev; > _ZN7WebCore8Document36updateLayoutIgnorePendingStylesheetsEv; > _ZN7WebCore8Document8iconURLsEv; >+_ZNK7WebCore8Document6loaderEv; > _ZN7WebCore9HTMLNames8inputTagE; > _ZN7WebCore9HTMLNames11textareaTagE; > _ZN7WebCore10JSDocument10putVirtualEPN3JSC9ExecStateERKNS1_10IdentifierENS1_7JSValueERNS1_15PutPropertySlotE; >@@ -82,6 +83,7 @@ _ZN7WebCore19InspectorController18disconnectFrontendEv; > _ZN7WebCore19InspectorController26setInspectorFrontendClientEN3WTF10PassOwnPtrINS_23InspectorFrontendClientEEE; > _ZN7WebCore19InspectorController39setResourcesDataSizeLimitsFromInternalsEii; > _ZN7WebCore20CachedResourceLoader31garbageCollectDocumentResourcesEv; >+_ZN7WebCore4Node18dispatchMouseEventERKNS_18PlatformMouseEventERKN3WTF12AtomicStringEiPS0_; > _ZN7WebCore20NodeRenderingContextC1EPNS_4NodeE; > _ZN7WebCore20NodeRenderingContextD1Ev; > _ZN7WebCore21InspectorConsoleAgent28consoleMessageArgumentCountsEv; >diff --git a/Tools/ChangeLog b/Tools/ChangeLog >index 6e659bb0466593873adc0caa37bd47370d652231..991e728e0a6edb94fd34c72c8fe54d1106db3157 100644 >--- a/Tools/ChangeLog >+++ b/Tools/ChangeLog >@@ -1,3 +1,18 @@ >+2012-11-22 Robert Flack <flackr@chromium.org> >+ >+ Add systemTime to DOM events >+ https://bugs.webkit.org/show_bug.cgi?id=94987 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Adds a systemTime property to DOM events which exposes the platform event >+ timestamp consistent with Performance.now() timestamps discussed on >+ http://lists.w3.org/Archives/Public/public-web-perf/2012Oct/0046.html and >+ http://lists.webkit.org/pipermail/webkit-dev/2012-October/022574.html >+ >+ * DumpRenderTree/chromium/WebPreferences.cpp: >+ (WebPreferences::applyTo): >+ > 2012-11-22 Balazs Kelemen <kbalazs@webkit.org> > > [Qt][WTR] TestController::platformRunUntil should not do busy waiting >diff --git a/Tools/DumpRenderTree/chromium/WebPreferences.cpp b/Tools/DumpRenderTree/chromium/WebPreferences.cpp >index e13939d32d45f6860098b1d95f57c0817079dafb..f787e6e84fba8a9232b4b5d75ac3b4a28fc0ab20 100644 >--- a/Tools/DumpRenderTree/chromium/WebPreferences.cpp >+++ b/Tools/DumpRenderTree/chromium/WebPreferences.cpp >@@ -31,6 +31,7 @@ > #include "config.h" > #include "WebPreferences.h" > >+#include "WebRuntimeFeatures.h" > #include "WebView.h" > > using namespace WebKit; >@@ -258,4 +259,8 @@ void WebPreferences::applyTo(WebView* webView) > settings->setVisualWordMovementEnabled(false); > settings->setPasswordEchoEnabled(false); > settings->setApplyDeviceScaleFactorInCompositor(true); >+ >+#if ENABLE(EVENT_SYSTEM_TIME) >+ WebRuntimeFeatures::enableEventSystemTime(true); >+#endif > } >diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog >index 77ff9ebc76d53f1512e596fa2896fe1ff62ef0a2..6b5b999e896e4d1db464999247de9711d4d3eb07 100644 >--- a/LayoutTests/ChangeLog >+++ b/LayoutTests/ChangeLog >@@ -1,3 +1,22 @@ >+2012-11-22 Robert Flack <flackr@chromium.org> >+ >+ Add systemTime to DOM events >+ https://bugs.webkit.org/show_bug.cgi?id=94987 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Adds a systemTime property to DOM events which exposes the platform event >+ timestamp consistent with Performance.now() timestamps discussed on >+ http://lists.w3.org/Archives/Public/public-web-perf/2012Oct/0046.html and >+ http://lists.webkit.org/pipermail/webkit-dev/2012-October/022574.html >+ >+ * platform/chromium-linux/fast/xmlhttprequest/xmlhttprequest-get-expected.txt: >+ * platform/chromium-win/fast/xmlhttprequest/xmlhttprequest-get-expected.txt: >+ * platform/chromium/fast/dom/event-systemTime-basic-expected.txt: Added. >+ * platform/chromium/fast/dom/event-systemTime-basic.html: Added. >+ * platform/chromium/fast/xmlhttprequest/xmlhttprequest-get-expected.txt: >+ * platform/chromium/http/tests/workers/worker-importScriptsOnError-expected.txt: >+ > 2012-11-22 Yury Semikhatsky <yurys@chromium.org> > > Chromium gardening. Rebaseline compositing tests >diff --git a/LayoutTests/platform/chromium-linux/fast/xmlhttprequest/xmlhttprequest-get-expected.txt b/LayoutTests/platform/chromium-linux/fast/xmlhttprequest/xmlhttprequest-get-expected.txt >index ca2175c49279d78d2ba3cbb0bc1d4042e5c4c0db..d3e6e0c30088ea2990c36e8e22e625249a14a757 100644 >--- a/LayoutTests/platform/chromium-linux/fast/xmlhttprequest/xmlhttprequest-get-expected.txt >+++ b/LayoutTests/platform/chromium-linux/fast/xmlhttprequest/xmlhttprequest-get-expected.txt >@@ -59,6 +59,7 @@ returnValue : 'true' > srcElement : '[object XMLHttpRequest]' > stopImmediatePropagation : 'function stopImmediatePropagation() { [native code] }' > stopPropagation : 'function stopPropagation() { [native code] }' >+systemTime : '0' > target : '[object XMLHttpRequest]' > total : '0' > totalSize : '0' >diff --git a/LayoutTests/platform/chromium-win/fast/xmlhttprequest/xmlhttprequest-get-expected.txt b/LayoutTests/platform/chromium-win/fast/xmlhttprequest/xmlhttprequest-get-expected.txt >index ca2175c49279d78d2ba3cbb0bc1d4042e5c4c0db..d3e6e0c30088ea2990c36e8e22e625249a14a757 100644 >--- a/LayoutTests/platform/chromium-win/fast/xmlhttprequest/xmlhttprequest-get-expected.txt >+++ b/LayoutTests/platform/chromium-win/fast/xmlhttprequest/xmlhttprequest-get-expected.txt >@@ -59,6 +59,7 @@ returnValue : 'true' > srcElement : '[object XMLHttpRequest]' > stopImmediatePropagation : 'function stopImmediatePropagation() { [native code] }' > stopPropagation : 'function stopPropagation() { [native code] }' >+systemTime : '0' > target : '[object XMLHttpRequest]' > total : '0' > totalSize : '0' >diff --git a/LayoutTests/platform/chromium/fast/dom/event-systemTime-basic-expected.txt b/LayoutTests/platform/chromium/fast/dom/event-systemTime-basic-expected.txt >new file mode 100644 >index 0000000000000000000000000000000000000000..3bd231677f146b582349ec67332d9a8f1ea99239 >--- /dev/null >+++ b/LayoutTests/platform/chromium/fast/dom/event-systemTime-basic-expected.txt >@@ -0,0 +1,8 @@ >+PASS successfullyParsed is true >+ >+TEST COMPLETE >+PASS navigationStartTime > 0 is true >+PASS clickEvent instanceof window.Event is true >+PASS clickEvent.systemTime !== undefined is true >+PASS clickEvent.systemTime is 1500 >+ >diff --git a/LayoutTests/platform/chromium/fast/dom/event-systemTime-basic.html b/LayoutTests/platform/chromium/fast/dom/event-systemTime-basic.html >new file mode 100644 >index 0000000000000000000000000000000000000000..a3f4bc4cf0c0f27fdf5905c60b79cc8e033f7157 >--- /dev/null >+++ b/LayoutTests/platform/chromium/fast/dom/event-systemTime-basic.html >@@ -0,0 +1,42 @@ >+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> >+<html> >+<head> >+<script src="../../../../fast/js/resources/js-test-pre.js"></script> >+<script> >+ >+var clickEvent; >+var navigationStartTime; >+var eventSystemTime = 1500; >+ >+function eventListener(e) >+{ >+ clickEvent = e; >+} >+ >+function runTest() >+{ >+ window.testRunner.dumpAsText(); >+ if (document.body.addEventListener) { >+ document.body.addEventListener("click", eventListener, false); >+ } else { >+ document.body.attachEvent("onclick", eventListener); >+ } >+ >+ navigationStartTime = window.internals.navigationStartTime(document); >+ shouldBeTrue("navigationStartTime > 0"); >+ >+ var eventTime = navigationStartTime + eventSystemTime / 1000; >+ window.internals.dispatchPlatformMouseEvent(document.body, 50, 50, eventTime); >+ >+ shouldBeTrue("clickEvent instanceof window.Event"); >+ shouldBeTrue("clickEvent.systemTime !== undefined"); >+ shouldBe("clickEvent.systemTime", String(eventSystemTime)); >+} >+ >+</script> >+</head> >+<body onload="runTest();"> >+<p id="debug"></p> >+<script src="../../../../fast/js/resources/js-test-post.js"></script> >+</body> >+</html> >diff --git a/LayoutTests/platform/chromium/fast/xmlhttprequest/xmlhttprequest-get-expected.txt b/LayoutTests/platform/chromium/fast/xmlhttprequest/xmlhttprequest-get-expected.txt >index ca2175c49279d78d2ba3cbb0bc1d4042e5c4c0db..d3e6e0c30088ea2990c36e8e22e625249a14a757 100644 >--- a/LayoutTests/platform/chromium/fast/xmlhttprequest/xmlhttprequest-get-expected.txt >+++ b/LayoutTests/platform/chromium/fast/xmlhttprequest/xmlhttprequest-get-expected.txt >@@ -59,6 +59,7 @@ returnValue : 'true' > srcElement : '[object XMLHttpRequest]' > stopImmediatePropagation : 'function stopImmediatePropagation() { [native code] }' > stopPropagation : 'function stopPropagation() { [native code] }' >+systemTime : '0' > target : '[object XMLHttpRequest]' > total : '0' > totalSize : '0' >diff --git a/LayoutTests/platform/chromium/http/tests/workers/worker-importScriptsOnError-expected.txt b/LayoutTests/platform/chromium/http/tests/workers/worker-importScriptsOnError-expected.txt >index 3a7d7491d1d421111fb28f23b95ff22639e7110b..ffa40fb579fb63634914a3f4810d5053bc996f07 100644 >--- a/LayoutTests/platform/chromium/http/tests/workers/worker-importScriptsOnError-expected.txt >+++ b/LayoutTests/platform/chromium/http/tests/workers/worker-importScriptsOnError-expected.txt >@@ -38,6 +38,7 @@ returnValue: true, > srcElement: [object Worker], > stopImmediatePropagation: function stopImmediatePropagation() { [native code] }, > stopPropagation: function stopPropagation() { [native code] }, >+systemTime: 0, > target: [object Worker], > type: error > >diff --git a/ChangeLog b/ChangeLog >index 814a8bc794e79f010c90dd6f8d5eb2bc6610bdcd..0bd70a5ddf010fd04418eb70ad5f741cab32ccb7 100644 >--- a/ChangeLog >+++ b/ChangeLog >@@ -1,3 +1,17 @@ >+2012-11-22 Robert Flack <flackr@chromium.org> >+ >+ Add systemTime to DOM events >+ https://bugs.webkit.org/show_bug.cgi?id=94987 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Adds a systemTime property to DOM events which exposes the platform event >+ timestamp consistent with Performance.now() timestamps discussed on >+ http://lists.w3.org/Archives/Public/public-web-perf/2012Oct/0046.html and >+ http://lists.webkit.org/pipermail/webkit-dev/2012-October/022574.html >+ >+ * Source/autotools/symbols.filter: >+ > 2012-11-21 Ryuan Choi <ryuan.choi@gmail.com> > > [EFL] Remove unnecessary definition, -DENABLE_SPELLCHECK=1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 94987
:
160531
|
160541
|
160547
|
168415
|
170536
|
170648
|
170658
|
170659
|
170750
|
170977
|
170978
|
173044
|
173346
|
173360
|
173424
|
173633
|
174436
|
174465
|
175697
| 175826