more keyboard shortcuts
This commit is contained in:
parent
ff3315ebf1
commit
4a232151e0
@ -140,9 +140,8 @@ class Display {
|
|||||||
}
|
}
|
||||||
|
|
||||||
entryScroll(index, smooth) {
|
entryScroll(index, smooth) {
|
||||||
if (index < 0 || index >= this.definitions.length) {
|
index = Math.min(index, this.definitions.length - 1);
|
||||||
return;
|
index = Math.max(index, 0);
|
||||||
}
|
|
||||||
|
|
||||||
$('.current').hide().eq(index).show();
|
$('.current').hide().eq(index).show();
|
||||||
|
|
||||||
@ -217,6 +216,14 @@ class Display {
|
|||||||
this.entryScroll(this.definitions.length - 1, true);
|
this.entryScroll(this.definitions.length - 1, true);
|
||||||
},
|
},
|
||||||
|
|
||||||
|
33: /* page up */ () => {
|
||||||
|
this.entryScroll(this.index - 3, true);
|
||||||
|
},
|
||||||
|
|
||||||
|
34: /* page down */ () => {
|
||||||
|
this.entryScroll(this.index + 3, true);
|
||||||
|
},
|
||||||
|
|
||||||
38: /* up */ () => {
|
38: /* up */ () => {
|
||||||
this.entryScroll(this.index - 1, true);
|
this.entryScroll(this.index - 1, true);
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user