Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use the Tauri implementation of the DPI-change fix #10

Open
wants to merge 2 commits into
base: warpdotdev/v0.30.x
Choose a base branch
from

Conversation

acarl005
Copy link
Collaborator

@acarl005 acarl005 commented Feb 14, 2025

This PR is another attempt at #8. Instead of deleting that check altogether, it is guarded by a Windows version check. Tauri noticed in tauri-apps/tao#1056 that this is still necessary in Windows 10. In this commit i've reverted my fix and applied theirs on top.

It's a little easier to see using this semantic diff tool that they just wrapped a big block of code in an if-else.

Using that same tool to visualize this diff: https://app.semanticdiff.com/gh/warpdotdev/winit/pull/10/changes#src/platform_impl/windows/event_loop.rs?ignore_comments=false

@@ -26,6 +27,9 @@ use windows_sys::Win32::UI::WindowsAndMessaging::{

use crate::window::CursorIcon;

pub static WIN_VERSION: LazyLock<windows_version::OsVersion> =
LazyLock::new(windows_version::OsVersion::current);

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@acarl005 acarl005 requested a review from vorporeal February 14, 2025 16:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants