Ticket #1179: nextgen_gallery_shutter_close.patch

File nextgen_gallery_shutter_close.patch, 811 bytes (added by snarfed, 22 months ago)
  • shutter/shutter-reloaded.js

     
    1717        else {oldonld = window.onload;window.onload = function(){if(oldonld){oldonld();};shutterOnload();}}; 
    1818} 
    1919 
     20// Escape closes shutter.  
     21document['onkeypress'] = function(e) { 
     22  if (e.keyCode == 27) shutterReloaded.hideShutter(); 
     23} 
     24 
    2025shutterReloaded = { 
    2126 
    2227        I : function (a) { 
     
    9196                if ( ! (S = t.I('shShutter')) ) { 
    9297                        S = document.createElement('div'); 
    9398                        S.setAttribute('id','shShutter'); 
     99                        S.setAttribute('onclick', 'shutterReloaded.hideShutter();return false;'); 
    94100                        document.getElementsByTagName('body')[0].appendChild(S); 
    95101                        t.hideTags(); 
    96102                }