diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index e0ba2ffb..43e1c02a 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -153,3 +153,24 @@ jobs: uses: Swatinem/rust-cache@v2 - run: cargo check --features wgpu --target aarch64-linux-android working-directory: crates/eframe + + windows: + name: Check Windows + runs-on: windows-latest + steps: + - uses: actions/checkout@v2 + - uses: actions-rs/toolchain@v1 + with: + profile: minimal + toolchain: 1.65.0 + override: true + + - name: Set up cargo cache + uses: Swatinem/rust-cache@v2 + + - name: Check + uses: actions-rs/cargo@v1 + with: + command: check + args: --all-targets --all-features + diff --git a/Cargo.toml b/Cargo.toml index 4de49458..fb2ce97c 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -27,7 +27,8 @@ opt-level = 2 # fast and small wasm, basically same as `opt-level = 's'` [profile.dev] -split-debuginfo = "unpacked" # faster debug builds on mac +# Can't leave this on by default, because it breaks the Windows build. Related: https://github.com/rust-lang/cargo/issues/4897 +# split-debuginfo = "unpacked" # faster debug builds on mac # opt-level = 1 # Make debug builds run faster # Optimize all dependencies even in debug builds (does not affect workspace packages): diff --git a/crates/eframe/src/native/epi_integration.rs b/crates/eframe/src/native/epi_integration.rs index 0e775acb..0cc384ad 100644 --- a/crates/eframe/src/native/epi_integration.rs +++ b/crates/eframe/src/native/epi_integration.rs @@ -172,7 +172,7 @@ fn window_builder_drag_and_drop( enable: bool, ) -> winit::window::WindowBuilder { use winit::platform::windows::WindowBuilderExtWindows as _; - build_window.with_drag_and_drop(enable) + window_builder.with_drag_and_drop(enable) } #[cfg(not(target_os = "windows"))] diff --git a/crates/egui_glow/examples/pure_glow.rs b/crates/egui_glow/examples/pure_glow.rs index 3c20a7c1..4dab4f3a 100644 --- a/crates/egui_glow/examples/pure_glow.rs +++ b/crates/egui_glow/examples/pure_glow.rs @@ -29,7 +29,7 @@ impl GlutinWindowContext { // try egl and fallback to windows wgl. Windows is the only platform that *requires* window handle to create display. #[cfg(target_os = "windows")] - let preference = glutin::display::DisplayApiPreference::EglThenWgl(Some(window_handle)); + let preference = glutin::display::DisplayApiPreference::EglThenWgl(Some(raw_window_handle)); // try egl and fallback to x11 glx #[cfg(target_os = "linux")] let preference = glutin::display::DisplayApiPreference::EglThenGlx(Box::new(