Make input and output tab areas scrollable

This commit is contained in:
j433866 2019-06-03 16:10:05 +01:00
parent f5cf7bb1f2
commit 2575a762e1
3 changed files with 37 additions and 3 deletions

View file

@ -265,7 +265,7 @@ class InputWaiter {
this.showLoadingInfo(r.data, true);
break;
case "setInput":
this.set(r.data.inputObj, r.data.silent);
this.app.debounce(this.set, 50, "setInput", this, [r.data.inputObj, r.data.siilent])();
break;
case "inputAdded":
this.inputAdded(r.data.changeTab, r.data.inputNum);
@ -1299,6 +1299,22 @@ class InputWaiter {
}
}
/**
* Handler for scrolling on the input tabs area
*
* @param {event} wheelEvent
*/
scrollTab(wheelEvent) {
wheelEvent.preventDefault();
if (wheelEvent.deltaY > 0) {
this.changeTabLeft();
} else if (wheelEvent.deltaY < 0) {
this.changeTabRight();
}
}
/**
* Handler for clicking on next tab button
*/