diff options
author | Tim Almdal <tnalmdal@shaw.ca> | 2009-06-27 16:57:38 -0700 |
---|---|---|
committer | Tim Almdal <tnalmdal@shaw.ca> | 2009-06-27 16:57:38 -0700 |
commit | 4707a97b826b12958fda6d59d157726b246693cd (patch) | |
tree | 2e15d54f2749b76250ffc02184053496e066b2b1 /modules/digibug/js | |
parent | 11f08ee4399c62cc1d2c36457a214c6db693db06 (diff) | |
parent | 76f688a070c7c36eb84dc22b21b165f00440a4a4 (diff) |
Merge branch 'master' of git@github.com:gallery/gallery3
Diffstat (limited to 'modules/digibug/js')
-rw-r--r-- | modules/digibug/js/digibug.js | 42 |
1 files changed, 14 insertions, 28 deletions
diff --git a/modules/digibug/js/digibug.js b/modules/digibug/js/digibug.js index 837c8f7f..78ca8cf3 100644 --- a/modules/digibug/js/digibug.js +++ b/modules/digibug/js/digibug.js @@ -1,26 +1,16 @@ -$(document).ready(function() { - $(".gDigibugPrintButton a").click(function(e) { - e.preventDefault(); - queue_print(e); - }); - $("#gDigibugLink").click(function(e) { - e.preventDefault(); - return queue_print(e); - }); -}); - -function popUp(url, options) { +function digibug_popup(url, options) { options = $.extend({ /* default options */ - width: 400, - height: 400, + width: '800', + height: '600', target: 'dbPopWin', scrollbars: 'yes', resizable: 'no', menuBar: 'no', - addressBar: 'yes'}, options); + addressBar: 'yes' + }, options); - /* center the window by default. */ + // center the window by default. if (!options.winY) { options.winY = screen.height / 2 - options.height / 2; }; @@ -32,19 +22,15 @@ function popUp(url, options) { url, options['target'], 'width= ' + options.width + - ',height=' + options.height + - ',top=' + options.winY + - ',left=' + options.winX + - ',scrollbars=' + options.scrollbars + - ',resizable=' + options.resizable + - ',menubar=' + options.menuBar + - ',location=' + options.addressBar - ); + ',height=' + options.height + + ',top=' + options.winY + + ',left=' + options.winX + + ',scrollbars=' + options.scrollbars + + ',resizable=' + options.resizable + + ',menubar=' + options.menuBar + + ',location=' + options.addressBar + ); return false; } - -function queue_print(e) { - return popUp(e.currentTarget.href, { width: 800, height: 600 } ); -}; |