- From: Jian Li <jianli@chromium.org>
- Date: Thu, 8 Apr 2010 17:51:53 -0700
- To: Web Applications Working Group WG <public-webapps@w3.org>
- Message-ID: <z2oa95818c31004081751naa803fccm71e2f84fef8f183c@mail.gmail.com>
The spec says that loadend event should be dispatched before error event when an error occurs during file read: 2. If an error occurs during file read, set readyState to DONE and set result to null. Proceed to the error steps below. 1. Dispatch a progress event called loadend. 2. Dispatch a progress event called error. Set the error attribute; on getting, the error attribute MUST be a a FileError object with a valid error code that indicates the kind of file error that has occurred. 3. Terminate this overall set of steps. However, it is said that loadend event should be dispatched after load event when the file data has been completely read. When this specification says to make progress notifications for a read method, the following steps MUST be followed: 1. While the read method is processing, queue a task to dispatch a progress event called progress about every 50ms or for every byte read into memory, whichever is least frequent. 2. When the data from the file or fileBlob has been completely read into memory, queue a task to dispatch a progress event called load 3. When the data from the file or fileBlob has been completely read into memory, queue a task to dispatch a progress event called loadend The ordering of error/load and loadend event seem to be inconsistent. Could we move the dispatch of loadend event after error event?
Received on Friday, 9 April 2010 00:52:24 UTC