Changeset 97225 in webkit
- Timestamp:
- Oct 11, 2011 9:05:11 PM (13 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r97224 r97225 1 2011-10-11 Kentaro Hara <haraken@chromium.org> 2 3 Implement a WebKitTransitionEvent constructor for JSC 4 https://bugs.webkit.org/show_bug.cgi?id=69829 5 6 Reviewed by Adam Barth. 7 8 webkit-transition-event-constructor.html checks the behavior of the WebKitTransitionEvent constructor. 9 10 * fast/dom/constructed-objects-prototypes-expected.txt: 11 * fast/events/constructors/webkit-transition-event-constructor-expected.txt: Added. 12 * fast/events/constructors/webkit-transition-event-constructor.html: Added. 13 * platform/chromium/test_expectations.txt: Skipped webkit-transition-event-constructor.html, since V8 does not yet have the WebKitTransitionEvent constructor. 14 1 15 2011-10-11 Sameer Patil <mkrp87@motorola.com> 2 16 -
trunk/LayoutTests/fast/dom/constructed-objects-prototypes-expected.txt
r96179 r97225 36 36 PASS (new inner.WebKitAnimationEvent()).isInner is true 37 37 PASS (new inner.WebKitAnimationEvent()).constructor.isInner is true 38 PASS (new inner.WebKitTransitionEvent()).isInner is true 39 PASS (new inner.WebKitTransitionEvent()).constructor.isInner is true 38 40 PASS (new inner.WebKitCSSMatrix()).isInner is true 39 41 PASS (new inner.WebKitCSSMatrix()).constructor.isInner is true -
trunk/LayoutTests/platform/chromium/test_expectations.txt
r97209 r97225 83 83 // Tests for WebVTT parser for <track>. Feature is not yet functional. 84 84 BUGWK43668 SKIP : media/track/ = TIMEOUT 85 86 // This will soon be fixed after implementing a WebKitTransitionEvent constructor for V8. 87 BUGWK69829 : fast/events/constructors/webkit-transition-event-constructor.html = FAIL 85 88 86 89 // Tests for MediaSource API. Feature is not yet functional. -
trunk/Source/WebCore/ChangeLog
r97224 r97225 1 2011-10-11 Kentaro Hara <haraken@chromium.org> 2 3 Implement a WebKitTransitionEvent constructor for JSC 4 https://bugs.webkit.org/show_bug.cgi?id=69829 5 6 Reviewed by Adam Barth. 7 8 There is no spec for the WebKitTransitionEvent constructor 9 since it is WebKit-specific. However, judging from the current 10 IDL of initWebKitTransitionEvent(), the constructor IDL 11 should be as follows. 12 13 [Constructor(DOMString type, optional WebKitTransitionEventInit eventInitDict)] 14 interface WebKitTransitionEvent : Event { 15 ...; 16 } 17 18 dictionary WebKitTransitionEventInit : EventInit { 19 DOMString propertyName; 20 double elapsedTime; 21 } 22 23 Test: fast/events/constructors/webkit-transition-event-constructor.html 24 25 * bindings/generic/EventConstructors.h: Added a definition for the WebKitTransitionEvent constructor. 26 * bindings/js/JSEventConstructors.cpp: Added #includes for WebKitTransitionEvent. 27 * dom/WebKitTransitionEvent.cpp: 28 (WebCore::WebKitTransitionEventInit::WebKitTransitionEventInit): 29 (WebCore::WebKitTransitionEvent::WebKitTransitionEvent): 30 (WebCore::WebKitTransitionEvent::initWebKitTransitionEvent): 31 * dom/WebKitTransitionEvent.h: Added a definition for WebKitTransitionEventInit. 32 (WebCore::WebKitTransitionEvent::create): 33 (WebCore::WebKitTransitionEvent::isWebKitTransitionEvent): 34 * dom/WebKitTransitionEvent.idl: Makes WebKitTransitionEvent constructible. 35 1 36 2011-10-11 Sameer Patil <mkrp87@motorola.com> 2 37 -
trunk/Source/WebCore/bindings/generic/EventConstructors.h
r96179 r97225 111 111 DICTIONARY_END(MessageEvent) 112 112 113 #define INSTANTIATE_INITIALIZING_CONSTRUCTOR_FOR_WEBKIT_TRANSITION_EVENT(DICTIONARY_START, DICTIONARY_END, FILL_PARENT_PROPERTIES, FILL_PROPERTY) \ 114 \ 115 DICTIONARY_START(WebKitTransitionEvent) \ 116 FILL_PARENT_PROPERTIES(Event) \ 117 FILL_PROPERTY(propertyName) \ 118 FILL_PROPERTY(elapsedTime) \ 119 DICTIONARY_END(WebKitTransitionEvent) 120 113 121 114 122 #define INSTANTIATE_ALL_EVENT_INITIALIZING_CONSTRUCTORS(DICTIONARY_START, DICTIONARY_END, FILL_PARENT_PROPERTIES, FILL_PROPERTY) \ … … 123 131 INSTANTIATE_INITIALIZING_CONSTRUCTOR_FOR_CLOSE_EVENT(DICTIONARY_START, DICTIONARY_END, FILL_PARENT_PROPERTIES, FILL_PROPERTY) \ 124 132 INSTANTIATE_INITIALIZING_CONSTRUCTOR_FOR_MESSAGE_EVENT(DICTIONARY_START, DICTIONARY_END, FILL_PARENT_PROPERTIES, FILL_PROPERTY) \ 133 INSTANTIATE_INITIALIZING_CONSTRUCTOR_FOR_WEBKIT_TRANSITION_EVENT(DICTIONARY_START, DICTIONARY_END, FILL_PARENT_PROPERTIES, FILL_PROPERTY) \ 125 134 126 135 } // namespace WebCore -
trunk/Source/WebCore/bindings/js/JSEventConstructors.cpp
r96179 r97225 43 43 #include "JSProgressEvent.h" 44 44 #include "JSWebKitAnimationEvent.h" 45 #include "JSWebKitTransitionEvent.h" 45 46 #include "MessageEvent.h" 46 47 #include "PageTransitionEvent.h" … … 48 49 #include "ProgressEvent.h" 49 50 #include "WebKitAnimationEvent.h" 51 #include "WebKitTransitionEvent.h" 50 52 #include <runtime/Error.h> 51 53 -
trunk/Source/WebCore/dom/WebKitTransitionEvent.cpp
r95901 r97225 30 30 31 31 namespace WebCore { 32 32 33 WebKitTransitionEventInit::WebKitTransitionEventInit() 34 : propertyName() 35 , elapsedTime(0) 36 { 37 } 38 33 39 WebKitTransitionEvent::WebKitTransitionEvent() 34 40 : m_propertyName() 35 , m_elapsedTime(0 .0)41 , m_elapsedTime(0) 36 42 { 37 43 } … … 41 47 , m_propertyName(propertyName) 42 48 , m_elapsedTime(elapsedTime) 49 { 50 } 51 52 WebKitTransitionEvent::WebKitTransitionEvent(const AtomicString& type, const WebKitTransitionEventInit& initializer) 53 : Event(type, initializer) 54 , m_propertyName(initializer.propertyName) 55 , m_elapsedTime(initializer.elapsedTime) 43 56 { 44 57 } … … 56 69 if (dispatched()) 57 70 return; 58 71 59 72 initEvent(type, canBubbleArg, cancelableArg); 60 73 61 74 m_propertyName = propertyName; 62 75 m_elapsedTime = elapsedTime; -
trunk/Source/WebCore/dom/WebKitTransitionEvent.h
r95901 r97225 30 30 31 31 namespace WebCore { 32 33 class WebKitTransitionEvent : public Event {34 public:35 static PassRefPtr<WebKitTransitionEvent> create()36 {37 return adoptRef(new WebKitTransitionEvent);38 }39 static PassRefPtr<WebKitTransitionEvent> create(const AtomicString& type, const String& animationName, double elapsedTime)40 {41 return adoptRef(new WebKitTransitionEvent(type, animationName, elapsedTime));42 }43 32 44 virtual ~WebKitTransitionEvent(); 45 46 void initWebKitTransitionEvent(const AtomicString& type, 47 bool canBubbleArg, 48 bool cancelableArg, 49 const String& propertyName, 50 double elapsedTime); 51 52 const String& propertyName() const; 53 double elapsedTime() const; 54 55 virtual bool isWebKitTransitionEvent() const { return true; } 56 57 private: 58 WebKitTransitionEvent(); 59 WebKitTransitionEvent(const AtomicString& type, const String& propertyName, double elapsedTime); 33 struct WebKitTransitionEventInit : public EventInit { 34 WebKitTransitionEventInit(); 60 35 61 String m_propertyName; 62 double m_elapsedTime; 63 }; 64 36 String propertyName; 37 double elapsedTime; 38 }; 39 40 class WebKitTransitionEvent : public Event { 41 public: 42 static PassRefPtr<WebKitTransitionEvent> create() 43 { 44 return adoptRef(new WebKitTransitionEvent); 45 } 46 static PassRefPtr<WebKitTransitionEvent> create(const AtomicString& type, const String& propertyName, double elapsedTime) 47 { 48 return adoptRef(new WebKitTransitionEvent(type, propertyName, elapsedTime)); 49 } 50 static PassRefPtr<WebKitTransitionEvent> create(const AtomicString& type, const WebKitTransitionEventInit& initializer) 51 { 52 return adoptRef(new WebKitTransitionEvent(type, initializer)); 53 } 54 55 virtual ~WebKitTransitionEvent(); 56 57 void initWebKitTransitionEvent(const AtomicString& type, 58 bool canBubbleArg, 59 bool cancelableArg, 60 const String& propertyName, 61 double elapsedTime); 62 63 const String& propertyName() const; 64 double elapsedTime() const; 65 66 virtual bool isWebKitTransitionEvent() const { return true; } 67 68 private: 69 WebKitTransitionEvent(); 70 WebKitTransitionEvent(const AtomicString& type, const String& propertyName, double elapsedTime); 71 WebKitTransitionEvent(const AtomicString& type, const WebKitTransitionEventInit& initializer); 72 73 String m_propertyName; 74 double m_elapsedTime; 75 }; 76 65 77 } // namespace WebCore 66 78 -
trunk/Source/WebCore/dom/WebKitTransitionEvent.idl
r91617 r97225 26 26 module events { 27 27 28 interface WebKitTransitionEvent : Event { 29 readonly attribute DOMString propertyName; 30 readonly attribute double elapsedTime; 31 void initWebKitTransitionEvent(in [Optional=CallWithDefaultValue] DOMString typeArg, 32 in [Optional=CallWithDefaultValue] boolean canBubbleArg, 33 in [Optional=CallWithDefaultValue] boolean cancelableArg, 34 in [Optional=CallWithDefaultValue] DOMString propertyNameArg, 35 in [Optional=CallWithDefaultValue] double elapsedTimeArg); 28 interface [ 29 CanBeConstructed, 30 JSCustomConstructor 31 ] WebKitTransitionEvent : Event { 32 readonly attribute DOMString propertyName; 33 readonly attribute double elapsedTime; 34 void initWebKitTransitionEvent(in [Optional=CallWithDefaultValue] DOMString typeArg, 35 in [Optional=CallWithDefaultValue] boolean canBubbleArg, 36 in [Optional=CallWithDefaultValue] boolean cancelableArg, 37 in [Optional=CallWithDefaultValue] DOMString propertyNameArg, 38 in [Optional=CallWithDefaultValue] double elapsedTimeArg); 36 39 }; 37 40
Note: See TracChangeset
for help on using the changeset viewer.