@fat You mean like this? Of course I can do this.
```
var type = e.which == 37 ? 'prev'  :
           e.which == 38 ? 'first' :
           e.which == 39 ? 'next'  :
           e.which == 40 ? 'last'  : false
```