fix: 修改扫码枪监听
这个提交包含在:
父节点
37a7f6ae13
当前提交
266ce0c6a7
@ -48,14 +48,17 @@ public class GlobalKeyListenerExample implements NativeKeyListener {
|
||||
return NativeKeyEvent.getKeyText(n);
|
||||
}).collect(Collectors.toList());
|
||||
|
||||
for (String s : collect) {
|
||||
result = result + s;
|
||||
}
|
||||
if (queue.size() == 5) {
|
||||
log.info("符合标准的扫码是:"+ result.replace("Enter",""));
|
||||
for (String s : collect) {
|
||||
result = result + s;
|
||||
}
|
||||
}else {
|
||||
log.info("符合标准的扫码是:"+ result.substring(1).replace("Enter",""));
|
||||
for (int i = 1; i < collect.size(); i++) {
|
||||
result = result + collect.get(i);
|
||||
}
|
||||
}
|
||||
|
||||
log.info("符合标准的扫码是:"+ result.replace("Enter",""));
|
||||
queue.clear();
|
||||
}
|
||||
if (queue.size() == 6){
|
||||
|
正在加载...
在新工单中引用
屏蔽一个用户