lib/har/viewer/scripts/downloadify/js/downloadify.min.js in har-0.1.0 vs lib/har/viewer/scripts/downloadify/js/downloadify.min.js in har-0.1.1

- old
+ new

@@ -1,4 +1,8 @@ -(function(){Downloadify=window.Downloadify={queue:{},uid:(new Date).getTime(),getTextForSave:function(a){if(a=Downloadify.queue[a])return a.getData();return""},getFileNameForSave:function(a){if(a=Downloadify.queue[a])return a.getFilename();return""},saveComplete:function(a){(a=Downloadify.queue[a])&&a.complete();return!0},saveCancel:function(a){(a=Downloadify.queue[a])&&a.cancel();return!0},saveError:function(a){(a=Downloadify.queue[a])&&a.error();return!0},addToQueue:function(a){Downloadify.queue[a.queue_name]=a},getUID:function(a){a.id==""&&(a.id="downloadify_"+Downloadify.uid++);return a.id}},Downloadify.create=function(a,b){a=typeof a=="string"?document.getElementById(a):a;return new Downloadify.Container(a,b)},Downloadify.Container=function(a,b){function d(){c.options=b,c.options.append||(c.el.innerHTML=""),c.flashContainer=document.createElement("span"),c.el.appendChild(c.flashContainer),c.queue_name=Downloadify.getUID(c.flashContainer),typeof c.options.filename==="function"?c.filenameCallback=c.options.filename:c.options.filename&&(c.filename=c.options.filename),typeof c.options.data==="function"?c.dataCallback=c.options.data:c.options.data&&(c.data=c.options.data);var a={queue_name:c.queue_name,width:c.options.width,height:c.options.height},d={allowScriptAccess:"always"},e={id:c.flashContainer.id,name:c.flashContainer.id};c.options.enabled===!1&&(c.enabled=!1),c.options.transparent===!0&&(d.wmode="transparent"),c.options.downloadImage&&(a.downloadImage=c.options.downloadImage),swfobject.embedSWF(c.options.swf,c.flashContainer.id,c.options.width,c.options.height,"10",null,a,d,e),Downloadify.addToQueue(c)}var c=this;c.el=a,c.enabled=!0,c.dataCallback=null,c.filenameCallback=null,c.data=null,c.filename=null,c.enable=function(){var a=document.getElementById(c.flashContainer.id);a.setEnabled(!0),c.enabled=!0},c.disable=function(){var a=document.getElementById(c.flashContainer.id);a.setEnabled(!1),c.enabled=!1},c.getData=function(){if(!c.enabled)return"";return c.dataCallback?c.dataCallback():c.data?c.data:""},c.getFilename=function(){return c.filenameCallback?c.filenameCallback():c.filename?c.filename:""},c.complete=function(){typeof c.options.onComplete==="function"&&c.options.onComplete()},c.cancel=function(){typeof c.options.onCancel==="function"&&c.options.onCancel()},c.error=function(){typeof c.options.onError==="function"&&c.options.onError()},d()},Downloadify.defaultOptions={swf:"media/downloadify.swf",downloadImage:"images/download.png",width:100,height:30,transparent:!0,append:!1}})(),typeof jQuery!="undefined"&&function(a){a.fn.downloadify=function(c){return this.each(function(){c=a.extend({},Downloadify.defaultOptions,c);var d=Downloadify.create(this,c);a(this).data("Downloadify",d)})}}(jQuery) +/* Downloadify 0.1 (c) 2009 by Douglas Neiner. Licensed under the MIT license */ + +/* See http://github.com/dcneiner/Downloadify for license and more info */ + +(function(){Downloadify=window.Downloadify={queue:{},uid:(new Date).getTime(),getTextForSave:function(e){return(e=Downloadify.queue[e])?e.getData():""},getFileNameForSave:function(e){return(e=Downloadify.queue[e])?e.getFilename():""},saveComplete:function(e){return(e=Downloadify.queue[e])&&e.complete(),!0},saveCancel:function(e){return(e=Downloadify.queue[e])&&e.cancel(),!0},saveError:function(e){return(e=Downloadify.queue[e])&&e.error(),!0},addToQueue:function(e){Downloadify.queue[e.queue_name]=e},getUID:function(e){return e.id==""&&(e.id="downloadify_"+Downloadify.uid++),e.id}},Downloadify.create=function(e,t){return e=typeof e=="string"?document.getElementById(e):e,new Downloadify.Container(e,t)},Downloadify.Container=function(e,t){function r(){n.options=t,n.options.append||(n.el.innerHTML=""),n.flashContainer=document.createElement("span"),n.el.appendChild(n.flashContainer),n.queue_name=Downloadify.getUID(n.flashContainer),typeof n.options.filename=="function"?n.filenameCallback=n.options.filename:n.options.filename&&(n.filename=n.options.filename),typeof n.options.data=="function"?n.dataCallback=n.options.data:n.options.data&&(n.data=n.options.data);var e={queue_name:n.queue_name,width:n.options.width,height:n.options.height},r={allowScriptAccess:"always"},i={id:n.flashContainer.id,name:n.flashContainer.id};n.options.enabled===!1&&(n.enabled=!1),n.options.transparent===!0&&(r.wmode="transparent"),n.options.downloadImage&&(e.downloadImage=n.options.downloadImage),swfobject.embedSWF(n.options.swf,n.flashContainer.id,n.options.width,n.options.height,"10",null,e,r,i),Downloadify.addToQueue(n)}var n=this;n.el=e,n.enabled=!0,n.dataCallback=null,n.filenameCallback=null,n.data=null,n.filename=null,n.enable=function(){var e=document.getElementById(n.flashContainer.id);e.setEnabled(!0),n.enabled=!0},n.disable=function(){var e=document.getElementById(n.flashContainer.id);e.setEnabled(!1),n.enabled=!1},n.getData=function(){return n.enabled?n.dataCallback?n.dataCallback():n.data?n.data:"":""},n.getFilename=function(){return n.filenameCallback?n.filenameCallback():n.filename?n.filename:""},n.complete=function(){typeof n.options.onComplete=="function"&&n.options.onComplete()},n.cancel=function(){typeof n.options.onCancel=="function"&&n.options.onCancel()},n.error=function(){typeof n.options.onError=="function"&&n.options.onError()},r()},Downloadify.defaultOptions={swf:"media/downloadify.swf",downloadImage:"images/download.png",width:100,height:30,transparent:!0,append:!1}})(),typeof jQuery!="undefined"&&function(e){e.fn.downloadify=function(t){return this.each(function(){t=e.extend({},Downloadify.defaultOptions,t);var n=Downloadify.create(this,t);e(this).data("Downloadify",n)})}}(jQuery); \ No newline at end of file