m: Cache document in web frontend (#66)
This commit is contained in:
parent
125ad070c2
commit
33a4c3741b
2 changed files with 27 additions and 11 deletions
|
|
@ -93,7 +93,7 @@ make_dispatch! {
|
|||
#[cfg(target_os = "macos")]
|
||||
CG((), cg::CGImpl),
|
||||
#[cfg(target_arch = "wasm32")]
|
||||
Web((), web::WebImpl),
|
||||
Web(web::WebDisplayImpl, web::WebImpl),
|
||||
#[cfg(target_os = "redox")]
|
||||
Orbital((), orbital::OrbitalImpl),
|
||||
}
|
||||
|
|
@ -134,7 +134,7 @@ impl Context {
|
|||
#[cfg(target_os = "macos")]
|
||||
RawDisplayHandle::AppKit(_) => ContextDispatch::CG(()),
|
||||
#[cfg(target_arch = "wasm32")]
|
||||
RawDisplayHandle::Web(_) => ContextDispatch::Web(()),
|
||||
RawDisplayHandle::Web(_) => ContextDispatch::Web(web::WebDisplayImpl::new()?),
|
||||
#[cfg(target_os = "redox")]
|
||||
RawDisplayHandle::Orbital(_) => ContextDispatch::Orbital(()),
|
||||
unimplemented_display_handle => {
|
||||
|
|
@ -212,8 +212,8 @@ impl Surface {
|
|||
SurfaceDispatch::CG(unsafe { cg::CGImpl::new(appkit_handle)? })
|
||||
}
|
||||
#[cfg(target_arch = "wasm32")]
|
||||
(ContextDispatch::Web(()), RawWindowHandle::Web(web_handle)) => {
|
||||
SurfaceDispatch::Web(web::WebImpl::new(web_handle)?)
|
||||
(ContextDispatch::Web(context), RawWindowHandle::Web(web_handle)) => {
|
||||
SurfaceDispatch::Web(web::WebImpl::new(context, web_handle)?)
|
||||
}
|
||||
#[cfg(target_os = "redox")]
|
||||
(ContextDispatch::Orbital(()), RawWindowHandle::Orbital(orbital_handle)) => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue