diff --git a/.github/workflows/benchmarks.yml b/.github/workflows/benchmarks.yml index 671e7fc03..934eba4d3 100644 --- a/.github/workflows/benchmarks.yml +++ b/.github/workflows/benchmarks.yml @@ -1,5 +1,5 @@ on: - push: + pull_request: paths: - 'crates/torin/**/*' - '.github/workflows/benchmarks.yml' @@ -14,5 +14,5 @@ jobs: - uses: boa-dev/criterion-compare-action@59f4d964c5f19d7f13d36f5c0944b18ce6652cb0 with: package: torin - branchName: feat/torin-benchmarks-TEST-COMPARE + branchName: ${{ github.base_ref }} token: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file diff --git a/book/src/setup.md b/book/src/setup.md index 483ead6ae..136373ce6 100644 --- a/book/src/setup.md +++ b/book/src/setup.md @@ -15,6 +15,13 @@ Install these packages: sudo apt install build-essential libssl-dev pkg-config cmake libgtk-3-dev libclang-dev ``` +#### Arch Linux + +Install these packages: +```sh +sudo pacman -S base-devel openssl cmake gtk3 clang +``` + Don't hesitate to contribute so other distros can be added here. ### MacOS diff --git a/crates/components/Cargo.toml b/crates/components/Cargo.toml index f75303dcb..8c6d2eeca 100644 --- a/crates/components/Cargo.toml +++ b/crates/components/Cargo.toml @@ -1,7 +1,7 @@ [package] name = "freya-components" description = "Components library desgined for Freya." -version = "0.1.4" +version = "0.1.5" edition = "2021" license = "MIT" authors = ["Marc Espín "] diff --git a/crates/core/src/layout.rs b/crates/core/src/layout.rs index 0f7b3ec95..9be7bbc19 100644 --- a/crates/core/src/layout.rs +++ b/crates/core/src/layout.rs @@ -13,17 +13,17 @@ pub fn process_layout( scale_factor: f32, ) -> (Layers, ViewportsCollection) { let rdom = fdom.rdom(); - let dom_adapter = DioxusDOMAdapter::new(rdom); + let mut dom_adapter = DioxusDOMAdapter::new_with_cache(rdom); let skia_measurer = SkiaMeasurer::new(rdom, font_collection); // Finds the best Node from where to start measuring - fdom.layout().find_best_root(&dom_adapter); + fdom.layout().find_best_root(&mut dom_adapter); let root_id = fdom.rdom().root_id(); // Measure the layout fdom.layout() - .measure(root_id, area, &mut Some(skia_measurer), &dom_adapter); + .measure(root_id, area, &mut Some(skia_measurer), &mut dom_adapter); // Create the layers let mut layers = Layers::default(); diff --git a/crates/core/src/viewports.rs b/crates/core/src/viewports.rs index 6bf5240d1..3417314b1 100644 --- a/crates/core/src/viewports.rs +++ b/crates/core/src/viewports.rs @@ -26,10 +26,11 @@ pub fn calculate_viewports( let node_areas = layout.get(*node_id); if let Some((node, node_areas)) = node.zip(node_areas) { - let style = node.get::