-Mousetrap.bind('n', function() { move_to_nondeleted(1); setpic(); });
-Mousetrap.bind('p', function() { move_to_nondeleted(-1); setpic(); });
-Mousetrap.bind('N', function() { input_index ++; setpic(); });
-Mousetrap.bind('P', function() { input_index --; setpic(); });
-Mousetrap.bind('b', function() { exposure ++; setpic(); });
-Mousetrap.bind('d', function() { exposure --; setpic(); });
-Mousetrap.bind('x', function() { mark_deleted(); });
-Mousetrap.bind('X', function() { mark_not_deleted(); });
+Mousetrap.bind(['n', 'l'], function() { move_to_nondeleted(1); });
+Mousetrap.bind(['p', 'h'], function() { move_to_nondeleted(-1); });
+Mousetrap.bind(['N', 'L'], function() { move_to_unnamed(1); });
+Mousetrap.bind(['P', 'H'], function() { move_to_unnamed(-1); });
+Mousetrap.bind(['m n', 'm l'], function() { move(1); });
+Mousetrap.bind(['m n', 'm h'], function() { move(-1); });
+Mousetrap.bind(['b', 'k'], function() { change_exposure(1); });
+Mousetrap.bind(['d', 'j'], function() { change_exposure(-1); });
+Mousetrap.bind('0', move_to_begenning);
+Mousetrap.bind('$', move_to_end);
+Mousetrap.bind('x', function(){ mark_deleted("deleted"); });
+Mousetrap.bind('X', mark_not_deleted);
+Mousetrap.bind('e', function(){ mark_deleted("extra"); });
+Mousetrap.bind('E', mark_not_deleted);
+Mousetrap.bind('g', function(){ mark_deleted("blurry"); });
+Mousetrap.bind('G', mark_not_deleted);
+Mousetrap.bind('r', rotate);
+Mousetrap.bind('i', announce);
+Mousetrap.bind('f', function() { say(files[input_index]); });
+Mousetrap.bind('B', function() { say_exposure(); });
+Mousetrap.bind('c', function() { $("#name").show().focus(); return false; });
+Mousetrap.bind('C', function() { if (last_name) { set_name(last_name); } });
+Mousetrap.bind('%', function() { say((100 * input_index / files.length).toFixed(2) + "%"); });
+Mousetrap.bind('!', show_commands);
+Mousetrap.bind('esc', function() { $("#name").hide(); $("#shell_out").hide(); });
+
+function clean_picinfo() {
+ files_index = {};
+ $.each(files, function(i, f) {
+ files_index[f] = true;
+ });
+ for (f in picinfo) {
+ if (!files_index[f]) {
+ delete picinfo[f];
+ }
+ }
+}
+
+function undelete_all() {
+ for (f in picinfo) {
+ delete picinfo[f].deleted;
+ }
+ save_picinfo();
+ say("Undeleted everything");
+}