You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
tt-rss/lib/dijit/layout/ContentPane.js

2 lines
6.8 KiB
JavaScript

//>>built
define("dijit/layout/ContentPane",["dojo/_base/kernel","dojo/_base/lang","../_Widget","../_Container","./_ContentPaneResizeMixin","dojo/string","dojo/html","dojo/_base/array","dojo/_base/declare","dojo/_base/Deferred","dojo/dom","dojo/dom-attr","dojo/dom-construct","dojo/_base/xhr","dojo/i18n","dojo/when","dojo/i18n!../nls/loading"],function(_1,_2,_3,_4,_5,_6,_7,_8,_9,_a,_b,_c,_d,_e,_f,_10){return _9("dijit.layout.ContentPane",[_3,_4,_5],{href:"",content:"",extractContent:false,parseOnLoad:true,parserScope:_1._scopeName,preventCache:false,preload:false,refreshOnShow:false,loadingMessage:"<span class='dijitContentPaneLoading'><span class='dijitInline dijitIconLoading'></span>${loadingState}</span>",errorMessage:"<span class='dijitContentPaneError'><span class='dijitInline dijitIconError'></span>${errorState}</span>",isLoaded:false,baseClass:"dijitContentPane",ioArgs:{},onLoadDeferred:null,_setTitleAttr:null,stopParser:true,template:false,markupFactory:function(_11,_12,_13){var _14=new _13(_11,_12);return !_14.href&&_14._contentSetter&&_14._contentSetter.parseDeferred&&!_14._contentSetter.parseDeferred.isFulfilled()?_14._contentSetter.parseDeferred.then(function(){return _14;}):_14;},create:function(_15,_16){if((!_15||!_15.template)&&_16&&!("href" in _15)&&!("content" in _15)){_16=_b.byId(_16);var df=_16.ownerDocument.createDocumentFragment();while(_16.firstChild){df.appendChild(_16.firstChild);}_15=_2.delegate(_15,{content:df});}this.inherited(arguments,[_15,_16]);},postMixInProperties:function(){this.inherited(arguments);var _17=_f.getLocalization("dijit","loading",this.lang);this.loadingMessage=_6.substitute(this.loadingMessage,_17);this.errorMessage=_6.substitute(this.errorMessage,_17);},buildRendering:function(){this.inherited(arguments);if(!this.containerNode){this.containerNode=this.domNode;}this.domNode.removeAttribute("title");},startup:function(){this.inherited(arguments);if(this._contentSetter){_8.forEach(this._contentSetter.parseResults,function(obj){if(!obj._started&&!obj._destroyed&&_2.isFunction(obj.startup)){obj.startup();obj._started=true;}},this);}},_startChildren:function(){_8.forEach(this.getChildren(),function(obj){if(!obj._started&&!obj._destroyed&&_2.isFunction(obj.startup)){obj.startup();obj._started=true;}});if(this._contentSetter){_8.forEach(this._contentSetter.parseResults,function(obj){if(!obj._started&&!obj._destroyed&&_2.isFunction(obj.startup)){obj.startup();obj._started=true;}},this);}},setHref:function(_18){_1.deprecated("dijit.layout.ContentPane.setHref() is deprecated. Use set('href', ...) instead.","","2.0");return this.set("href",_18);},_setHrefAttr:function(_19){this.cancel();this.onLoadDeferred=new _a(_2.hitch(this,"cancel"));this.onLoadDeferred.then(_2.hitch(this,"onLoad"));this._set("href",_19);if(this.preload||(this._created&&this._isShown())){this._load();}else{this._hrefChanged=true;}return this.onLoadDeferred;},setContent:function(_1a){_1.deprecated("dijit.layout.ContentPane.setContent() is deprecated. Use set('content', ...) instead.","","2.0");this.set("content",_1a);},_setContentAttr:function(_1b){this._set("href","");this.cancel();this.onLoadDeferred=new _a(_2.hitch(this,"cancel"));if(this._created){this.onLoadDeferred.then(_2.hitch(this,"onLoad"));}this._setContent(_1b||"");this._isDownloaded=false;return this.onLoadDeferred;},_getContentAttr:function(){return this.containerNode.innerHTML;},cancel:function(){if(this._xhrDfd&&(this._xhrDfd.fired==-1)){this._xhrDfd.cancel();}delete this._xhrDfd;this.onLoadDeferred=null;},destroy:function(){this.cancel();this.inherited(arguments);},destroyRecursive:function(_1c){if(this._beingDestroyed){return;}this.inherited(arguments);},_onShow:function(){this.inherited(arguments);if(this.href){if(!this._xhrDfd&&(!this.isLoaded||this._hrefChanged||this.refreshOnShow)){return this.refresh();}}},refresh:function(){this.cancel();this.onLoadDeferred=new _a(_2.hitch(this,"cancel"));this.onLoadDeferred.then(_2.hitch(this,"onLoad"));this._load();return this.onLoadDeferred;},_load:function(){this._setContent(this.onDownloadStart(),true);var _1d=th