Lines Matching refs:hasAttribute

75 f&&f.is("textarea","input")&&(a=!0);if(!a&&f&&"undefined"!=typeof f.$.isContentEditable)return!(f.$.isContentEditable||f.data("cke-editable"));for(;f;){if(f.data("cke-editable"))return!1;if(f.hasAttribute("contenteditable"))return"false"==f.getAttribute("contenteditable");f=f.getParent()}return!0}}),CKEDITOR.dom.window=function(a){CKEDITOR.dom.domObject.call(this,a)},CKEDITOR.dom.window.prototype=new CKEDITOR.dom.domObject,CKEDITOR.tools.extend(CKEDITOR.dom.window.prototype,{focus:function(){this.$.focus()},
97 for(var b=0;b<arguments.length;b++)if(arguments[b]==a)return!0;return!1},isEditable:function(a){var b=this.getName();return this.isReadOnly()||"none"==this.getComputedStyle("display")||"hidden"==this.getComputedStyle("visibility")||CKEDITOR.dtd.$nonEditable[b]||CKEDITOR.dtd.$empty[b]||this.is("a")&&(this.data("cke-saved-name")||this.hasAttribute("name"))&&!this.getChildCount()?!1:!1!==a?(a=CKEDITOR.dtd[b]||CKEDITOR.dtd.span,!(!a||!a["#"])):!0},isIdentical:function(a){var b=this.clone(0,1);a=a.clone(0,
101 function(){var a=this.$.attributes,b=a.length,c={"data-cke-expando":1,_moz_dirty:1};return 0<b&&(2<b||!c[a[0].nodeName]||2==b&&!c[a[1].nodeName])},hasAttribute:function(){function a(b){var d=this.$.attributes.getNamedItem(b);if("input"==this.getName())switch(b){case "class":return 0<this.$.className.length;case "checked":return!!this.$.checked;case "value":return b=this.getAttribute("type"),"checkbox"==b||"radio"==b?"on"!=this.$.value:!!this.$.value}return d?d.specified:!1}return CKEDITOR.env.ie?
115 getFrameDocument:function(){var a=this.$;try{a.contentWindow.document}catch(b){a.src=a.src}return a&&new CKEDITOR.dom.document(a.contentWindow.document)},copyAttributes:function(a,b){var c=this.$.attributes;b=b||{};for(var g=0;g<c.length;g++){var e=c[g],f=e.nodeName.toLowerCase(),k;if(!(f in b))if("checked"==f&&(k=this.getAttribute(f)))a.setAttribute(f,k);else if(!CKEDITOR.env.ie||this.hasAttribute(f))k=this.getAttribute(f),null===k&&(k=e.nodeValue),a.setAttribute(f,k)}""!==this.$.style.cssText&&
129 g=g.getNext(b),c=c.isBlockBoundary()&&(!g||g.type==CKEDITOR.NODE_ELEMENT&&g.isBlockBoundary()));return!!(a^c)}};CKEDITOR.dom.walker.temp=function(a){return function(b){b.type!=CKEDITOR.NODE_ELEMENT&&(b=b.getParent());b=b&&b.hasAttribute("data-cke-temp");return!!(a^b)}};var e=/^[\t\r\n ]*(?:&nbsp;|\xa0)$/,l=CKEDITOR.dom.walker.whitespaces(),k=CKEDITOR.dom.walker.bookmark(),d=CKEDITOR.dom.walker.temp(),h=function(a){return k(a)||l(a)||a.type==CKEDITOR.NODE_ELEMENT&&a.is(CKEDITOR.dtd.$inline)&&!a.is(CKEDITOR.dtd.$empty)};
148 this.setStart(c,d);if(e){this.collapse(!0);return}}c=this.endContainer;d=this.endOffset;b||e||!c||c.type!=CKEDITOR.NODE_TEXT||(d?(d>=c.getLength()||c.split(d),d=c.getIndex()+1):d=c.getIndex(),c=c.getParent(),this.setEnd(c,d))},enlarge:function(a,b){function c(a){return a&&a.type==CKEDITOR.NODE_ELEMENT&&a.hasAttribute("contenteditable")?null:a}var d=new RegExp(/[^\s\ufeff]/);switch(a){case CKEDITOR.ENLARGE_INLINE:var e=1;case CKEDITOR.ENLARGE_ELEMENT:var f=function(a,b){var c=new CKEDITOR.dom.range(h);
158 var y;f.guard=function(b,c){if(e&&A(b)||z(b))return!0;if(a==CKEDITOR.SHRINK_ELEMENT&&b.type==CKEDITOR.NODE_TEXT||c&&b.equals(y)||!1===d&&b.type==CKEDITOR.NODE_ELEMENT&&b.isBlockBoundary()||b.type==CKEDITOR.NODE_ELEMENT&&b.hasAttribute("contenteditable"))return!1;c||b.type!=CKEDITOR.NODE_ELEMENT||(y=b);return!0};c&&(m=f[a==CKEDITOR.SHRINK_ELEMENT?"lastForward":"next"]())&&this.setStartAt(m,b?CKEDITOR.POSITION_AFTER_START:CKEDITOR.POSITION_BEFORE_START);r&&(f.reset(),(f=f[a==CKEDITOR.SHRINK_ELEMENT?
247 b){a.on("customConfigLoaded",function(){if(b){if(b.on)for(var c in b.on)a.on(c,b.on[c]);CKEDITOR.tools.extend(a.config,b,!0);delete a.config.on}c=a.config;a.readOnly=c.readOnly?!0:a.elementMode==CKEDITOR.ELEMENT_MODE_INLINE?a.element.is("textarea")?a.element.hasAttribute("disabled")||a.element.hasAttribute("readonly"):a.element.isReadOnly():a.elementMode==CKEDITOR.ELEMENT_MODE_REPLACE?a.element.hasAttribute("disabled")||a.element.hasAttribute("readonly"):!1;a.blockless=a.elementMode==CKEDITOR.ELEMENT_MODE_INLINE?
322 e,l,k){if(!CKEDITOR.env.isCompatible)return null;a=CKEDITOR.dom.element.get(a);if(a.getEditor())throw'The editor instance "'+a.getEditor().name+'" is already attached to the provided element.';var d=new CKEDITOR.editor(e,a,k);k==CKEDITOR.ELEMENT_MODE_REPLACE&&(a.setStyle("visibility","hidden"),d._.required=a.hasAttribute("required"),a.removeAttribute("required"));l&&d.setData(l,null,!0);d.on("loaded",function(){b(d);k==CKEDITOR.ELEMENT_MODE_REPLACE&&d.config.autoUpdateElement&&a.$.form&&d._attachToForm();
363 this._.editable;if(b&&a)return 0;arguments.length&&(b=this._.editable=a?a instanceof CKEDITOR.editable?a:new CKEDITOR.editable(this,a):(b&&b.detach(),null));return b};CKEDITOR.on("instanceLoaded",function(b){var c=b.editor;c.on("insertElement",function(a){a=a.data;a.type==CKEDITOR.NODE_ELEMENT&&(a.is("input")||a.is("textarea"))&&("false"!=a.getAttribute("contentEditable")&&a.data("cke-editable",a.hasAttribute("contenteditable")?"true":"1"),a.setAttribute("contentEditable",!1))});c.on("selectionChange",
373 fixForBody:!1,protectedWhitespaces:!!Q,dontFilter:n.dontFilter,filter:n.editor.activeFilter,enterMode:n.editor.activeEnterMode});I=B.document.createElement("body");I.setHtml(x);Q&&(I.getFirst().remove(),I.getLast().remove());if((Q=B.startPath().block)&&(1!=Q.getChildCount()||!Q.getBogus()))a:{var R;if(1==I.getChildCount()&&a(R=I.getFirst())&&R.is(u)&&!R.hasAttribute("contenteditable")){Q=R.getElementsByTag("*");B=0;for(p=Q.count();B<p;B++)if(G=Q.getItem(B),!G.is(v))break a;R.moveChildren(R.getParent(1));
416 c.selectionChange(1)});c.on("loadSnapshot",function(){var a=CKEDITOR.dom.walker.nodeType(CKEDITOR.NODE_ELEMENT),b=c.editable().getLast(a);b&&b.hasAttribute("data-cke-hidden-sel")&&(b.remove(),CKEDITOR.env.gecko&&(a=c.editable().getFirst(a))&&a.is("br")&&a.getAttribute("_moz_editor_bogus_node")&&a.remove())},null,null,100);c.on("key",function(a){if("wysiwyg"==c.mode){var b=c.getSelection();if(b.isFake){var d=y[a.data.keyCode];if(d)return d({editor:c,selected:b.getSelectedElement(),selection:b,keyEvent:a})}}})});
439 v.getName()?(g(this.root),d.moveToPosition(v,CKEDITOR.POSITION_BEFORE_START)):d.moveToPosition(n,CKEDITOR.POSITION_AFTER_END));x.setStart(d.startContainer.$,d.startOffset);try{x.setEnd(d.endContainer.$,d.endOffset)}catch(w){if(0<=w.toString().indexOf("NS_ERROR_ILLEGAL_VALUE"))d.collapse(1),x.setEnd(d.endContainer.$,d.endOffset);else throw w;}l.addRange(x)}}this.reset();this.root.fire("selectionchange")}}},fake:function(a,b){var c=this.root.editor;void 0===b&&a.hasAttribute("aria-label")&&(b=a.getAttribute("aria-label"));
457 c.append(g)}else b.setHtml(e)}return c||b}function t(a,b){var c=this._.definition,d=c.attributes,c=c.styles,e=r(this)[a.getName()],g=CKEDITOR.tools.isEmpty(d)&&CKEDITOR.tools.isEmpty(c),f;for(f in d)if("class"!=f&&!this._.definition.fullMatch||a.getAttribute(f)==z(f,d[f]))b&&"data-"==f.slice(0,5)||(g=a.hasAttribute(f),a.removeAttribute(f));for(var h in c)this._.definition.fullMatch&&a.getStyle(h)!=z(h,c[h],!0)||(g=g||!!a.getStyle(h),a.removeStyle(h));q(a,e,D[a.getName()]);g&&(this._.definition.alwaysRemoveElement?
460 d&&!c.equals(d)&&d.type==CKEDITOR.NODE_ELEMENT&&d.mergeSiblings())}function u(a,b,c){var d;d=a.element;"*"==d&&(d="span");d=new CKEDITOR.dom.element(d,b);c&&c.copyAttributes(d);d=x(d,a);b.getCustomData("doc_processing_style")&&d.hasAttribute("id")?d.removeAttribute("id"):b.setCustomData("doc_processing_style",1);return d}function x(a,b){var c=b._.definition,d=c.attributes,c=CKEDITOR.style.getStyleText(c);if(d)for(var e in d)a.setAttribute(e,d[e]);c&&a.setAttribute("style",c);return a}function B(a,
607 a,"bidi_processed",1);d=a;for(var e=c.editable();(d=d.getParent())&&!d.equals(e);)if(d.getCustomData("bidi_processed")){a.removeStyle("direction");a.removeAttribute("dir");return}d="useComputedState"in c.config?c.config.useComputedState:1;(d?a.getComputedStyle("direction"):a.getStyle("direction")||a.hasAttribute("dir"))!=b&&(a.removeStyle("direction"),d?(a.removeAttribute("dir"),b!=a.getComputedStyle("direction")&&a.setAttribute("dir",b)):a.setAttribute("dir",b),c.forceNextSelectionCheck())}}function f(a,
751 CKEDITOR.tools,c=a.getAttributes(CKEDITOR.plugins.copyformatting.excludedAttributes),b=b.parseCssText(a.getAttribute("style"),!0,!0);return{element:a.getName(),type:CKEDITOR.STYLE_INLINE,attributes:c,styles:b}},_extractStylesFromElement:function(a,b){var c={},f=[];do if(b.type===CKEDITOR.NODE_ELEMENT&&!b.hasAttribute("data-cke-bookmark")&&(c.element=b,a.copyFormatting.fire("extractFormatting",c,a)&&c.styleDef&&f.push(new CKEDITOR.style(c.styleDef)),b.getName&&-1!==e(CKEDITOR.plugins.copyformatting.breakOnElements,
778 k=(new CKEDITOR.dom.elementPath(a.getTarget(),c.editable())).contains(function(a){return a.hasAttribute("contenteditable")},!0);k&&"false"==k.getAttribute("contenteditable")&&c.getSelection().fake(k)}var k=a.getTarget().getDocument(),d=a.getTarget().getDocument().getDocumentElement(),c=!k.equals(CKEDITOR.document),k=k.getWindow().getScrollPosition(),h=c?a.$.clientX:a.$.pageX||k.x+a.$.clientX,m=c?a.$.clientY:a.$.pageY||k.y+a.$.clientY;CKEDITOR.tools.setTimeout(function(){this.open(d,null,h,m)},CKEDITOR.env.ie?
780 !1!==a.config.browserContextMenuOnCtrl)});a.addCommand("contextMenu",{exec:function(){a.contextMenu.open(a.document.getBody())}});a.setKeystroke(CKEDITOR.SHIFT+121,"contextMenu");a.setKeystroke(CKEDITOR.CTRL+CKEDITOR.SHIFT+121,"contextMenu")}}),function(){function a(a){var b=this.att;a=a&&a.hasAttribute(b)&&a.getAttribute(b)||"";void 0!==a&&this.setValue(a)}function f(){for(var a,b=0;b<arguments.length;b++)if(arguments[b]instanceof CKEDITOR.dom.element){a=arguments[b];break}if(a){var b=this.att,f=
791 B[z],y=0;r=A.data("cke-display-name")?A.data("cke-display-name"):A.data("cke-real-element-type")?A.data("cke-real-element-type"):A.getName();(l=A.hasAttribute("contenteditable")?"true"==A.getAttribute("contenteditable"):l)||A.hasAttribute("contenteditable")||(y=1);for(var D=0;D<k.length;D++){var C=k[D](A,r);if(!1===C){y=1;break}r=C||r}y||(d.unshift(A),f.unshift(r))}d=d.length;for(k=0;k<d;k++)r=f[k],l=a.lang.elementspath.eleTitle.replace(/%1/,r),r=c.output({id:n+k,label:l,text:r,jsTitle:"javascript:void('"+
900 else{for(;!a.hasAttribute||!a.hasAttribute("align")&&!a.getStyle("text-align");){f=a.getParent();if(!f)break;a=f}f=a.getStyle("text-align")||a.getAttribute("align")||""}f&&(f=f.replace(/(?:-(?:moz|webkit)-)?(?:start|auto)/i,""));!f&&b&&(f="rtl"==a.getComputedStyle("direction")?"right":"left");return f}function f(a,b,f){this.editor=a;this.name=b;this.value=f;this.context="p";b=a.config.justifyClasses;var k=a.config.enterMode==CKEDITOR.ENTER_P?"p":"div";if(b){switch(f){case "left":this.cssClassName=
911 c.language_remove=d?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED;d&&(c["language_"+d.getAttribute("lang")]=CKEDITOR.TRISTATE_ON);return c}})},getCurrentLangElement:function(a){var f=a.elementPath();a=f&&f.elements;var b;if(f)for(var c=0;c<a.length;c++)f=a[c],!b&&"span"==f.getName()&&f.hasAttribute("dir")&&f.hasAttribute("lang")&&(b=f);return b}})}(),"use strict",function(){function a(a){return a.replace(/'/g,"\\$\x26")}function f(a){for(var b,c=a.length,d=[],f=0;f<c;f++)b=a.charCodeAt(f),d.push(b);
918 b.isReadOnly())return null;b=CKEDITOR.plugins.link.tryRestoreFakeAnchor(a,b);if(!b&&!(b=CKEDITOR.plugins.link.getSelectedLink(a)))return null;var c={};b.getAttribute("href")&&b.getChildCount()&&(c={link:CKEDITOR.TRISTATE_OFF,unlink:CKEDITOR.TRISTATE_OFF});b&&b.hasAttribute("name")&&(c.anchor=c.removeAnchor=CKEDITOR.TRISTATE_OFF);return c});this.compiledProtectionFunction=c(a)},afterInit:function(a){a.dataProcessor.dataFilter.addRules({elements:{a:function(b){return b.attributes.name?b.children.length?
921 f=c.getRanges(),e=[],g;if(!b&&d&&d.is("a"))return d;for(d=0;d<f.length;d++)if(g=c.getRanges()[d],g.shrink(CKEDITOR.SHRINK_TEXT,!1,{skipBogus:!0}),(g=a.elementPath(g.getCommonAncestor()).contains("a",1))&&b)e.push(g);else if(g)return g;return b?e:null},getEditorAnchors:function(a){for(var b=a.editable(),c=b.isInline()&&!a.plugins.divarea?a.document:b,b=c.getElementsByTag("a"),c=c.getElementsByTag("img"),d=[],f=0,e;e=b.getItem(f++);)(e.data("cke-saved-name")||e.hasAttribute("name"))&&d.push({name:e.data("cke-saved-name")||
931 contextSensitive:1,startDisabled:1,requiredContent:"a[href]",editorFocus:1};CKEDITOR.removeAnchorCommand=function(){};CKEDITOR.removeAnchorCommand.prototype={exec:function(a){var b=a.getSelection(),c=b.createBookmarks(),d;if(b&&(d=b.getSelectedElement())&&(d.getChildCount()?d.is("a"):CKEDITOR.plugins.link.tryRestoreFakeAnchor(a,d)))d.remove(1);else if(d=CKEDITOR.plugins.link.getSelectedLink(a))d.hasAttribute("href")?(d.removeAttributes({name:1,"data-cke-saved-name":1}),d.removeClass("cke_anchor")):
960 !0))&&a.editable.contains(b)){var c=k(b);if("true"==c.getAttribute("contenteditable"))return b;if(c.is(a.triggers))return c}return null}function c(a,b,c){r(a,b);r(a,c);a=b.size.bottom;c=c.size.top;return a&&c?0|(a+c)/2:a||c}function e(a,b,c){return b=b[c?"getPrevious":"getNext"](function(b){return b&&b.type==CKEDITOR.NODE_TEXT&&!Z(b)||n(b)&&!p(b)&&!g(a,b)})}function l(a,b,c){return a>b&&a<c}function k(a,b){if(a.data("cke-editable"))return null;for(b||(a=a.getParent());a&&!a.data("cke-editable");){if(a.hasAttribute("contenteditable"))return a;
971 null}function q(a,b){if(!b)return!1;for(var c=b.getParents(1),d=c.length;d--;)for(var f=a.tabuList.length;f--;)if(c[d].hasAttribute(a.tabuList[f]))return!0;return!1}function v(a,b,c){b=b[c?"getLast":"getFirst"](function(b){return a.isRelevant(b)&&!b.is(fa)});if(!b)return!1;r(a,b);return c?b.size.top>a.mouse.y:b.size.bottom<a.mouse.y}function u(a){var b=a.editable,c=a.mouse,d=a.view,e=a.triggerOffset;z(a);var h=c.y>(a.inInlineMode?d.editable.top+d.editable.height/2:Math.min(d.editable.height,d.pane.height)/
1028 typeof f.startContainer.$.nodeValue&&(d=f.startContainer.getText().length,(d<f.startOffset||d<f.endOffset)&&a.unlockSelection(!1))}},this,null,-10)},k=function(){b?a.config.scayt_inlineModeImmediateMarkup?e():(a.on("blur",function(){setTimeout(c,0)}),a.on("focus",e),a.focusManager.hasFocus&&e()):e();l();var d=a.editable();d.attachListener(d,"mousedown",function(b){b=b.data.getTarget();var c=a.widgets&&a.widgets.getByElement(b);c&&(c.wrapper=b.getAscendant(function(a){return a.hasAttribute("data-cke-widget-wrapper")},
1042 b=b&&b.dataFilter,l=a.addRemoveFormatFilter,k=function(b){if(a.scayt&&(b.hasAttribute(f.options.data_attribute_name)||b.hasAttribute(f.options.problem_grammar_data_attribute)))return!1},d=function(b){var c=!0;a.scayt&&(b.hasAttribute(f.options.data_attribute_name)||b.hasAttribute(f.options.problem_grammar_data_attribute))&&(c=!1);return c};e&&e.push(k);b&&b.addRules({elements:{span:function(a){var b=a.hasClass(f.options.misspelled_word_class)&&a.attributes[f.options.data_attribute_name],c=a.hasClass(f.options.problem_grammar_class)&&
1071 "cke_show_border").replace(/%1/g,"cke_show_borders ");CKEDITOR.addCss(a)},init:function(f){var b=f.addCommand("showborders",a);b.canUndo=!1;!1!==f.config.startupShowBorders&&b.setState(CKEDITOR.TRISTATE_ON);f.on("mode",function(){b.state!=CKEDITOR.TRISTATE_DISABLED&&b.refresh(f)},null,null,100);f.on("contentDom",function(){b.state!=CKEDITOR.TRISTATE_DISABLED&&b.refresh(f)});f.on("removeFormatCleanup",function(a){a=a.data;f.getCommand("showborders").state==CKEDITOR.TRISTATE_ON&&a.is("table")&&(!a.hasAttribute("border")||
1168 b.getItem(0).hasAttribute("data-cke-temp")||b.getItem(0).remove(1),c=!1)})}var c=this.editor,d=a.document,h=d.body,m=d.getElementById("cke_actscrpt");m&&m.parentNode.removeChild(m);(m=d.getElementById("cke_shimscrpt"))&&m.parentNode.removeChild(m);(m=d.getElementById("cke_basetagscrpt"))&&m.parentNode.removeChild(m);h.contentEditable=!0;CKEDITOR.env.ie&&(h.hideFocus=!0,h.disabled=!0,h.removeAttribute("disabled"));delete this._.isLoadingData;this.$=h;d=new CKEDITOR.dom.document(d);this.setup();this.fixInitialSelection();