add keyboard shortcuts and make todos selectable useing j and k

This commit is contained in:
Reinier Balt 2013-07-01 15:56:54 +02:00
parent b725b7b137
commit db29b84f69
17 changed files with 217 additions and 99 deletions

View file

@ -41,8 +41,11 @@ $ ->
mouseTrapRails.toggleHints() if mouseTrapRails.showOnLoad
# HELP
Mousetrap.bind '?', -> $('div#tracks-shortcuts-dialog').modal()
Mousetrap.bind 'a', -> $('div#tracks-add-action-dialog').modal()
# ADD: a is bound in navbar
# GO TO
# Mousetrap.bind 'g h', TracksApp.go_home
Mousetrap.bind 'g c', -> alert("go context")
@ -50,6 +53,11 @@ $ ->
Mousetrap.bind 'g t', -> alert("go tag")
Mousetrap.bind 'g p', -> alert("go project")
# Mousetrap.bind 'g P', TracksApp.go_projects
# VIEW
Mousetrap.bind 'v p', -> alert("group by project")
Mousetrap.bind 'v c', -> alert("group by context")
# Item Selection
Mousetrap.bind 'j', -> TracksApp.selectNext()
Mousetrap.bind 'k', -> TracksApp.selectPrev()