pub(crate) trait DataTransferMethods<D: DomTypes> {
// Required methods
fn DropEffect(&self) -> DOMString;
fn SetDropEffect(&self, value: DOMString);
fn EffectAllowed(&self) -> DOMString;
fn SetEffectAllowed(&self, value: DOMString);
fn Items(&self) -> DomRoot<D::DataTransferItemList>;
fn SetDragImage(&self, image: &D::Element, x: i32, y: i32);
fn Types(
&self,
cx: SafeJSContext,
_can_gc: CanGc,
retval: MutableHandleValue<'_>,
);
fn GetData(&self, format: DOMString) -> DOMString;
fn SetData(&self, format: DOMString, data: DOMString);
fn ClearData(&self, format: Option<DOMString>);
fn Files(&self, _can_gc: CanGc) -> DomRoot<D::FileList>;
fn Constructor(
global: &D::Window,
proto: Option<HandleObject<'_>>,
can_gc: CanGc,
) -> DomRoot<D::DataTransfer>;
}
Required Methods§
fn DropEffect(&self) -> DOMString
fn SetDropEffect(&self, value: DOMString)
fn EffectAllowed(&self) -> DOMString
fn SetEffectAllowed(&self, value: DOMString)
fn Items(&self) -> DomRoot<D::DataTransferItemList>
fn SetDragImage(&self, image: &D::Element, x: i32, y: i32)
fn Types( &self, cx: SafeJSContext, _can_gc: CanGc, retval: MutableHandleValue<'_>, )
fn GetData(&self, format: DOMString) -> DOMString
fn SetData(&self, format: DOMString, data: DOMString)
fn ClearData(&self, format: Option<DOMString>)
fn Files(&self, _can_gc: CanGc) -> DomRoot<D::FileList>
fn Constructor( global: &D::Window, proto: Option<HandleObject<'_>>, can_gc: CanGc, ) -> DomRoot<D::DataTransfer>
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.