Skip to content
  • darin@apple.com's avatar
    Reviewed by Sam Weinig. · a309ff78
    darin@apple.com authored
            - fix http://bugs.webkit.org/show_bug.cgi?id=16332
              ObjC DOM exception object descriptions should include the exception name
    
            * WebCore.pro: Added ExceptionCode.cpp.
            * WebCore.vcproj/WebCore.vcproj: Added ExceptionCode.cpp.
            * WebCore.xcodeproj/project.pbxproj: Added ExceptionCode.cpp.
            * WebCoreSources.bkl: Added ExceptionCode.cpp.
    
            * bindings/js/kjs_binding.cpp: (KJS::setDOMException): Moved the code to decompose an
            ExceptionCode into ExceptionCode.h/cpp -- getExceptionCodeDescription. Also removed
            the many unneeded includes that were here. Had to keep one special case here, for
            SECURITY_ERR.
    
            * bindings/objc/ExceptionHandlers.mm: (WebCore::raiseDOMException): Changed to use the
            new getExceptionCodeDescription function so that this shares the exception name
            information that was previously only available to JavaScript.
    
            * dom/ExceptionCode.cpp: Copied from bindings/js/kjs_binding.cpp.
            (WebCore::getExceptionCodeDescription): Added some assertions, and made the function
            handle exception names in a slightly more robust way that is not subject to integer
            overflow. (Not a real world issue since we should never receive a bad exception code.)
    
            * dom/ExceptionCode.h: Added the ExceptionCodeDescription struct and the
            getExceptionCodeDescription function.
    
            * svg/SVGException.h: Added a missing #include and got rid of some comments. Some of
            the comments were mildly helpful, but others were incorrect. This now matches the other
            exception-related headers such as RangeException.h.
    
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@28509 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    a309ff78