It is now possible to add mouse directions.

Furthermore, it is now possible to read keys, mousedirections, and
mousepedals on the same pedal with print_mouse_key(1)
This commit is contained in:
2018-08-07 00:48:16 +02:00
parent 0d55a26626
commit 6fd43a14ed
3 changed files with 66 additions and 7 deletions

View File

@@ -131,7 +131,7 @@ fn main() {
"set_key" => {
pedals.set_key(ped_list[i] as usize, val_list[i].as_str());
}
"set_mouse" => {
"set_mousebutton" => {
pedals.set_mousebutton(ped_list[i] as usize, val_list[i].as_str());
}
"del_key" => {
@@ -144,6 +144,15 @@ fn main() {
"app_mod" => {
pedals.set_modifier(ped_list[i] as usize, val_list[i].as_str());
}
"set_x" => {
pedals.set_mouse_xyw(ped_list[i] as usize, val_list[i].as_str(), 5)
}
"set_y" => {
pedals.set_mouse_xyw(ped_list[i] as usize, val_list[i].as_str(), 6)
}
"set_w" => {
pedals.set_mouse_xyw(ped_list[i] as usize, val_list[i].as_str(), 7)
}
_ => {
error!("Unknown command!");
}