]> git.scottworley.com Git - picsort/blobdiff - picsorter.js
pic-mv chmod's to 644
[picsort] / picsorter.js
index 213a553ac488356fc9b15d4784c5e2bace04a51b..f1847841dc052819c962b94e0d487093eca951fd 100644 (file)
@@ -152,7 +152,8 @@ function shell_escape(x) {
 function show_commands() {
   var commands = [];
   $.each(files, function(i, f) {
-    if ("name" in picinfo[f] && picinfo[f].name.length > 0) {
+    if ("name" in picinfo[f] && picinfo[f].name.length > 0 &&
+        !("deleted" in picinfo[f])) {
       var command = ["pic-mv"];
       if ("exposure" in picinfo[f]) {
         command.push("-e " + picinfo[f].exposure);
@@ -165,6 +166,7 @@ function show_commands() {
       commands.push(command.join(" "));
     }
   });
+  commands.push("");
   $("#shell_out").text(commands.join("\n")).show();
 }
 
@@ -189,3 +191,4 @@ Mousetrap.bind('r', rotate);
 Mousetrap.bind('c', function() { $("#name").show().focus(); return false; });
 Mousetrap.bind('%', function() { say((100 * input_index / files.length).toFixed(2) + "%"); });
 Mousetrap.bind('!', show_commands);
+Mousetrap.bind('esc', function() { $("#name").hide(); $("#shell_out").hide(); });