Bug 47812

Summary: V8 binding for DOMSettableTokenList
Product: WebKit Reporter: Kenichi Ishibashi <bashi>
Component: DOMAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: arv, commit-queue, tkent
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: PC   
OS: OS X 10.5   
Bug Depends on:    
Bug Blocks: 29363    
Attachments:
Description Flags
Patch V0 none

Kenichi Ishibashi
Reported 2010-10-18 04:28:36 PDT
Implement V8 binding for DOMSettableTokenList. This issue is a part of implementing the <output> element. See https://bugs.webkit.org/show_bug.cgi?id=29363 for more details.
Attachments
Patch V0 (1.62 KB, patch)
2010-10-31 17:46 PDT, Kenichi Ishibashi
no flags
Kenichi Ishibashi
Comment 1 2010-10-31 17:46:53 PDT
Created attachment 72479 [details] Patch V0
WebKit Commit Bot
Comment 2 2010-10-31 19:54:42 PDT
Comment on attachment 72479 [details] Patch V0 Clearing flags on attachment: 72479 Committed r71007: <http://trac.webkit.org/changeset/71007>
WebKit Commit Bot
Comment 3 2010-10-31 19:54:47 PDT
All reviewed patches have been landed. Closing bug.
Erik Arvidsson
Comment 4 2010-11-01 11:12:38 PDT
Comment on attachment 72479 [details] Patch V0 View in context: https://bugs.webkit.org/attachment.cgi?id=72479&action=review Also, why do we need custom indexedPropertyGetter? It wasn't needed for classList. The codegen knows how to generate this. > WebCore/bindings/v8/custom/V8DOMSettableTokenListCustom.cpp:39 > + return v8String(list->item(index)); This does not look right since we should return null when index is out of bounds. ([ConvertNullStringTo=Null] in the idl)
Kenichi Ishibashi
Comment 5 2010-11-02 00:42:18 PDT
Hi Erik, Thank you for your comment. (In reply to comment #4) > Also, why do we need custom indexedPropertyGetter? It wasn't needed for classList. The codegen knows how to generate this. It looks like that the codegen for V8 bindings does not consider the inheritance of the interface and doesn't generate indexedPropertyGetter automatically. On the other hand, the codegen for JSC consider the inheritance of the interface and generate getter function automatically. To manage these two case, we need to custom function. > > WebCore/bindings/v8/custom/V8DOMSettableTokenListCustom.cpp:39 > > + return v8String(list->item(index)); > > This does not look right since we should return null when index is out of bounds. ([ConvertNullStringTo=Null] in the idl) Yes, I've made a mistake and I'll fix it in the patch for https://bugs.webkit.org/show_bug.cgi?id=29363. Thank you for correcting.
Note You need to log in before you can comment on or make changes to this bug.