src/myams/resources/js/ext/tinymce/dev/classes/ui/Path.min.js
changeset 0 f05d7aea098a
child 5 c9c69b13d884
equal deleted inserted replaced
-1:000000000000 0:f05d7aea098a
       
     1 define("tinymce/ui/Path",["tinymce/ui/Widget"],function(a){return a.extend({init:function(c){var b=this;if(!c.delimiter){c.delimiter="\u00BB"}b._super(c);b.addClass("path");b.canFocus=true;b.on("click",function(g){var d,f=g.target;if((d=f.getAttribute("data-index"))){b.fire("select",{value:b.data()[d],index:d})}})},focus:function(){var b=this;b.getEl().firstChild.focus();return b},data:function(c){var b=this;if(typeof c!=="undefined"){b._data=c;b.update();return b}return b._data},update:function(){this.innerHtml(this._getPathHtml())},postRender:function(){var b=this;b._super();b.data(b.settings.data)},renderHtml:function(){var b=this;return('<div id="'+b._id+'" class="'+b.classes()+'">'+b._getPathHtml()+"</div>")},_getPathHtml:function(){var c=this,g=c._data||[],e,b,d="",f=c.classPrefix;for(e=0,b=g.length;e<b;e++){d+=((e>0?'<div class="'+f+'divider" aria-hidden="true"> '+c.settings.delimiter+" </div>":"")+'<div role="button" class="'+f+"path-item"+(e==b-1?" "+f+"last":"")+'" data-index="'+e+'" tabindex="-1" id="'+c._id+"-"+e+'" aria-level="'+e+'">'+g[e].name+"</div>")}if(!d){d='<div class="'+f+'path-item">\u00a0</div>'}return d}})});