| { |
| "dart.dom.html": { |
| "CanvasGradient": { |
| "comment": [ |
| "/**", |
| " * An opaque canvas object representing a gradient.", |
| " *", |
| " * Created by calling [createLinearGradient] or [createRadialGradient] on a", |
| " * [CanvasRenderingContext2D] object.", |
| " *", |
| " * Example usage:", |
| " *", |
| " * var canvas = new CanvasElement(width: 600, height: 600);", |
| " * var ctx = canvas.context2D;", |
| " * ctx.clearRect(0, 0, 600, 600);", |
| " * ctx.save();", |
| " * // Create radial gradient.", |
| " * CanvasGradient gradient = ctx.createRadialGradient(0, 0, 0, 0, 0, 600);", |
| " * gradient.addColorStop(0, '#000');", |
| " * gradient.addColorStop(1, 'rgb(255, 255, 255)');", |
| " * // Assign gradients to fill.", |
| " * ctx.fillStyle = gradient;", |
| " * // Draw a rectangle with a gradient fill.", |
| " * ctx.fillRect(0, 0, 600, 600);", |
| " * ctx.save();", |
| " * document.body.children.add(canvas);", |
| " *", |
| " * See also:", |
| " *", |
| " * * [CanvasGradient](https://developer.mozilla.org/en-US/docs/DOM/CanvasGradient) from MDN.", |
| " * * [CanvasGradient](http://www.whatwg.org/specs/web-apps/current-work/multipage/the-canvas-element.html#canvasgradient) from whatwg.", |
| " * * [CanvasGradient](http://www.w3.org/TR/2010/WD-2dcontext-20100304/#canvasgradient) from W3C.", |
| " */" |
| ], |
| "members": { |
| "addColorStop": [ |
| "/**", |
| " * Adds a color stop to this gradient at the offset.", |
| " *", |
| " * The [offset] can range between 0.0 and 1.0.", |
| " *", |
| " * See also:", |
| " *", |
| " * * [Multiple Color Stops](https://developer.mozilla.org/en-US/docs/CSS/linear-gradient#Gradient_with_multiple_color_stops) from MDN.", |
| " */" |
| ] |
| } |
| }, |
| "CanvasPattern": { |
| "comment": [ |
| "/**", |
| " * An opaque object representing a pattern of image, canvas, or video.", |
| " *", |
| " * Created by calling [createPattern] on a [CanvasRenderingContext2D] object.", |
| " *", |
| " * Example usage:", |
| " *", |
| " * var canvas = new CanvasElement(width: 600, height: 600);", |
| " * var ctx = canvas.context2D;", |
| " * var img = new ImageElement();", |
| " * // Image src needs to be loaded before pattern is applied.", |
| " * img.onLoad.listen((event) {", |
| " * // When the image is loaded, create a pattern", |
| " * // from the ImageElement.", |
| " * CanvasPattern pattern = ctx.createPattern(img, 'repeat');", |
| " * ctx.rect(0, 0, canvas.width, canvas.height);", |
| " * ctx.fillStyle = pattern;", |
| " * ctx.fill();", |
| " * });", |
| " * img.src = \"images/foo.jpg\";", |
| " * document.body.children.add(canvas);", |
| " *", |
| " * See also:", |
| " * * [CanvasPattern](https://developer.mozilla.org/en-US/docs/DOM/CanvasPattern) from MDN.", |
| " * * [CanvasPattern](http://www.whatwg.org/specs/web-apps/current-work/multipage/the-canvas-element.html#canvaspattern) from whatwg.", |
| " * * [CanvasPattern](http://www.w3.org/TR/2010/WD-2dcontext-20100304/#canvaspattern) from W3C.", |
| " */" |
| ] |
| }, |
| "CanvasRenderingContext": { |
| "comment": [ |
| "/**", |
| " * A rendering context for a canvas element.", |
| " *", |
| " * This context is extended by [CanvasRenderingContext2D] and", |
| " * [WebGLRenderingContext].", |
| " */" |
| ], |
| "members": { |
| "canvas": [ |
| "/// Reference to the canvas element to which this context belongs." |
| ] |
| } |
| }, |
| "Clipboard": { |
| "members": { |
| "getData": [ |
| "/**", |
| " * Gets the data for the specified type.", |
| " *", |
| " * The data is only available from within a drop operation (such as an", |
| " * [Element.onDrop] event) and will return `null` before the event is", |
| " * triggered.", |
| " *", |
| " * Data transfer is prohibited across domains. If a drag originates", |
| " * from content from another domain or protocol (HTTP vs HTTPS) then the", |
| " * data cannot be accessed.", |
| " *", |
| " * The [type] can have values such as:", |
| " *", |
| " * * `'Text'`", |
| " * * `'URL'`", |
| " */" |
| ] |
| } |
| }, |
| "Document": { |
| "members": { |
| "body": [ |
| "/// Moved to [HtmlDocument]." |
| ], |
| "caretRangeFromPoint": [ |
| "/// Use the [Range] constructor instead." |
| ], |
| "createElement": [ |
| "/// Deprecated: use new Element.tag(tagName) instead." |
| ], |
| "createTouchList": [ |
| "/// Use the [TouchList] constructor instead." |
| ], |
| "getCSSCanvasContext": [ |
| "/// Moved to [HtmlDocument]." |
| ], |
| "head": [ |
| "/// Moved to [HtmlDocument]." |
| ], |
| "lastModified": [ |
| "/// Moved to [HtmlDocument]." |
| ], |
| "querySelector": [ |
| "/**", |
| " * Finds the first descendant element of this document that matches the", |
| " * specified group of selectors.", |
| " *", |
| " * Unless your webpage contains multiple documents, the top-level query", |
| " * method behaves the same as this method, so you should use it instead to", |
| " * save typing a few characters.", |
| " *", |
| " * [selectors] should be a string using CSS selector syntax.", |
| " * var element1 = document.query('.className');", |
| " * var element2 = document.query('#id');", |
| " *", |
| " * For details about CSS selector syntax, see the", |
| " * [CSS selector specification](http://www.w3.org/TR/css3-selectors/).", |
| " */" |
| ], |
| "querySelectorAll": [ |
| "/// Deprecated: use query(\"#$elementId\") instead." |
| ], |
| "referrer": [ |
| "/// Moved to [HtmlDocument]." |
| ], |
| "styleSheets": [ |
| "/// Moved to [HtmlDocument]" |
| ], |
| "title": [ |
| "/// Moved to [HtmlDocument]." |
| ], |
| "webkitCancelFullScreen": [ |
| "/// Moved to [HtmlDocument]." |
| ], |
| "webkitExitFullscreen": [ |
| "/// Moved to [HtmlDocument]." |
| ], |
| "webkitExitPointerLock": [ |
| "/// Moved to [HtmlDocument]." |
| ], |
| "webkitFullscreenElement": [ |
| "/// Moved to [HtmlDocument]." |
| ], |
| "webkitFullscreenEnabled": [ |
| "/// Moved to [HtmlDocument]." |
| ], |
| "webkitHidden": [ |
| "/// Moved to [HtmlDocument]." |
| ], |
| "webkitIsFullScreen": [ |
| "/// Moved to [HtmlDocument]." |
| ], |
| "webkitPointerLockElement": [ |
| "/// Moved to [HtmlDocument]." |
| ] |
| } |
| }, |
| "Element": { |
| "members": { |
| "querySelector": [ |
| "/**", |
| " * Finds the first descendant element of this element that matches the", |
| " * specified group of selectors.", |
| " *", |
| " * [selectors] should be a string using CSS selector syntax.", |
| " *", |
| " * // Gets the first descendant with the class 'classname'", |
| " * var element = element.query('.className');", |
| " * // Gets the element with id 'id'", |
| " * var element = element.query('#id');", |
| " * // Gets the first descendant [ImageElement]", |
| " * var img = element.query('img');", |
| " *", |
| " * See also:", |
| " *", |
| " * * [CSS Selectors](http://docs.webplatform.org/wiki/css/selectors)", |
| " */" |
| ] |
| } |
| }, |
| "HTMLAreaElement": { |
| "comment": [ |
| "/**", |
| " * DOM Area Element, which links regions of an image map with a hyperlink.", |
| " *", |
| " * The element can also define an uninteractive region of the map.", |
| " *", |
| " * See also:", |
| " *", |
| " * * [<area>](https://developer.mozilla.org/en-US/docs/HTML/Element/area)", |
| " * on MDN.", |
| " */" |
| ] |
| }, |
| "HTMLCanvasElement": { |
| "members": { |
| "height": [ |
| "/// The height of this canvas element in CSS pixels." |
| ], |
| "toDataURL": [ |
| "/**", |
| " * Returns a data URI containing a representation of the image in the", |
| " * format specified by type (defaults to 'image/png').", |
| " *", |
| " * Data Uri format is as follow `data:[<MIME-type>][;charset=<encoding>][;base64],<data>`", |
| " *", |
| " * Optional parameter [quality] in the range of 0.0 and 1.0 can be used when requesting [type]", |
| " * 'image/jpeg' or 'image/webp'. If [quality] is not passed the default", |
| " * value is used. Note: the default value varies by browser.", |
| " *", |
| " * If the height or width of this canvas element is 0, then 'data:' is returned,", |
| " * representing no data.", |
| " *", |
| " * If the type requested is not 'image/png', and the returned value is", |
| " * 'data:image/png', then the requested type is not supported.", |
| " *", |
| " * Example usage:", |
| " *", |
| " * CanvasElement canvas = new CanvasElement();", |
| " * var ctx = canvas.context2D", |
| " * ..fillStyle = \"rgb(200,0,0)\"", |
| " * ..fillRect(10, 10, 55, 50);", |
| " * var dataUrl = canvas.toDataUrl(\"image/jpeg\", 0.95);", |
| " * // The Data Uri would look similar to", |
| " * // 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUA", |
| " * // AAAFCAYAAACNbyblAAAAHElEQVQI12P4//8/w38GIAXDIBKE0DHxgljNBAAO", |
| " * // 9TXL0Y4OHwAAAABJRU5ErkJggg=='", |
| " * //Create a new image element from the data URI.", |
| " * var img = new ImageElement();", |
| " * img.src = dataUrl;", |
| " * document.body.children.add(img);", |
| " *", |
| " * See also:", |
| " *", |
| " * * [Data URI Scheme](http://en.wikipedia.org/wiki/Data_URI_scheme) from Wikipedia.", |
| " *", |
| " * * [HTMLCanvasElement](https://developer.mozilla.org/en-US/docs/DOM/HTMLCanvasElement) from MDN.", |
| " *", |
| " * * [toDataUrl](http://dev.w3.org/html5/spec/the-canvas-element.html#dom-canvas-todataurl) from W3C.", |
| " */" |
| ], |
| "width": [ |
| "/// The width of this canvas element in CSS pixels." |
| ] |
| } |
| }, |
| "HTMLDivElement": { |
| "comment": [ |
| "/**", |
| " * Represents an HTML <div> element.", |
| " *", |
| " * The [DivElement] is a generic container for content and does not have any", |
| " * special significance. It is functionally similar to [SpanElement].", |
| " *", |
| " * The [DivElement] is a block-level element, as opposed to [SpanElement],", |
| " * which is an inline-level element.", |
| " *", |
| " * Example usage:", |
| " *", |
| " * DivElement div = new DivElement();", |
| " * div.text = 'Here's my new DivElem", |
| " * document.body.elements.add(elem);", |
| " *", |
| " * See also:", |
| " *", |
| " * * [HTML <div> element](http://www.w3.org/TR/html-markup/div.html) from W3C.", |
| " * * [Block-level element](http://www.w3.org/TR/CSS2/visuren.html#block-boxes) from W3C.", |
| " * * [Inline-level element](http://www.w3.org/TR/CSS2/visuren.html#inline-boxes) from W3C.", |
| " */" |
| ] |
| }, |
| "HTMLHRElement": { |
| "comment": [ |
| "/**", |
| " * An `<hr>` tag.", |
| " */" |
| ] |
| }, |
| "HTMLMenuElement": { |
| "comment": [ |
| "/**", |
| " * An HTML <menu> element.", |
| " *", |
| " * A <menu> element represents an unordered list of menu commands.", |
| " *", |
| " * See also:", |
| " *", |
| " * * [Menu Element](https://developer.mozilla.org/en-US/docs/HTML/Element/menu) from MDN.", |
| " * * [Menu Element](http://www.w3.org/TR/html5/the-menu-element.html#the-menu-element) from the W3C.", |
| " */" |
| ] |
| }, |
| "Node": { |
| "members": { |
| "appendChild": [ |
| "/**", |
| " * Adds a node to the end of the child [nodes] list of this node.", |
| " *", |
| " * If the node already exists in this document, it will be removed from its", |
| " * current parent node, then added to this node.", |
| " *", |
| " * This method is more efficient than `nodes.add`, and is the preferred", |
| " * way of appending a child node.", |
| " */" |
| ] |
| } |
| }, |
| "WebSocket": { |
| "comment": [ |
| "/**", |
| " * Use the WebSocket interface to connect to a WebSocket,", |
| " * and to send and receive data on that WebSocket.", |
| " *", |
| " * To use a WebSocket in your web app, first create a WebSocket object,", |
| " * passing the WebSocket URL as an argument to the constructor.", |
| " *", |
| " * var webSocket = new WebSocket('ws://127.0.0.1:1337/ws');", |
| " *", |
| " * To send data on the WebSocket, use the [send] method.", |
| " *", |
| " * if (webSocket != null && webSocket.readyState == WebSocket.OPEN) {", |
| " * webSocket.send(data);", |
| " * } else {", |
| " * print('WebSocket not connected, message $data not sent');", |
| " * }", |
| " *", |
| " * To receive data on the WebSocket, register a listener for message events.", |
| " *", |
| " * webSocket.onMessage.listen((MessageEvent e) {", |
| " * receivedData(e.data);", |
| " * });", |
| " *", |
| " * The message event handler receives a [MessageEvent] object", |
| " * as its sole argument.", |
| " * You can also define open, close, and error handlers,", |
| " * as specified by [WebSocketEvents].", |
| " *", |
| " * For more information, see the", |
| " * [WebSockets](http://www.dartlang.org/docs/library-tour/#html-websockets)", |
| " * section of the library tour and", |
| " * [Introducing WebSockets](http://www.html5rocks.com/en/tutorials/websockets/basics/),", |
| " * an HTML5Rocks.com tutorial.", |
| " */" |
| ], |
| "members": { |
| "send": [ |
| "/**", |
| " * Transmit data to the server over this connection.", |
| " *", |
| " * This method accepts data of type [Blob], [ByteBuffer], [String], or", |
| " * [TypedData]. Named variants [sendBlob], [sendByteBuffer], [sendString],", |
| " * or [sendTypedData], in constrast, only accept data of the specified type.", |
| " */" |
| ] |
| } |
| }, |
| "XMLHttpRequest": { |
| "members": { |
| "abort": [ |
| "/**", |
| " * Stop the current request.", |
| " *", |
| " * The request can only be stopped if readyState is `HEADERS_RECIEVED` or", |
| " * `LOADING`. If this method is not in the process of being sent, the method", |
| " * has no effect.", |
| " */" |
| ], |
| "getAllResponseHeaders": [ |
| "/**", |
| " * Retrieve all the response headers from a request.", |
| " *", |
| " * `null` if no headers have been received. For multipart requests,", |
| " * `getAllResponseHeaders` will return the response headers for the current", |
| " * part of the request.", |
| " *", |
| " * See also [HTTP response headers](http://en.wikipedia.org/wiki/List_of_HTTP_header_fields#Responses)", |
| " * for a list of common response headers.", |
| " */" |
| ], |
| "getResponseHeader": [ |
| "/**", |
| " * Return the response header named `header`, or `null` if not found.", |
| " *", |
| " * See also [HTTP response headers](http://en.wikipedia.org/wiki/List_of_HTTP_header_fields#Responses)", |
| " * for a list of common response headers.", |
| " */" |
| ], |
| "onabort": [ |
| "/**", |
| " * Event listeners to be notified when request has been aborted,", |
| " * generally due to calling `httpRequest.abort()`.", |
| " */" |
| ], |
| "onerror": [ |
| "/**", |
| " * Event listeners to be notified when a request has failed, such as when a", |
| " * cross-domain error occurred or the file wasn't found on the server.", |
| " */" |
| ], |
| "onload": [ |
| "/**", |
| " * Event listeners to be notified once the request has completed", |
| " * *successfully*.", |
| " */" |
| ], |
| "onloadend": [ |
| "/**", |
| " * Event listeners to be notified once the request has completed (on", |
| " * either success or failure).", |
| " */" |
| ], |
| "onloadstart": [ |
| "/**", |
| " * Event listeners to be notified when the request starts, once", |
| " * `httpRequest.send()` has been called.", |
| " */" |
| ], |
| "onprogress": [ |
| "/**", |
| " * Event listeners to be notified when data for the request", |
| " * is being sent or loaded.", |
| " *", |
| " * Progress events are fired every 50ms or for every byte transmitted,", |
| " * whichever is less frequent.", |
| " */" |
| ], |
| "onreadystatechange": [ |
| "/**", |
| " * Event listeners to be notified every time the [HttpRequest]", |
| " * object's `readyState` changes values.", |
| " */" |
| ], |
| "open": [ |
| "/**", |
| " * Specify the desired `url`, and `method` to use in making the request.", |
| " *", |
| " * By default the request is done asyncronously, with no user or password", |
| " * authentication information. If `async` is false, the request will be send", |
| " * synchronously.", |
| " *", |
| " * Calling `open` again on a currently active request is equivalent to", |
| " * calling `abort`.", |
| " */" |
| ], |
| "overrideMimeType": [ |
| "/**", |
| " * Specify a particular MIME type (such as `text/xml`) desired for the", |
| " * response.", |
| " *", |
| " * This value must be set before the request has been sent. See also the list", |
| " * of [common MIME types](http://en.wikipedia.org/wiki/Internet_media_type#List_of_common_media_types)", |
| " */" |
| ], |
| "readyState": [ |
| "/**", |
| " * Indicator of the current state of the request:", |
| " *", |
| " * <table>", |
| " * <tr>", |
| " * <td>Value</td>", |
| " * <td>State</td>", |
| " * <td>Meaning</td>", |
| " * </tr>", |
| " * <tr>", |
| " * <td>0</td>", |
| " * <td>unsent</td>", |
| " * <td><code>open()</code> has not yet been called</td>", |
| " * </tr>", |
| " * <tr>", |
| " * <td>1</td>", |
| " * <td>opened</td>", |
| " * <td><code>send()</code> has not yet been called</td>", |
| " * </tr>", |
| " * <tr>", |
| " * <td>2</td>", |
| " * <td>headers received</td>", |
| " * <td><code>sent()</code> has been called; response headers and <code>status</code> are available</td>", |
| " * </tr>", |
| " * <tr>", |
| " * <td>3</td> <td>loading</td> <td><code>responseText</code> holds some data</td>", |
| " * </tr>", |
| " * <tr>", |
| " * <td>4</td> <td>done</td> <td>request is complete</td>", |
| " * </tr>", |
| " * </table>", |
| " */" |
| ], |
| "response": [ |
| "/**", |
| " * The data received as a reponse from the request.", |
| " *", |
| " * The data could be in the", |
| " * form of a [String], [ByteBuffer], [Document], [Blob], or json (also a", |
| " * [String]). `null` indicates request failure.", |
| " */" |
| ], |
| "responseText": [ |
| "/**", |
| " * The response in string form or `null on failure.", |
| " */" |
| ], |
| "responseType": [ |
| "/**", |
| " * [String] telling the server the desired response format.", |
| " *", |
| " * Default is `String`.", |
| " * Other options are one of 'arraybuffer', 'blob', 'document', 'json',", |
| " * 'text'. Some newer browsers will throw NS_ERROR_DOM_INVALID_ACCESS_ERR if", |
| " * `responseType` is set while performing a synchronous request.", |
| " *", |
| " * See also: [MDN responseType](https://developer.mozilla.org/en-US/docs/DOM/XMLHttpRequest#responseType)", |
| " */" |
| ], |
| "responseXML": [ |
| "/**", |
| " * The request response, or null on failure.", |
| " *", |
| " * The response is processed as", |
| " * `text/xml` stream, unless responseType = 'document' and the request is", |
| " * synchronous.", |
| " */" |
| ], |
| "send": [ |
| "/**", |
| " * Send the request with any given `data`.", |
| " *", |
| " * See also:", |
| " *", |
| " * * [send](https://developer.mozilla.org/en-US/docs/DOM/XMLHttpRequest#send%28%29)", |
| " * from MDN.", |
| " */" |
| ], |
| "status": [ |
| "/**", |
| " * The http result code from the request (200, 404, etc).", |
| " * See also: [Http Status Codes](http://en.wikipedia.org/wiki/List_of_HTTP_status_codes)", |
| " */" |
| ], |
| "statusText": [ |
| "/**", |
| " * The request response string (such as \\\"200 OK\\\").", |
| " * See also: [Http Status Codes](http://en.wikipedia.org/wiki/List_of_HTTP_status_codes)", |
| " */" |
| ], |
| "upload": [ |
| "/**", |
| " * [EventTarget] that can hold listeners to track the progress of the request.", |
| " * The events fired will be members of [HttpRequestUploadEvents].", |
| " */" |
| ], |
| "withCredentials": [ |
| "/**", |
| " * True if cross-site requests should use credentials such as cookies", |
| " * or authorization headers; false otherwise.", |
| " *", |
| " * This value is ignored for same-site requests.", |
| " */" |
| ], |
| "XMLHttpRequest": [ |
| "/**", |
| " * General constructor for any type of request (GET, POST, etc).", |
| " *", |
| " * This call is used in conjunction with [open]:", |
| " *", |
| " * var request = new HttpRequest();", |
| " * request.open('GET', 'http://dartlang.org');", |
| " * request.onLoad.listen((event) => print(", |
| " * 'Request complete ${event.target.reponseText}'));", |
| " * request.send();", |
| " *", |
| " * is the (more verbose) equivalent of", |
| " *", |
| " * HttpRequest.getString('http://dartlang.org').then(", |
| " * (result) => print('Request complete: $result'));", |
| " */" |
| ] |
| } |
| } |
| }, |
| "dart.dom.web_sql": { |
| "Database": { |
| "members": { |
| "changeVersion": [ |
| "/**", |
| " * Atomically update the database version to [newVersion], asynchronously", |
| " * running [callback] on the [SqlTransaction] representing this", |
| " * [changeVersion] transaction.", |
| " *", |
| " * If [callback] runs successfully, then [successCallback] is called.", |
| " * Otherwise, [errorCallback] is called.", |
| " *", |
| " * [oldVersion] should match the database's current [version] exactly.", |
| " *", |
| " * * [Database.changeVersion](http://www.w3.org/TR/webdatabase/#dom-database-changeversion) from W3C.", |
| " */" |
| ] |
| } |
| } |
| } |
| } |