indefero/src/IDF/templates/js-hotkeys.html

14 lines
530 B
HTML
Raw Normal View History

2008-07-25 08:26:05 +00:00
<script type="text/javascript" src="{media '/idf/js/jquery.hotkeys.js'}"></script>
{if $project}
<script type="text/javascript" charset="utf-8">
// <!--
var hk_submit_issue = '{url 'IDF_Views_Issue::create', array($project.shortname)}';
var hk_recent_issues = '{url 'IDF_Views_Issue::index', array($project.shortname)}';
{literal}
jQuery.hotkeys.add('Shift+a',function (){window.location.href=hk_submit_issue;});
jQuery.hotkeys.add('Shift+r',function (){window.location.href=hk_recent_issues;});
{/literal} //-->
</script>
{/if}