template.js.base.widget.min.js Maven / Gradle / Ivy
'use strict';(function(c){"function"===typeof define&&define.amd?define(["jquery","./version"],c):c(jQuery)})(function(c){var n=0,m=Array.prototype.slice;c.cleanData=function(a){return function(b){var f,d,e;for(e=0;null!=(d=b[e]);e++)try{(f=c._data(d,"events"))&&f.remove&&c(d).triggerHandler("remove")}catch(g){}a(b)}}(c.cleanData);c.widget=function(a,b,f){var d,e,g,h={},k=a.split(".")[0];a=a.split(".")[1];var l=k+"-"+a;f||(f=b,b=c.Widget);c.isArray(f)&&(f=c.extend.apply(null,[{}].concat(f)));c.expr[":"][l.toLowerCase()]=
function(a){return!!c.data(a,l)};c[k]=c[k]||{};d=c[k][a];e=c[k][a]=function(a,b){if(!this._createWidget)return new e(a,b);arguments.length&&this._createWidget(a,b)};c.extend(e,d,{version:f.version,_proto:c.extend({},f),_childConstructors:[]});g=new b;g.options=c.widget.extend({},g.options);c.each(f,function(a,d){c.isFunction(d)?h[a]=function(){function c(){return b.prototype[a].apply(this,arguments)}function f(c){return b.prototype[a].apply(this,c)}return function(){var a=this._super,b=this._superApply,
e;this._super=c;this._superApply=f;e=d.apply(this,arguments);this._super=a;this._superApply=b;return e}}():h[a]=d});e.prototype=c.widget.extend(g,{widgetEventPrefix:d?g.widgetEventPrefix||a:a},h,{constructor:e,namespace:k,widgetName:a,widgetFullName:l});d?(c.each(d._childConstructors,function(a,b){var d=b.prototype;c.widget(d.namespace+"."+d.widgetName,e,b._proto)}),delete d._childConstructors):b._childConstructors.push(e);c.widget.bridge(a,e);return e};c.widget.extend=function(a){for(var b=m.call(arguments,
1),f=0,d=b.length,e,g;f
© 2015 - 2024 Weber Informatics LLC | Privacy Policy