mirror of
https://github.com/rustdesk/rustdesk.git
synced 2025-05-11 18:36:11 +02:00
min scroll, 0.1 thread
Signed-off-by: dignow <linlong1265@gmail.com>
This commit is contained in:
parent
3188051667
commit
c8cd10b6de
1 changed files with 8 additions and 0 deletions
|
@ -336,6 +336,14 @@ class InputModel {
|
|||
_trackpadLastDelta = delta;
|
||||
var x = delta.dx.toInt();
|
||||
var y = delta.dy.toInt();
|
||||
if (x == 0 && y == 0) {
|
||||
final thr = 0.1;
|
||||
if (delta.dx.abs() > delta.dy.abs()) {
|
||||
x = delta.dx > thr ? 1 : (delta.dx < -thr ? -1 : 0);
|
||||
} else {
|
||||
y = delta.dy > thr ? 1 : (delta.dy < -thr ? -1 : 0);
|
||||
}
|
||||
}
|
||||
if (x != 0 || y != 0) {
|
||||
bind.sessionSendMouse(
|
||||
sessionId: sessionId,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue