Reviewed by Sam.
authorandersca@apple.com <andersca@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 15 Nov 2007 23:53:19 +0000 (23:53 +0000)
committerandersca@apple.com <andersca@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 15 Nov 2007 23:53:19 +0000 (23:53 +0000)
commit63614bf0fb48fad433ac8e09d4d5eb1ec499f641
tree795cf34743dc8d9718753330477932278a039dc0
parent59ee994b7825172b406616d3d6d5648f757cc041
    Reviewed by Sam.

        Make the VoidCallback DOM interface behave more like our other DOM interfaces.

        * bindings/js/JSCustomVoidCallback.h: Added.
        * bindings/js/JSCustomVoidCallback.cpp: Added.
        (WebCore::JSCustomVoidCallback::JSCustomVoidCallback):
        (WebCore::JSCustomVoidCallback::handleEvent):
        VoidCallback implementation that wraps a JS object.

        (WebCore::toVoidCallback):
        New method that creates a VoidCallback implementation given a JS object.

        * bindings/scripts/CodeGeneratorJS.pm:
        Specify that VoidCallback can fail conversion and add a custom conversion function.

        * html/HTMLMediaElement.cpp:
        (WebCore::HTMLMediaElement::movieCuePointReached):
        Call handleEvent on the callback.

        (WebCore::HTMLMediaElement::removeCuePoint):
        Comment out parts of this method, it has already been removed in the HTML5 spec and it relies
        on overriding VoidCallback equality.

        * html/VoidCallback.cpp: Removed.

        * html/VoidCallback.h:
        (WebCore::VoidCallback::VoidCallback):
        (WebCore::VoidCallback::~VoidCallback):
        Make this an abstract class with a pure virtual handleEvent method.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@27826 268f45cc-cd09-0410-ab3c-d52691b4dbfc
WebCore/ChangeLog
WebCore/WebCore.xcodeproj/project.pbxproj
WebCore/bindings/js/JSCustomVoidCallback.cpp [new file with mode: 0644]
WebCore/bindings/js/JSCustomVoidCallback.h [new file with mode: 0644]
WebCore/bindings/scripts/CodeGeneratorJS.pm
WebCore/html/HTMLMediaElement.cpp
WebCore/html/VoidCallback.cpp [deleted file]
WebCore/html/VoidCallback.h