gui-apps/lan-mouse: update wlroots scroll patch

add RESTRICT=mirror and RUST_MIN_VERSION

Signed-off-by: Thomas Matthijs <gentoo@selckin.be>
This commit is contained in:
Thomas Matthijs
2025-08-15 21:21:15 +02:00
parent 43144d9dc1
commit a927d3ad6d
2 changed files with 22 additions and 5 deletions

View File

@@ -1,16 +1,29 @@
--- i/input-emulation/src/wlroots.rs
+++ w/input-emulation/src/wlroots.rs
@@ -208,11 +208,11 @@ impl VirtualInput {
--- a/input-emulation/src/wlroots.rs
+++ b/input-emulation/src/wlroots.rs
@@ -10,11 +10,11 @@ use std::sync::{Arc, Mutex};
use std::time::{SystemTime, UNIX_EPOCH};
use wayland_client::backend::WaylandError;
use wayland_client::WEnum;
use wayland_client::protocol::wl_keyboard::{self, WlKeyboard};
-use wayland_client::protocol::wl_pointer::{Axis, ButtonState};
+use wayland_client::protocol::wl_pointer::{Axis, AxisSource, ButtonState};
use wayland_client::protocol::wl_seat::WlSeat;
use wayland_protocols_wlr::virtual_pointer::v1::client::{
zwlr_virtual_pointer_manager_v1::ZwlrVirtualPointerManagerV1 as VpManager,
zwlr_virtual_pointer_v1::ZwlrVirtualPointerV1 as Vp,
};
@@ -208,11 +208,12 @@ impl VirtualInput {
self.pointer.frame();
}
PointerEvent::AxisDiscrete120 { axis, value } => {
let axis: Axis = (axis as u32).try_into()?;
self.pointer
- .axis_discrete(now, axis, value as f64 / 6., value / 120);
+ .axis_discrete(now, axis, value as f64 / 6., value);
+ .axis_discrete(now, axis, value as f64 / 8., value);
+ self.pointer.axis_source(AxisSource::Wheel);;
self.pointer.frame();
}
}
self.pointer.frame();
}

View File

@@ -418,6 +418,8 @@ CRATES="
zvariant_utils@3.0.2
"
RUST_MIN_VER="1.80"
inherit cargo desktop systemd xdg
DEPEND="
@@ -452,6 +454,8 @@ LICENSE+="
SLOT="0"
KEYWORDS="~amd64"
RESTRICT="mirror"
QA_FLAGS_IGNORED="usr/bin/lan-mouse"
PATCHES=(