From: Michael M Slusarz Date: Fri, 7 May 2010 21:49:35 +0000 (-0600) Subject: Use Horde.popup() in DIMP X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=e099027563302cf4706285953d712d4d4c79a68a;p=horde.git Use Horde.popup() in DIMP --- diff --git a/imp/js/DimpCore.js b/imp/js/DimpCore.js index ae4dcf4ab..04cbc29e6 100644 --- a/imp/js/DimpCore.js +++ b/imp/js/DimpCore.js @@ -266,9 +266,18 @@ var DimpCore = { this.popupWindow(this.addURLParam(url, args), 'compose' + new Date().getTime()); }, - popupWindow: function(url, name) + popupWindow: function(url, name, onload) { - if (!(window.open(url, name.replace(/\W/g, '_'), 'width=' + DIMP.conf.popup_width + ',height=' + DIMP.conf.popup_height + ',status=1,scrollbars=yes,resizable=yes'))) { + var opts = { + height: DIMP.conf.popup_height, + name: name.gsub(/\W/, '_'), + noalert: true, + onload: onload, + url: url, + width: DIMP.conf.popup_width + }; + + if (!Horde.popup(opts)) { this.showNotifications([ { type: 'horde.warning', message: DIMP.text.popup_block } ]); } },