Changeset 768

Show
Ignore:
Timestamp:
2007-09-03 01:08:17 (15 months ago)
Author:
fredck
Message:

Small fix for the override detection.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • FCKeditor/branches/features/style/editor/_source/classes/fckstyle.js

    r767 r768  
    316316                        for ( var i = 0 ; i < attribs.length ; i++ ) 
    317317                        { 
    318                                 var attName = attributes[i][0] ; 
     318                                var attName = attribs[i][0] ; 
    319319                                if ( FCKDomTools.HasAttribute( element, attName ) ) 
    320320                                { 
    321                                         var attValue = attributes[i][1] ; 
     321                                        var attValue = attribs[i][1] ; 
    322322 
    323323                                        // Remove the attribute if: 
     
    742742 
    743743                if ( range.CheckIsCollapsed() ) 
     744                { 
     745                        // The following doesn't work. 
     746//                      var collapsedElement = this.BuildElement( range.Window.document ) ; 
     747//                      range.InsertNode( collapsedElement ) ; 
     748//                      range.MoveToNodeContents( collapsedElement ) ; 
     749//                      range.Select() ; 
     750 
     751                        // An idea would be calling a standard execCommand for formatting 
     752                        // and wait "after" a keystroke or paste. Then, if the formatting 
     753                        // tag exists and has contents, replace it with the real element. 
     754                        // range.Window.document.execCommand( 'FontName', false, '__FCKeditorTemp' ) ; 
     755                         
     756                        // For now, we do nothing for collapsed selections. 
    744757                        return ; 
    745  
     758                } 
     759                 
    746760                var elementName = this.Element ; 
    747761