mirror of
https://github.com/mofeng-git/One-KVM.git
synced 2026-02-01 02:21:53 +08:00
interactive hid leds
This commit is contained in:
@@ -8,14 +8,19 @@ var hid = new function() {
|
||||
this.init = function() {
|
||||
keyboard.init();
|
||||
mouse.init();
|
||||
}
|
||||
};
|
||||
|
||||
this.updateLeds = function() {
|
||||
keyboard.updateLeds();
|
||||
mouse.updateLeds();
|
||||
};
|
||||
|
||||
this.releaseAll = function() {
|
||||
keyboard.releaseAll();
|
||||
};
|
||||
|
||||
this.emitShortcut = function(...codes) {
|
||||
console.log(codes);
|
||||
tools.debug("Emitted keys:", codes);
|
||||
var delay = 0;
|
||||
[[codes, true], [codes.slice().reverse(), false]].forEach(function(op) {
|
||||
var [op_codes, state] = op;
|
||||
|
||||
Reference in New Issue
Block a user