/*! (c) Ashampoo GmbH & Co. KG */
var bant={isOk:function(){try{return window.external.bant.isOk()}catch(t){return!1}return!1},WebSocket:function(t,e){void 0===e&&(e=""),Array.isArray(e)||(e=[e]),e=e.join(),this._instance=window.external.bant.websocket.create(this,t,e)},log:{debug:function(t){return window.external.bant.log("debug",t)},info:function(t){return window.external.bant.log("info",t)},warning:function(t){return window.external.bant.log("warning",t)},error:function(t){return window.external.bant.log("error",t)}},getVersion:function(){return"3.0"},execute:{uri:function(t,e){return window.external.bant.execute.uri(t,e)},linktarget:function(t,e){return void 0===e&&(e=""),window.external.bant.execute.linktarget(t,e)}},utils:{addFiles:function(t){return window.external.bant.utils.addFiles(t)},is_in:function(t,e){for(var n=0;n<e.length;++n)if(e[n]==t)return!0;return!1},is_in_no_case:function(t,e){for(var n=0;n<e.length;++n)if(e[n].toLowerCase()==t.toLowerCase())return!0;return!1}},callback:{dialog:{onClose:function(t){return!0},onShow:function(){return!0}},clipboard:{onText:function(t){return!0},onLicenseKey:function(t){return!0},onEMailAddress:function(t){return!0}},download:{onCompleted:function(t){return!0},onAborted:function(t){return!0}}},resources:{get:function(t){return void 0===t&&(t="*"),JSON.parse(window.external.bant.resources.get(t))},set:function(t){return window.external.bant.resources.set(JSON.stringify(t))},setup:{getTitle:function(t){return bant.resources.load(t,"setup.title","### SETUP.TITLE ###")}}},service:{update:{execute:function(t){return window.external.bant.service.update.execute(t)},exists:function(){return window.external.bant.service.update.exists()}},upgrade:{exists:function(){return window.external.bant.service.upgrade.exists()},execute:function(t){return window.external.bant.service.upgrade.execute(t)},info:{execute:function(){return window.external.bant.service.upgrade.info.execute()}}},sendFeedback:function(t,e){return void 0===t&&(t=null),void 0===e&&(e={}),window.external.bant.service.sendFeedback(t,JSON.stringify(e))}},license:{update:function(t){return JSON.parse(window.external.bant.license.update(JSON.stringify(t)))},isValid:function(t){return window.external.bant.license.isValid(JSON.stringify(t))}},button:{click:function(t,e){return window.external.bant.button.click(t,e)}},dialog:{close:function(t,e){return window.external.bant.dialog.close(t,e)},load:function(t,e){return window.external.bant.dialog.load(t,e)},layout_min:function(t,e){for(var n=t,o=e,r=document.body.getElementsByTagName("*"),i=0,a=r.length;i<a;i++){var u=r[i].getBoundingClientRect();u.right>n&&(n=parseInt(u.right)),u.bottom>o&&(o=parseInt(u.bottom))}return window.external.bant.dialog.layout(n,o)},layout:function(){return bant.dialog.layout_min(0,0)},center:function(){return window.external.bant.dialog.center()},getX:function(){return window.external.bant.dialog.getX()},getY:function(){return window.external.bant.dialog.getY()},setPosition:function(t,e){return window.external.bant.dialog.setPosition(t,e)},getHeight:function(){return window.external.bant.dialog.getHeight()},getWidth:function(){return window.external.bant.dialog.getWidth()},setSize:function(t,e){return window.external.bant.dialog.setSize(t,e)},startDrag:function(t,e){return window.external.bant.dialog.startDrag(t,e)},localize:function(){for(var t=bant.resources.get("product").language,e=document.body.getElementsByTagName("*"),n=0,o=e.length;n<o;n++){var r=e[n];if(null!=r&&r.hasAttribute("data-localize-id")){var i=r.getAttribute("data-localize-id");bant.utils.is_in_no_case(r.tagName,["h1","h2","h3","h4","h5","h6","a","div","span","label","button","textarea","p"])&&(r.innerText=window.external.bant.dialog.localize(r,i,r.innerText)),r.hasAttribute("title")&&r.setAttribute("title",window.external.bant.dialog.localize(r,i+".title",r.getAttribute("title"))),r.hasAttribute("placeholder")&&r.setAttribute("placeholder",window.external.bant.dialog.localize(r,i+".placeholder",r.getAttribute("placeholder"))),r.setAttribute("lang",t)}}}}};bant.WebSocket.prototype.send=function(t){window.external.bant.websocket.send(this._instance,t)},bant.WebSocket.prototype.close=function(t,e){void 0===t&&(t=1e3),void 0===e&&(e=""),window.external.bant.websocket.close(this._instance,t,e)},bant.WebSocket.prototype._onopen=function(){return this.onopen()},bant.WebSocket.prototype.onopen=function(){},bant.WebSocket.prototype._onmessage=function(t){return evt={},evt.data=t,this.onmessage(evt)},bant.WebSocket.prototype.onmessage=function(t){},bant.WebSocket.prototype._onerror=function(){return evt={},this.onerror(evt)},bant.WebSocket.prototype.onerror=function(t){},bant.WebSocket.prototype._onclose=function(t,e,n){return evt={},evt.code=t,evt.reason=e,evt.wasClean=n,this.onclose(evt)},bant.WebSocket.prototype.onclose=function(){};