(function(){function d(){}d.prototype={bind:function(a){for(var b in a)c.addShortcut(b,a[b])},bindWithDelay:function(a){for(var b in a)c.addShortcut(b,this._handleDelayedShortcut(a[b]))},_handleDelayedShortcut:function(a){var b=null,e=null;return function(g){clearTimeout(b);clearTimeout(e);c.commandCanRun()&&null===b&&(b=setTimeout(function(){a(g)},150));e=setTimeout(function(){b=null},200)}}};var c={addShortcut:function(a,b){var c=new maxkir.KbdMatcher(a);maxkir.KbdMatcher.matchers.pop();c.resetUnmatched= function(a){c.has_sequence(a)||c.reset()};return maxkir.kbd.forCondition(function(a){return c.matches(a)}).addHook(function(a){b(a)})},collapse:function(){return maxkir.ChecklistNodeToggle.collapse(this.getTaskId())},expand:function(){return maxkir.ChecklistNodeToggle.expand(this.getTaskId())},setFocus:function(){return maxkir.TaskFocus.set_focus(this.getTaskId())},removeFocus:function(){return maxkir.TaskFocus.remove_focus(this.getTaskId())},commandCanRun:function(){return maxkir.cmd.can_run(!0)}, getTaskId:function(){return maxkir.Task.selected_task_id()}},f=new d;f.bindWithDelay({h:function(){c.collapse()},l:function(){c.expand()},o:function(a){maxkir.cmd.add_task()&&Event.stop(a)},"shift+g":function(){maxkir.tree_nav.selectLastInTree()}});f.bind({"shift+h":function(){c.removeFocus()},"shift+l":function(){c.setFocus()},"shift+o":function(a){maxkir.cmd.add_task(!0)&&Event.stop(a)},"alt+g alt+g":function(){maxkir.tree_nav.selectFirstInTree()}})})();

(function(){function e(){}e.prototype={bind:function(a){for(var b in a)d.addShortcut(b,this._handleShortcut(a[b]))},bindWithDelay:function(a,b){for(var c in a)d.addShortcut(c,this._handleDelayedShortcut(a[c],b))},_handleShortcut:function(a){return function(b){d.commandCanRun()&&a(b)}},_handleDelayedShortcut:function(a,b){var c=null,f=null;b=b||150;return function(e){clearTimeout(c);clearTimeout(f);d.commandCanRun()&&null===c&&(c=setTimeout(function(){a(e)},b));f=setTimeout(function(){c=null},b+50)}}}; var d={addShortcut:function(a,b){var c=new maxkir.KbdMatcher(a);maxkir.KbdMatcher.matchers.pop();c.resetUnmatched=function(a){c.has_sequence(a)||c.reset()};return maxkir.kbd.forCondition(function(a){return c.matches(a)}).addHook(function(a){b(a)})},collapse:function(){return maxkir.ChecklistNodeToggle.collapse(this.getTaskId())},expand:function(){return maxkir.ChecklistNodeToggle.expand(this.getTaskId())},setFocus:function(){return maxkir.TaskFocus.set_focus(this.getTaskId())},removeFocus:function(){return maxkir.TaskFocus.remove_focus(this.getTaskId())}, commandCanRun:function(){return maxkir.cmd.can_run(!0)},getTaskId:function(){return maxkir.Task.selected_task_id()}},g=new e;g.bindWithDelay({h:function(){d.collapse()},l:function(){d.expand()},o:function(a){maxkir.cmd.add_task()&&Event.stop(a)},"shift+g":function(){maxkir.tree_nav.selectLastInTree()}});g.bind({"shift+h":function(){d.removeFocus()},"shift+l":function(){d.setFocus()},"shift+o":function(a){maxkir.cmd.add_task(!0)&&Event.stop(a)},"alt+g alt+g":function(){maxkir.tree_nav.selectFirstInTree()}})})();

Update min file