window-edge snap during drag via WM_MOVING subclass

This commit is contained in:
2026-05-12 01:56:24 +03:00
parent afb3f24375
commit 953263028b
3 changed files with 123 additions and 1 deletions
+6
View File
@@ -4,6 +4,7 @@ mod capture;
mod clicks;
mod config;
mod encode;
mod snap;
mod updates;
use std::path::{Path, PathBuf};
@@ -973,6 +974,11 @@ pub fn run() {
(cfg.updates.check_on_launch, cfg)
};
register_hotkeys(app.handle(), &cfg);
if let Some(overlay) = app.get_webview_window("overlay") {
if let Ok(raw) = overlay.hwnd() {
snap::attach(raw.0 as isize);
}
}
if check_on_launch {
let handle = app.handle().clone();
tauri::async_runtime::spawn(async move {