function MagazineApplication(a,b){"use strict";function c(){Magazine.showPopupScreen("preview",function(a,b){w.popupContainer.hide()},{title:Translate.getLabel("desc_watch_preview")})}function d(){var a=w.cookies.get("allowCookie"),b=function(){var a;null!=Config.options.cookie_check_message&&"undefined"!=typeof Config.options.cookie_check_message&&(a={},a.title=Config.options.cookie_check_message.title||!1,a.description=Config.options.cookie_check_message.description||!1),Magazine.showPopupScreen("cookiechecker",function(a,b){w.popupContainer.hide(),"allow"==b?("function"==typeof initAnalytics&&initAnalytics(),w.cookies.set("allowCookie",{allow:"y"})):(w.cookies.set("allowCookie",{allow:"n"},2),Magazine.tracker.disable())},a)};0==a?b():"n"==a.allow?Magazine.tracker.disable():("function"==typeof initAnalytics&&initAnalytics(),w.cookies.set("allowCookie",{allow:"y"}))}function e(a){try{Magazine.device.isIE9||Magazine.device.isIE8||(B=new IMHeader,B.init(a,function(){B.addToMagazine()}))}catch(a){Console.error(a,"Load header")}}function f(a){Loader.loadJs([Config.viewer_url+"/script/Request.js",Config.viewer_url+"/script/Animations.js"],a)}function g(a){var b=[Config.viewer_url+"/maggie.min.js",Config.viewer_url+"/languages/"+("undefined"!=typeof Config.locale?Config.locale:"en_gb")+".js",Config.viewer_url+"/themes/"+("undefined"!=typeof Config.theme?Config.theme:"basic")+"/Assets.js"];if(Loader.loadJs(b,a),Config.is_preview){var c=function(a){var b=a.origin||a.originalEvent.origin;if(["https://my.instantmagazine.com","http://becky-js.here:8080"].indexOf(b)!==-1)try{var c=JSON.parse(a.data);"reload"===c.action&&(window.location.reload(!0),c.url&&(window.location.href=c.url))}catch(a){}};window.addEventListener("message",c,!1)}}function h(a){if(!Config.is_screenshot&&Config.options.authentication&&"whitepaper"===Config.options.authentication.method){var b=function(){Magazine.whitepaper=Whitepaper(Config.options.authentication.params),Magazine.whitepaper.events.addEventListener(WHITEPAPER.EVENTS.READY,function(){Magazine.whitepaper.view.appendTo(w.container),$("#splash").addClass("splash-whitepaper"),$("#splash .content").attr("style",""),$("#splash .content").removeClass("im-align center-center"),Magazine.tracker.trackEvent("whitepaper","open","loginscreen"),Magazine.whitepaper.view.show()}),Magazine.whitepaper.events.addEventListener(WHITEPAPER.EVENTS.LOGIN,function(b,c,d){var e=c.getProfile();Magazine.request.setParam("user",e),Magazine.tracker.trackEvent("whitepaper",d?"skipped":"login-success",e&&e.source?e.source:""),a(),Magazine.whitepaper.view&&Magazine.whitepaper.view.hide(function(){$("#splash").removeClass("splash-whitepaper"),w.showSplashScreen(),t(),Magazine.whitepaper.destroy()})}),Magazine.whitepaper.init()};"development"===Config.environment?Loader.loadJs([Config.viewer_url+"/script/whitepaper/Whitepaper.js",Config.viewer_url+"/script/whitepaper/IMFacebook.js",Config.viewer_url+"/script/whitepaper/IMEmail.js",Config.viewer_url+"/script/whitepaper/IMLinkedin.js",Config.viewer_url+"/script/whitepaper/IMUser.js"],b):Loader.loadJs([Config.viewer_url+"/whitepaper.min.js"],b)}else a()}function i(a){var b=$(".bar",$("#splash")),c=[Config.viewer_url+"/script/library/classes/Elements/InPageNavigation.js",Config.viewer_url+"/script/library/classes/PageController.js",Config.viewer_url+"/script/library/classes/Hogan.js",Config.viewer_url+"/script/library/classes/JSDate.js",Config.viewer_url+"/script/library/classes/CookieJar.js",Config.viewer_url+"/script/library/classes/Api.js",Config.viewer_url+"/script/library/classes/Preloader.js",Config.viewer_url+"/script/library/classes/Device.js",Config.viewer_url+"/script/library/classes/Core/Storage.js",Config.viewer_url+"/script/library/classes/NavigationBar/NavigationBar.js",Config.viewer_url+"/script/library/classes/NavigationBar/NavigationItemEvents.js",Config.viewer_url+"/script/library/classes/NavigationBar/NavigationBarPage.js",Config.viewer_url+"/script/library/classes/NavigationBar/ImFavoritePage.js",Config.viewer_url+"/script/library/classes/NavigationBar/NavigationItemsController.js",Config.viewer_url+"/script/library/classes/NavigationBar/NavigationBarCustomPages.js",Config.viewer_url+"/script/library/classes/NavigationBar/ListIndex.js",Config.viewer_url+"/script/library/classes/NavigationBar/ListIndex2.js",Config.viewer_url+"/script/library/classes/NavigationBar/ListIndexMobile.js",Config.viewer_url+"/script/library/classes/NavigationBar/IconsIndex.js",Config.viewer_url+"/script/library/classes/NavigationBar/IconsIndexMobile.js",Config.viewer_url+"/script/library/classes/NavigationController.js",Config.viewer_url+"/script/library/classes/Page.js",Config.viewer_url+"/script/library/classes/SubPage.js",Config.viewer_url+"/script/library/classes/DynamicForm.js",Config.viewer_url+"/script/library/classes/Whitepaper.js",Config.viewer_url+"/script/library/classes/Header/PageHeader.js",Config.viewer_url+"/script/library/classes/Directives/ImAdsDirective.js",Config.viewer_url+"/script/library/classes/Directives/ImMediaDirective.js",Config.viewer_url+"/script/library/classes/Directives/ImStyleDirective.js",Config.viewer_url+"/script/library/classes/Directives/ImFavoriteDirective.js",Config.viewer_url+"/script/library/classes/Directives/ImFavoriteViewDirective.js",Config.viewer_url+"/script/library/classes/Directives/ImShareDirective.js",Config.viewer_url+"/script/library/classes/Directives/ImRssDirective.js",Config.viewer_url+"/script/library/classes/Directives/ImParallaxDirective.js",Config.viewer_url+"/script/library/classes/Directives/ImGalleryDirective.js",Config.viewer_url+"/script/library/classes/ImFavorite.js",Config.viewer_url+"/script/library/classes/Video/Flickr.js",Config.viewer_url+"/script/library/classes/Video/Video.js",Config.viewer_url+"/script/library/classes/Video/IframePlayer.js",Config.viewer_url+"/script/library/classes/Video/NpoPlayer.js",Config.viewer_url+"/script/library/classes/Video/IMPlayer.js",Config.viewer_url+"/script/library/classes/Video/SoundControl.js",Config.viewer_url+"/script/library/classes/Video/Wistia.js",Config.viewer_url+"/script/library/classes/Video/VidYard.js",Config.viewer_url+"/script/library/classes/Vimeo.js",Config.viewer_url+"/script/library/classes/Popup.js",Config.viewer_url+"/script/library/classes/ScrollY.js",Config.viewer_url+"/script/library/classes/ScrollList.js",Config.viewer_url+"/script/library/classes/Touch.js",Config.viewer_url+"/script/library/classes/Gallery.js",Config.viewer_url+"/script/library/classes/Social.js",Config.viewer_url+"/script/library/classes/Overlay.js",Config.viewer_url+"/script/library/classes/TableGrid.js",Config.viewer_url+"/script/library/classes/CustomComponents.js",Config.viewer_url+"/script/library/classes/Translate.js",Config.viewer_url+"/script/library/classes/Background.js",Config.viewer_url+"/script/library/classes/View/AbsoluteView.js",Config.viewer_url+"/script/library/classes/View/IMRowContainer.js",Config.viewer_url+"/script/library/classes/Header/IMHeader.js",Config.viewer_url+"/script/library/classes/NavigationControls.js",Config.viewer_url+"/script/library/helpers/ViewHelpers.js",Config.viewer_url+"/script/library/classes/Handlers/MousePositionScroll.js",Config.viewer_url+"/script/library/classes/Handlers/ScrollHandler.js",Config.viewer_url+"/script/library/classes/Handlers/IMGesture.js",Config.viewer_url+"/script/library/gs/tweener/TweenMax.min.js",Config.viewer_url+"/script/library/classes/AnimatedObject.js",Config.viewer_url+"/script/library/classes/ImageCarousel.js",Config.viewer_url+"/script/library/classes/Elements/DotPaginator.js",Config.viewer_url+"/script/library/classes/Elements/Marker.js",Config.viewer_url+"/script/library/classes/Elements/TextBalloon.js",Config.viewer_url+"/script/library/classes/Elements/Maps.js",Config.viewer_url+"/script/library/classes/Elements/TextBlock.js",Config.viewer_url+"/script/library/classes/Elements/Dialog.js",Config.viewer_url+"/script/library/classes/Elements/IMTimeline.js",Config.viewer_url+"/script/library/classes/Elements/NavigationButtons.js",Config.viewer_url+"/script/library/classes/CustomApi.js",Config.viewer_url+"/script/library/classes/Models/ActionModel.js",Config.viewer_url+"/script/library/classes/Models/StyleModel.js",Config.viewer_url+"/script/library/classes/Video/SoundCloud.js",Config.viewer_url+"/script/library/classes/TransparentOverlay.js",Config.viewer_url+"/script/library/classes/Elements/ImList.js",Config.viewer_url+"/script/library/classes/Models/ColorModel.js",Config.viewer_url+"/script/library/classes/Elements/DynamicGrid.js",Config.viewer_url+"/script/library/classes/Core/Search.js",Config.viewer_url+"/script/library/classes/Core/Parser.js",Config.viewer_url+"/script/library/classes/events/Events.js",Config.viewer_url+"/script/library/classes/events/PageEvents.js",Config.viewer_url+"/script/Assets.js",Config.viewer_url+"/languages/"+("undefined"!=typeof Config.locale?Config.locale:"en_gb")+".js",Config.viewer_url+"/themes/"+("undefined"!=typeof Config.theme?Config.theme:"basic")+"/Assets.js"];1==w.request.getParam("imeditor")&&c.push(Config.viewer_url+"/script/library/classes/Core/Editor.js"),Loader.loadJs(c,a,function(a,c){b.length>0&&b.css("width",100*c+"%")})}function j(a){Assets.sources.length>0?Loader.loadJs(Assets.sources,a):a()}function k(a){try{1==Config.options.has_personalization&&(Config.options.magazine_api?$.ajax({url:Config.options.magazine_api,data:Config.getParams,success:function(a){Magazine.api=a}}):Magazine.api=Magazine.request.getParams()),a()}catch(a){Console.log(a,"Load custom api")}}function l(){k(function(){m(function(){try{setTimeout(function(){w.hideSplashScreen(),!Config.is_screenshot&&Config.is_preview&&c()},1e3),!Config.is_screenshot&&Config.options.has_cookie_check&&d();for(var a in y)"function"==typeof y[a].onMagazineReady&&($(window).off("resize",t),y[a].onMagazineReady())}catch(a){Console.error(a,"On magazine ready")}})})}function m(a){try{C=new Api(w.id,w.isSandbox),n(a)}catch(a){Console.error(a,"Load api")}}function n(a){C.getFonts(function(a){try{if(null!=typeof a&&"undefined"!=typeof a.fonts&&a.fonts.length>0){var b=[];for(var c in a.fonts)if("webfonts"==a.fonts[c].webfont){var d=a.fonts[c].family;null===a.fonts[c].weight&&null===a.fonts[c].style||(d=d+":"+(null!==a.fonts[c].weight?a.fonts[c].weight:"")+(null!==a.fonts[c].style?a.fonts[c].style:"")),b.push(d)}b.length>0&&Loader.loadCss("//fonts.googleapis.com/css?family="+b.join("|"))}}catch(a){Console.error(a,"Load fonts")}});try{var b=w.request.getParam("impr");Config.options.has_editions_hidden||b||!Magazine.device.isOnline?s(a):C.getEditions({done:function(b){b.editions.length>1&&(w.editions=b.editions),s(a)},fail:function(b){s(a)}})}catch(a){Console.error(a,"Check page restrictions")}}function o(a,b){Loader.loadPageCss(a,function(){b()}),w.device.isIE8&&8===document.documentMode&&Loader.loadCss(Config.viewer_url+"/css/compiled/ie8.css")}function p(a){Loader.loadCss(Config.is_preview?Config.style_url:Config.magazine_url+"/css/custom.css",function(){Magazine.device.browser===DeviceBrowser.FIREFOX?setTimeout(function(){a()},Config.is_preview?1e3:500):a()})}function q(a,b){a||(a="default");for(var c=[],d=0;d0&&(b.pages[parseInt(h)-1].restrictions=g),d.push(b.pages[parseInt(h)-1])}}d.length>0&&(b.pages=d)}if(Config.getParams&&(Config.getParams.tag||Config.getParams.user&&Config.getParams.user.industry)&&!Config.is_screenshot&&(b.pages=q(Config.getParams.user&&Config.getParams.user.industry?Config.getParams.user.industry:Config.getParams.tag,b.pages)),r(b.options.transition),!(b.pages.length>0))throw"No pages available";for(var i=new Array,j=0;j=Assets.maxWidth)){if(a.screen.width>=Assets.maxWidth&&(b=!0),$.extend(w.pages,v(a)),w.isFramed!=b)if(b){w.container.addClass("framed");var c=-(Assets.maxWidth/2),d=-(Assets.maxHeight/2);a.isIE8||(c-=10,d-=10),w.container.css({height:Assets.maxHeight,width:Assets.maxWidth,marginLeft:c,marginTop:d}),"left"==Assets.navigationBar.align[a.size]||"right"==Assets.navigationBar.align[a.size]?(w.pages.width=Assets.maxWidth,Assets.navigationBar.size[a.size][2]||(w.pages.width-=Assets.navigationBar.size[a.size][0]),w.pages.height=Assets.maxHeight):(w.pages.width=Assets.maxWidth,w.pages.height=Assets.maxHeight,Assets.navigationBar.size[a.size][2]||(w.pages.height-=Assets.navigationBar.size[a.size][1])),w.pages.offset=w.container.offset()}else w.pages.offset={top:0,left:0},w.container.removeClass("framed"),w.container.attr("style","");null!=z&&z.onResizeHandler(a),null!=A&&A.onResizeHandler(a),null!=w.popupContainer&&w.popupContainer.isVisible()&&w.popupContainer.onResizeHandler(a),w.pageContainer.width(w.pages.width),w.pageContainer.height(w.pages.height),w.isFramed=b;for(var e in y)"function"==typeof y[e].onResizeHandler&&y[e].onResizeHandler(a);w.trigger("resize",[a])}},this.onPageChangeHandler=function(a,b){this.currentPage=b,A.onPageChangeHandler(a,b),null!=B&&B.onPageChangeHandler(a,b);for(var c in y)"function"==typeof y[c].onPageChangeHandler&&y[c].onPageChangeHandler(a,b)},this.onSwitchSize=function(a,b){null!=z&&z.onSwitchSize(a,b),null!=A&&A.onSwitchSize(a,b),null!=B&&B.onSwitchSize(a,b);for(var c in y)"function"==typeof y[c].onSwitchSize&&y[c].onSwitchSize(a,b)},this.onSwitchedSize=function(){w.hideSplashScreen()},this.showPopupScreen=function(a,b,c){var d=new Popup;return"undefined"!=typeof c&&d.setData(c),d.onShow=function(a){"function"==typeof b.ready&&b.ready(a)},d.setScreen(a,function(a){a&&w.popupContainer.show(d)},b),d},this.registClass=function(a){y.push(a)},this.unregistClass=function(a){for(var b in y)y[b]===a&&y.splice(b,1)},this.lastPageAnimationSize={}}function imIncludeJs(a,b,c,d){var e=document.getElementsByTagName("head")[0],f=document.createElement("script");f.type="text/javascript",c&&(f.id=c),"development"===Config.environment&&a.indexOf("&_=")===-1&&(a+=a.indexOf("?")===-1?"?_=":"&_=",a+=(new Date).getTime()),f.src=a,f.onerror=function(){Loader.retry>0&&(Loader.retry--,imIncludeJs(a,b))},jQuery.isFunction(b)&&(f.onreadystatechange=b,f.onload=b),void 0===d?e.appendChild(f):d.appendChild(f)}function Tracker(){var a=[],b=!1;this.piwikScope=["","visit","visit","page"],this.pushTracker=function(b,c){a.push({tracker:b,type:c})},this.getTrackers=function(){return a},this.disable=function(){b=!0},this.trackOutbound=function(a,b,c,d){try{if(Magazine.options.utm_code){var e=Magazine.options.utm_code;if(e.indexOf("?")!==-1&&(e=e.slice(e.indexOf("?")+1)),a){var f=a.getAttribute("href");if(f.indexOf("utm")===-1){f.indexOf("?")===-1&&(e="?"+e);var g=f.indexOf("#");g!==-1?((f=f.split("#")).splice(1,0,e+"#"),f=f.join("")):f+=e}a.setAttribute("href",f)}}}catch(a){}this.trackEvent("outbound",c,d||a.getAttribute("href"))},this.trackEvent=function(c,d,e,f,g){if(!b&&0!=a.length)for(var h in a){var i=a[h];switch(i.type){case TrackerType.OMNITURE:i.tracker.trackEvent(c,d,e,f,g);break;case TrackerType.GOOGLE:var j=["_trackEvent"],k=["im._trackEvent"];for(var h in arguments)j.push(arguments[h]),k.push(arguments[h]);Console.log("TrackEvent GOOGLE: "+j),Config.has_tracker?window[i.tracker].push(j,k):window[i.tracker].push(k);break;case TrackerType.PIWIK:try{i.tracker.trackEvent(c,d,e,f)}catch(a){Console.error("Error tracking piwik")}break;case TrackerType.GTM:var j={};j.instantmagazine={category:c,action:d,label:e},j.event="instantmagazine-"+c,window[i.tracker].push(j)}}},this.setCustomVar=function(c,d,e,f){if(!b&&0!=a.length)for(var g in a){var h=a[g];switch(h.type){case TrackerType.GOOGLE:window[h.tracker].push(["im._setCustomVar",c,d,e,f]);break;case TrackerType.PIWIK:h.tracker.setCustomVariable(c,d,e,this.piwikScope[f])}}},this.trackGoal=function(){b||0==a.length},this.trackPageView=function(c){if(!b&&0!=a.length){var d=window.location;for(var e in a){var f=a[e];switch(f.type){case TrackerType.OMNITURE:f.tracker.trackPageView(c);break;case TrackerType.GOOGLE:Console.log("GOOGLE: "+d);try{Config.has_tracker?window[f.tracker].push(["_trackPageview",d.pathname+d.search+d.hash],["im._trackPageview",d.pathname+d.search+d.hash]):window[f.tracker].push(["im._trackPageview",d.pathname+d.search+d.hash])}catch(a){}break;case TrackerType.PIWIK:Console.log("PIWIK: "+d);try{c&&f.tracker.setCustomVariable(3,"page_id",c.id,"page"),f.tracker.setCustomUrl(d.pathname+d.hash),f.tracker.trackPageView(document.title)}catch(a){}break;case TrackerType.GTM:var g={};g.instantmagazine={pagetitle:c?c.title:document.title,pageurl:d.pathname+d.hash},g.event="instantmagazine-contentview",window[f.tracker].push(g)}}try{"undefined"!=typeof window.$mcGoal&&window.$mcGoal.processEvent(document.title)}catch(a){}}}}function isNumber(a){return!isNaN(parseFloat(a))&&isFinite(a)}function trim(a){return a.trim?a.trim():a.replace(/^\s*|\s*$/g,"")}function OmnitureTracker(a){"use strict";this.setPageName=function(a){this.page=a;for(var b=document.getElementsByTagName("meta"),c=0;c0&&b-1 in a))}function d(a,b,c){if(ea.isFunction(b))return ea.grep(a,function(a,d){return!!b.call(a,d,a)!==c});if(b.nodeType)return ea.grep(a,function(a){return a===b!==c});if("string"==typeof b){if(ma.test(b))return ea.filter(b,a,c);b=ea.filter(b,a)}return ea.grep(a,function(a){return ea.inArray(a,b)>=0!==c})}function e(a,b){do a=a[b];while(a&&1!==a.nodeType);return a}function f(a){var b=ua[a]={};return ea.each(a.match(ta)||[],function(a,c){b[c]=!0}),b}function g(){oa.addEventListener?(oa.removeEventListener("DOMContentLoaded",h,!1),a.removeEventListener("load",h,!1)):(oa.detachEvent("onreadystatechange",h),a.detachEvent("onload",h))}function h(){(oa.addEventListener||"load"===event.type||"complete"===oa.readyState)&&(g(),ea.ready())}function i(a,b,c){if(void 0===c&&1===a.nodeType){var d="data-"+b.replace(za,"-$1").toLowerCase();if(c=a.getAttribute(d),"string"==typeof c){try{c="true"===c||"false"!==c&&("null"===c?null:+c+""===c?+c:ya.test(c)?ea.parseJSON(c):c)}catch(a){}ea.data(a,b,c)}else c=void 0}return c}function j(a){var b;for(b in a)if(("data"!==b||!ea.isEmptyObject(a[b]))&&"toJSON"!==b)return!1;return!0}function k(a,b,c,d){if(ea.acceptData(a)){var e,f,g=ea.expando,h=a.nodeType,i=h?ea.cache:a,j=h?a[g]:a[g]&&g;if(j&&i[j]&&(d||i[j].data)||void 0!==c||"string"!=typeof b)return j||(j=h?a[g]=W.pop()||ea.guid++:g),i[j]||(i[j]=h?{}:{toJSON:ea.noop}),("object"==typeof b||"function"==typeof b)&&(d?i[j]=ea.extend(i[j],b):i[j].data=ea.extend(i[j].data,b)),f=i[j],d||(f.data||(f.data={}),f=f.data),void 0!==c&&(f[ea.camelCase(b)]=c),"string"==typeof b?(e=f[b],null==e&&(e=f[ea.camelCase(b)])):e=f,e}}function l(a,b,c){if(ea.acceptData(a)){var d,e,f=a.nodeType,g=f?ea.cache:a,h=f?a[ea.expando]:ea.expando;if(g[h]){if(b&&(d=c?g[h]:g[h].data)){ea.isArray(b)?b=b.concat(ea.map(b,ea.camelCase)):b in d?b=[b]:(b=ea.camelCase(b),b=b in d?[b]:b.split(" ")),e=b.length;for(;e--;)delete d[b[e]];if(c?!j(d):!ea.isEmptyObject(d))return}(c||(delete g[h].data,j(g[h])))&&(f?ea.cleanData([a],!0):ca.deleteExpando||g!=g.window?delete g[h]:g[h]=null)}}}function m(){return!0}function n(){return!1}function o(){try{return oa.activeElement}catch(a){}}function p(a){var b=Ka.split("|"),c=a.createDocumentFragment();if(c.createElement)for(;b.length;)c.createElement(b.pop());return c}function q(a,b){var c,d,e=0,f=typeof a.getElementsByTagName!==xa?a.getElementsByTagName(b||"*"):typeof a.querySelectorAll!==xa?a.querySelectorAll(b||"*"):void 0;if(!f)for(f=[],c=a.childNodes||a;null!=(d=c[e]);e++)!b||ea.nodeName(d,b)?f.push(d):ea.merge(f,q(d,b));return void 0===b||b&&ea.nodeName(a,b)?ea.merge([a],f):f}function r(a){Ea.test(a.type)&&(a.defaultChecked=a.checked)}function s(a,b){return ea.nodeName(a,"table")&&ea.nodeName(11!==b.nodeType?b:b.firstChild,"tr")?a.getElementsByTagName("tbody")[0]||a.appendChild(a.ownerDocument.createElement("tbody")):a}function t(a){return a.type=(null!==ea.find.attr(a,"type"))+"/"+a.type,a}function u(a){var b=Va.exec(a.type);return b?a.type=b[1]:a.removeAttribute("type"),a}function v(a,b){for(var c,d=0;null!=(c=a[d]);d++)ea._data(c,"globalEval",!b||ea._data(b[d],"globalEval"))}function w(a,b){if(1===b.nodeType&&ea.hasData(a)){var c,d,e,f=ea._data(a),g=ea._data(b,f),h=f.events;if(h){delete g.handle,g.events={};for(c in h)for(d=0,e=h[c].length;e>d;d++)ea.event.add(b,c,h[c][d])}g.data&&(g.data=ea.extend({},g.data))}}function x(a,b){var c,d,e;if(1===b.nodeType){if(c=b.nodeName.toLowerCase(),!ca.noCloneEvent&&b[ea.expando]){e=ea._data(b);for(d in e.events)ea.removeEvent(b,d,e.handle);b.removeAttribute(ea.expando)}"script"===c&&b.text!==a.text?(t(b).text=a.text,u(b)):"object"===c?(b.parentNode&&(b.outerHTML=a.outerHTML),ca.html5Clone&&a.innerHTML&&!ea.trim(b.innerHTML)&&(b.innerHTML=a.innerHTML)):"input"===c&&Ea.test(a.type)?(b.defaultChecked=b.checked=a.checked,b.value!==a.value&&(b.value=a.value)):"option"===c?b.defaultSelected=b.selected=a.defaultSelected:("input"===c||"textarea"===c)&&(b.defaultValue=a.defaultValue)}}function y(b,c){var d,e=ea(c.createElement(b)).appendTo(c.body),f=a.getDefaultComputedStyle&&(d=a.getDefaultComputedStyle(e[0]))?d.display:ea.css(e[0],"display");return e.detach(),f}function z(a){var b=oa,c=_a[a];return c||(c=y(a,b),"none"!==c&&c||($a=($a||ea("