Changeset 201
- Timestamp:
- 2007-03-09 20:07:16 (3 years ago)
- Location:
- FCKeditor/trunk
- Files:
-
- 4 modified
-
editor/_source/classes/fckelementpath.js (modified) (2 diffs)
-
editor/_source/internals/fck.js (modified) (1 diff)
-
editor/_source/internals/fcklistslib.js (modified) (1 diff)
-
_whatsnew.html (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
FCKeditor/trunk/editor/_source/classes/fckelementpath.js
r132 r201 42 42 var sElementName = e.nodeName.toLowerCase() ; 43 43 44 if ( !eBlockLimit && !eBlock && FCKListsLib.PathBlockElements[ sElementName ] != null ) 45 eBlock = e ; 44 if ( !eBlockLimit ) 45 { 46 if ( !eBlock && FCKListsLib.PathBlockElements[ sElementName ] != null ) 47 eBlock = e ; 46 48 47 // TODO: Review the Regex and move it to the RegexLib.48 if ( !eBlockLimit && (/^(?:body|td|th|caption|form)$/).test( sElementName ) )49 eBlockLimit = e ;49 if ( FCKListsLib.PathBlockLimitElements[ sElementName ] != null ) 50 eBlockLimit = e ; 51 } 50 52 51 53 aElements.push( e ) ; 52 54 53 if ( sElementName == ' BODY' )55 if ( sElementName == 'body' ) 54 56 break ; 55 57 } … … 62 64 } 63 65 66 -
FCKeditor/trunk/editor/_source/internals/fck.js
r194 r201 89 89 this.EditingArea = new FCKEditingArea( document.getElementById( 'xEditingArea' ) ) ; 90 90 this.EditingArea.FFSpellChecker = false ; 91 92 // Final setup of the lists lib. 93 FCKListsLib.Setup() ; 91 94 92 95 // Set the editor's startup contents -
FCKeditor/trunk/editor/_source/internals/fcklistslib.js
r188 r201 34 34 NonEmptyBlockElements : { p:1,div:1,h1:1,h2:1,h3:1,h4:1,h5:1,h6:1,address:1,pre:1,ol:1,ul:1,li:1,td:1,th:1 }, 35 35 36 // Elements that may be considered the "Block boundary" in an element path.37 PathBlockElements : { address:1,blockquote:1,div:1,dl:1,h1:1,h2:1,h3:1,h4:1,h5:1,h6:1,p:1,pre:1,ol:1,ul:1,li:1,dt:1,de:1 },38 39 36 // Inline elements which MUST have child nodes. 40 37 InlineChildReqElements : { abbr:1,acronym:1,b:1,bdo:1,big:1,cite:1,code:1,del:1,dfn:1,em:1,font:1,i:1,ins:1,label:1,kbd:1,q:1,samp:1,small:1,span:1,strong:1,sub:1,sup:1,tt:1,u:1,'var':1 }, 41 38 42 39 // Elements marked as empty "Empty" in the XHTML DTD. 43 EmptyElements : { base:1,meta:1,link:1,hr:1,br:1,param:1,img:1,area:1,input:1 } 40 EmptyElements : { base:1,meta:1,link:1,hr:1,br:1,param:1,img:1,area:1,input:1 }, 41 42 // Elements that may be considered the "Block boundary" in an element path. 43 PathBlockElements : { address:1,blockquote:1,dl:1,h1:1,h2:1,h3:1,h4:1,h5:1,h6:1,p:1,pre:1,ol:1,ul:1,li:1,dt:1,de:1 }, 44 45 // Elements that may be considered the "Block limit" in an element path. 46 PathBlockLimitElements : { body:1,td:1,th:1,caption:1,form:1 }, 47 48 // Final setup of FCKListsLib once the editor is loaded (at FCK.StartEditor). 49 // TODO: For v3, there should be a generic way to register to the editor 50 // startup event, so this function would not be needed to be defined here, not 51 // even be called at FCK.StartEditor. 52 Setup : function() 53 { 54 // <div> is considered a block element only if EnterMode=div, otherwise it is a block limit. 55 if ( FCKConfig.EnterMode == 'div' ) 56 this.PathBlockElements.div = 1 ; 57 else 58 this.PathBlockLimitElements.div = 1 ; 59 } 44 60 } ; -
FCKeditor/trunk/_whatsnew.html
r197 r201 101 101 <li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/211">#211</a>] Some invalid 102 102 inputs, like "<p>" where making the caret disappear in Firefox.</li> 103 <li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/99">#99</a>] The <div> 104 element is now considered a block container if EnterMode=p|br. It acts like a simple 105 block only if EnterMode=div.</li> 103 106 </ul> 104 107 <h3>