Comments (15)
Okay turns out, its actually UB... I should not be using transmute here
from lan-mouse.
Just to be sure: Did you upgrade both devices and restart the service?
from lan-mouse.
Yes, I did it.
from lan-mouse.
Same happening here, the Linux PC can control Windows but on Windows the mouse cannot leave the screen.
from lan-mouse.
Same here. The only version that worked for me (I just started using lan-mouse a couple of weeks ago) on two Windows 11 machines was the prerelease I downloaded on 2024-05-08, but I forgot the commit hash.
from lan-mouse.
Same here. The only version that worked for me (I just started using lan-mouse a couple of weeks ago) on two Windows 11 machines was the prerelease I downloaded on 2024-05-08, but I forgot the commit hash.
Thank you, that is very helpful!
from lan-mouse.
I am also experiencing this issue with the release versions on Windows & Wayland (0.8.0).
The cursor is able to enter the windows client but not able to return to the Wayland client.
It is working with the debug version built from source on Windows (although other issues are then present on windows side) and no changes on the Wayland side.
The release version built from source experiences the same issue as the release download.
from lan-mouse.
Okay this is interesting. I will hopefully get to take a look this weekend.
from lan-mouse.
Could you check if maybe the "barriers" are just on the wrong side? As in the position is set to right but it's actually on the left side?
from lan-mouse.
I retested with the source built release version on windows (also dropped down to just 1 monitor) and was not able to exit the screen from any screen edge despite the left being configured as the barrier to the Wayland client.
Reverting back to the source built debug version allowed me to exit from the left screen edge as expected.
from lan-mouse.
I am experiencing a similar problem. I am running version 0.8.0 on both Windows 11 and Ubuntu 22.04.
from lan-mouse.
now this is a very interesting bug. It looks to me like a compiler bug:
log::debug!("{}", wparam.0 != WM_MOUSEMOVE as usize);
log::debug!("{}, {}, {}", wparam.0, WM_MOUSEMOVE as usize, wparam.0 == WM_MOUSEMOVE as usize);
This prints
[2024-06-25T09:57:36Z DEBUG lan_mouse::capture::windows] true
[2024-06-25T09:57:36Z DEBUG lan_mouse::capture::windows] 512, 512, true
from lan-mouse.
use std::hint::black_box;
use std::ptr::addr_of;
use windows::Win32::Foundation::{LPARAM, WPARAM};
use windows::Win32::UI::WindowsAndMessaging::{MSLLHOOKSTRUCT, WM_MOUSEMOVE};
fn main() {
let msll = MSLLHOOKSTRUCT::default();
let wparam = WPARAM(512);
let lparam = LPARAM(addr_of!(msll) as *const _ as isize);
unsafe { check_client_activation(wparam, lparam) };
}
pub unsafe fn check_client_activation(wparam: WPARAM, lparam: LPARAM) -> bool {
eprintln!("{wparam:?}, {lparam:?}");
if wparam.0 != WM_MOUSEMOVE as usize {
black_box(wparam.0);
assert_ne!(wparam.0, WM_MOUSEMOVE as usize);
return true;
}
let mouse_low_level: MSLLHOOKSTRUCT =
unsafe { *std::mem::transmute::<LPARAM, *const MSLLHOOKSTRUCT>(lparam) };
black_box(mouse_low_level.pt);
true
}
reduced example... very very strange
from lan-mouse.
I have tested the dev build of lan mouse, from windows to linux is fine, but when back to windows the mouse seem to be frozen, and I can't do anything about this.
from lan-mouse.
Related Issues (20)
- [Help] I can't use him HOT 12
- client unresponsive after screen goes to sleep HOT 2
- Manual Release required between GNOME and XFCE HOT 3
- How to run it on MacOS HOT 10
- Windows: Input Lost on Elevated Programs HOT 4
- Keyboard focus broken when using Windows Emoji selector (`win+;`) HOT 3
- Some programs with mouse capture (like FPS games) fail to prevent the virtual cursor from moving & leaving the screen HOT 4
- Mouse wheel distance/speed HOT 7
- Hyprland not working with 1px shell surface HOT 12
- Can't Install on MacOS HOT 7
- Mouse pointer can't return back to Hyprland's surface HOT 3
- Custom global/host hotkeys HOT 3
- Input Capture not working in Plasma 6.1 HOT 19
- 32-bit build fails HOT 2
- Just asking HOT 1
- KDE Request permission for input emulation cancelled immediately with no prompt HOT 3
- Works only one way HOT 1
- BUG: stoped working after upgrading to Plasma 6.1.0 HOT 9
- Can't control from Hyprland Server a Windows Client / Client can control Server HOT 9
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from lan-mouse.