pub(crate) type ProgressEventInit = ProgressEventInit;
Aliased Type§
struct ProgressEventInit {
pub parent: EventInit,
pub lengthComputable: bool,
pub loaded: Finite<f64>,
pub total: Finite<f64>,
}
Fields§
§parent: EventInit
§lengthComputable: bool
§loaded: Finite<f64>
§total: Finite<f64>
Implementations
Source§impl ProgressEventInit
impl ProgressEventInit
pub unsafe fn to_jsobject( &self, cx: *mut JSContext, obj: MutableHandle<'_, *mut JSObject>, )
Source§impl ProgressEventInit
impl ProgressEventInit
pub fn empty() -> ProgressEventInit
pub fn new( cx: JSContext, val: Handle<'_, Value>, ) -> Result<ConversionResult<ProgressEventInit>, ()>
Trait Implementations
Source§impl Default for ProgressEventInit
impl Default for ProgressEventInit
Source§fn default() -> ProgressEventInit
fn default() -> ProgressEventInit
Returns the “default value” for a type. Read more
Source§impl FromJSValConvertible for ProgressEventInit
impl FromJSValConvertible for ProgressEventInit
Source§unsafe fn from_jsval(
cx: *mut JSContext,
value: Handle<'_, Value>,
_option: (),
) -> Result<ConversionResult<ProgressEventInit>, ()>
unsafe fn from_jsval( cx: *mut JSContext, value: Handle<'_, Value>, _option: (), ) -> Result<ConversionResult<ProgressEventInit>, ()>
Convert
val
to type Self
.
Optional configuration of type T
can be passed as the option
argument.
If it returns Err(())
, a JSAPI exception is pending.
If it returns Ok(Failure(reason))
, there is no pending JSAPI exception.