Implement read methods on FileReaderSync

This commit is contained in:
Jonas Reinwald 2017-12-07 16:57:06 +01:00 committed by Josh Matthews
parent 3e8caa4679
commit 0fdafb08c8
9 changed files with 277 additions and 104 deletions

View file

@ -35,6 +35,7 @@ pub enum DOMErrorName {
TimeoutError = DOMExceptionConstants::TIMEOUT_ERR,
InvalidNodeTypeError = DOMExceptionConstants::INVALID_NODE_TYPE_ERR,
DataCloneError = DOMExceptionConstants::DATA_CLONE_ERR,
NotReadableError = DOMExceptionConstants::NOT_READABLE_ERR,
}
#[dom_struct]
@ -94,6 +95,7 @@ impl DOMExceptionMethods for DOMException {
DOMErrorName::InvalidNodeTypeError =>
"The supplied node is incorrect or has an incorrect ancestor for this operation.",
DOMErrorName::DataCloneError => "The object can not be cloned.",
DOMErrorName::NotReadableError => "The I/O read operation failed."
};
DOMString::from(message)