Skip to content

Commit

Permalink
app-surface: fix wasm target
Browse files Browse the repository at this point in the history
  • Loading branch information
jinleili committed Oct 31, 2024
1 parent 01b6904 commit 118a070
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion app-surface/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name = "app-surface"
authors = ["jinleili"]
description = "Integrate wgpu into your existing iOS and Android apps."
edition = "2021"
version = "1.2.0"
version = "1.2.1"
rust-version = "1.76"
repository = "https://github.com/jinleili/wgpu-in-app"
keywords = ["android", "SurfaceView", "ios", "macos", "wgpu"]
Expand Down
4 changes: 2 additions & 2 deletions app-surface/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -111,8 +111,8 @@ impl SurfaceFrame for AppSurface {

#[cfg(target_arch = "wasm32")]
fn resize_surface_by_size(&mut self, size: (u32, u32)) {
self.sdq.config.width = size.0;
self.sdq.config.height = size.1;
self.ctx.config.width = size.0;
self.ctx.config.height = size.1;
self.surface.configure(&self.device, &self.config);
}

Expand Down

0 comments on commit 118a070

Please sign in to comment.