Rename rust API

This commit is contained in:
Tobias Hunger 2022-02-02 11:16:18 +01:00
parent 8d1c852e89
commit cc3994b58d
No known key found for this signature in database
GPG key ID: 60874021D2F23F91
128 changed files with 631 additions and 627 deletions

View file

@ -4,7 +4,7 @@
#[allow(dead_code)]
// ANCHOR: tiles
fn main() {
use sixtyfps::Model;
use slint::Model;
let main_window = MainWindow::new();
@ -19,13 +19,14 @@ fn main() {
tiles.shuffle(&mut rng);
// Assign the shuffled Vec to the model property
let tiles_model = std::rc::Rc::new(sixtyfps::VecModel::from(tiles));
let tiles_model = std::rc::Rc::new(slint::VecModel::from(tiles));
main_window.set_memory_tiles(tiles_model.into());
main_window.run();
}
// ANCHOR_END: tiles
sixtyfps::sixtyfps! {
slint::slint! {
struct TileData := {
image: image,
image_visible: bool,