From: Janusz Dobrowolski Date: Wed, 1 Apr 2009 20:06:46 +0000 (+0000) Subject: Fixed print link hotkey selection. X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=commitdiff_plain;h=c40ac63fe07a545a768721c860c87e3e61adb0d5;p=textcart.git Fixed print link hotkey selection. --- diff --git a/js/inserts.js b/js/inserts.js index a1640de..8e18e5c 100644 --- a/js/inserts.js +++ b/js/inserts.js @@ -355,14 +355,17 @@ function setHotKeys() { _hotkeys.alt = false; if (_hotkeys.focus>=0) { var link = document.links[_hotkeys.focus]; - if (link.target=='_blank') { -// window.open(link.href,'','toolbar=no,scrollbar=no,resizable=yes,menubar=no,width=900,height=500'); - openWindow(link.href,'_blank'); - } else - window.location = link.href; + if(link.onclick) + link.onclick(); + else + if (link.target=='_blank') { + window.open(link.href,'','toolbar=no,scrollbar=no,resizable=yes,menubar=no,width=900,height=500'); + openWindow(link.href,'_blank'); + } else + window.location = link.href; } - } return stopEv(ev); + } } return true; }