!function(){function t(t,e){var i;try{i=t.getSelection().getRanges()[0]}catch(t){return null}return i.shrink(CKEDITOR.SHRINK_TEXT),t.elementPath(i.getCommonAncestor()).contains(e,1)}function e(e,r){var n=e.lang.liststyle;if("bulletedListStyle"==r)return{title:n.bulletedTitle,minWidth:300,minHeight:50,contents:[{id:"info",accessKey:"I",elements:[{type:"select",label:n.type,id:"type",align:"center",style:"width:150px",items:[[n.notset,""],[n.circle,"circle"],[n.disc,"disc"],[n.square,"square"]],setup:function(t){t=t.getStyle("list-style-type")||l[t.getAttribute("type")]||t.getAttribute("type")||"",this.setValue(t)},commit:function(t){var e=this.getValue();e?t.setStyle("list-style-type",e):t.removeStyle("list-style-type")}}]}],onShow:function(){var e=this.getParentEditor();(e=t(e,"ul"))&&this.setupContent(e)},onOk:function(){var e=this.getParentEditor();(e=t(e,"ul"))&&this.commitContent(e)}};if("numberedListStyle"==r){var s=[[n.notset,""],[n.lowerRoman,"lower-roman"],[n.upperRoman,"upper-roman"],[n.lowerAlpha,"lower-alpha"],[n.upperAlpha,"upper-alpha"],[n.decimal,"decimal"]];return{title:n.numberedTitle,minWidth:300,minHeight:50,contents:[{id:"info",accessKey:"I",elements:[{type:"hbox",widths:["25%","75%"],children:[{label:n.start,type:"text",id:"start",validate:CKEDITOR.dialog.validate.integer(n.validateStartNumber),setup:function(t){t=t.getFirst(i).getAttribute("value")||t.getAttribute("start")||1,this.setValue(t)},commit:function(t){var e=t.getFirst(i),l=e.getAttribute("value")||t.getAttribute("start")||1;t.getFirst(i).removeAttribute("value");var r=parseInt(this.getValue(),10);for(isNaN(r)?t.removeAttribute("start"):t.setAttribute("start",r),t=e,e=l,r=isNaN(r)?1:r;(t=t.getNext(i))&&e++;)t.getAttribute("value")==e&&t.setAttribute("value",r+e-l)}},{type:"select",label:n.type,id:"type",style:"width: 100%;",items:s,setup:function(t){t=t.getStyle("list-style-type")||l[t.getAttribute("type")]||t.getAttribute("type")||"",this.setValue(t)},commit:function(t){var e=this.getValue();e?t.setStyle("list-style-type",e):t.removeStyle("list-style-type")}}]}]}],onShow:function(){var e=this.getParentEditor();(e=t(e,"ol"))&&this.setupContent(e)},onOk:function(){var e=this.getParentEditor();(e=t(e,"ol"))&&this.commitContent(e)}}}}var i=function(t){return t.type==CKEDITOR.NODE_ELEMENT&&t.is("li")},l={a:"lower-alpha",A:"upper-alpha",i:"lower-roman",I:"upper-roman",1:"decimal",disc:"disc",circle:"circle",square:"square"};CKEDITOR.dialog.add("numberedListStyle",(function(t){return e(t,"numberedListStyle")})),CKEDITOR.dialog.add("bulletedListStyle",(function(t){return e(t,"bulletedListStyle")}))}();