Changes between Version 144 and Version 145 of WebKitIDL
- Timestamp:
- Feb 24, 2016 6:37:21 PM (7 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
WebKitIDL
v144 v145 74 74 const unsigned short ELEMENT_NODE = 1; 75 75 attribute Node parentNode; 76 [TreatReturnedNullStringAs=Null] attribute DOMStringnodeName;76 attribute DOMString? nodeName; 77 77 [Custom] Node appendChild([CustomReturn] Node newChild); 78 78 void addEventListener(DOMString type, EventListener listener, optional boolean useCapture); … … 88 88 * appendChild(...) and addEventListener(...) are '''method'''s of the Node interface. 89 89 * type, listener and useCapture are '''parameter'''s of the Node interface. 90 * `[CustomToJSObject]`, `[ TreatReturnedNullStringAs=Null]`, `[Custom]` and `[CustomReturn]` are '''IDL attribute'''s.90 * `[CustomToJSObject]`, `[Custom]` and `[CustomReturn]` are '''IDL attribute'''s. 91 91 92 92 Note: These terminologies are not aligned with the Web IDL spec. … … 261 261 Summary: `[TreatReturnedNullStringAs]` controls the behavior when a WebKit null string is returned from the WebCore implementation. 262 262 263 Usage: The possible usage is `[TreatReturnedNullStringAs= Null]` or `[TreatReturnedNullStringAs=Undefined]`.263 Usage: The possible usage is `[TreatReturnedNullStringAs=Undefined]`. 264 264 They can be specified on DOMString attributes or methods that return a DOMString value: 265 265 {{{ 266 [TreatReturnedNullStringAs= Null] attribute DOMString str;266 [TreatReturnedNullStringAs= Undefined] attribute DOMString str; 267 267 [TreatReturnedNullStringAs=Undefined] DOMString func(); 268 268 }}} 269 269 270 * `[TreatReturnedNullStringAs=Null]` indicates that if the returned DOMString is a WebKit null string, the returned value is treated as a JavaScript null.271 270 * `[TreatReturnedNullStringAs=Undefined]` indicates that if the returned DOMString is a WebKit null string, the returned value is treated as a JavaScript undefined. 272 271 273 272 Without `[TreatReturnedNullStringAs=...]`, if the returned DOMString is a WebKit null string, then the returned value is treated as a JavaScript empty string ''. 274 275 Note that what should be specified on `[TreatReturnedNullStringAs=...]` depends on the spec of each attribute or method.276 273 277 274 == `[Default]`(p) == #Default