mirror of
https://github.com/kunkundi/crossdesk.git
synced 2025-10-27 04:35:34 +08:00
[fix] fix compile error on Linux
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
#include "mouse_controller.h"
|
||||
|
||||
#include "log.h"
|
||||
#include "rd_log.h"
|
||||
|
||||
MouseController::MouseController() {}
|
||||
|
||||
@@ -80,13 +80,13 @@ int MouseController::SendMouseCommand(RemoteAction remote_action) {
|
||||
event.type = EV_REL;
|
||||
event.code = REL_WHEEL;
|
||||
event.value = remote_action.m.s;
|
||||
write(uinput_fd_, &event, sizeof(event));
|
||||
(void)write(uinput_fd_, &event, sizeof(event));
|
||||
break;
|
||||
case MouseFlag::wheel_horizontal:
|
||||
event.type = EV_REL;
|
||||
event.code = REL_HWHEEL;
|
||||
event.value = remote_action.m.s;
|
||||
write(uinput_fd_, &event, sizeof(event));
|
||||
(void)write(uinput_fd_, &event, sizeof(event));
|
||||
break;
|
||||
default:
|
||||
SetMousePosition(uinput_fd_, mouse_pos_x, mouse_pos_y);
|
||||
@@ -148,4 +148,4 @@ void MouseController::SetMousePosition(int fd, int x, int y) {
|
||||
ev_sync.value = 0;
|
||||
ev_sync.code = 0;
|
||||
int res_ev_sync = write(fd, &ev_sync, sizeof(ev_sync));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user