mirror of
https://github.com/slint-ui/slint.git
synced 2025-10-03 15:14:35 +00:00
MCI: small changes required to run an (empty) windows for the compiled printerdemo
This commit is contained in:
parent
3534f3bd4c
commit
a40885b39e
2 changed files with 8 additions and 5 deletions
|
@ -28,11 +28,13 @@ scoped-tls-hkt = "0.1"
|
||||||
smallvec = "1.7"
|
smallvec = "1.7"
|
||||||
once_cell = "1.5"
|
once_cell = "1.5"
|
||||||
derive_more = "0.99.5"
|
derive_more = "0.99.5"
|
||||||
winit = { version = "0.25", default-features = false, optional = true }
|
winit = { version = "0.25", default-features = false, optional = true, features = ["x11"] }
|
||||||
glutin = { version = "0.27", default-features = false, optional = true }
|
glutin = { version = "0.27", default-features = false, optional = true, features = ["x11"] }
|
||||||
femtovg = { version = "0.2.8", optional = true }
|
femtovg = { version = "0.2.8", optional = true }
|
||||||
embedded-graphics = "0.7.1"
|
embedded-graphics = "0.7.1"
|
||||||
embedded-graphics-simulator = { version = "0.3.0", optional = true, default-features = false }
|
embedded-graphics-simulator = { version = "0.3.0", optional = true, default-features = false }
|
||||||
|
|
||||||
[target.'cfg(target_os = "macos")'.dependencies]
|
[target.'cfg(target_os = "macos")'.dependencies]
|
||||||
cocoa = { version = "0.24.0" }
|
cocoa = { version = "0.24.0" }
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -55,7 +55,8 @@ impl sixtyfps_corelib::backend::Backend for Backend {
|
||||||
&'static self,
|
&'static self,
|
||||||
_data: &'static [u8],
|
_data: &'static [u8],
|
||||||
) -> Result<(), Box<dyn std::error::Error>> {
|
) -> Result<(), Box<dyn std::error::Error>> {
|
||||||
unimplemented!()
|
//TODO
|
||||||
|
Err("Not implemented".into())
|
||||||
}
|
}
|
||||||
|
|
||||||
fn register_font_from_path(
|
fn register_font_from_path(
|
||||||
|
@ -82,11 +83,11 @@ impl sixtyfps_corelib::backend::Backend for Backend {
|
||||||
let inner: &ImageInner = image.into();
|
let inner: &ImageInner = image.into();
|
||||||
match inner {
|
match inner {
|
||||||
ImageInner::None => Default::default(),
|
ImageInner::None => Default::default(),
|
||||||
ImageInner::AbsoluteFilePath(_) => todo!(),
|
ImageInner::AbsoluteFilePath(_) | ImageInner::EmbeddedData { .. } => unimplemented!(),
|
||||||
ImageInner::EmbeddedData { .. } => todo!(),
|
|
||||||
ImageInner::EmbeddedImage(buffer) => {
|
ImageInner::EmbeddedImage(buffer) => {
|
||||||
[buffer.width() as f32, buffer.height() as f32].into()
|
[buffer.width() as f32, buffer.height() as f32].into()
|
||||||
}
|
}
|
||||||
|
ImageInner::StaticTextures { size, .. } => size.cast(),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue