Ticket #2323: 2323.patch
File 2323.patch, 2.0 KB (added by , 16 years ago) |
---|
-
_whatsnew.html
54 54 has pressed the Source button.</li> 55 55 <li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2314">#2314</a>] Corrected 56 56 mixed up Chinese translations for the blockquote command.</li> 57 <li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2323">#2323</a>] Fixed the issue 58 where the show blocks command loses the current selection from the view area when editing 59 a long document.</li> 57 60 </ul> 58 61 <p> 59 62 <a href="_whatsnew_history.html">See previous versions history</a></p> -
editor/_source/commandclasses/fckshowblocks.js
44 44 else 45 45 body.className += ' FCK__ShowBlocks' ; 46 46 47 if ( FCKBrowserInfo.IsIE ) 48 { 49 try 50 { 51 FCK.EditorDocument.selection.createRange().select() ; 52 } 53 catch ( e ) 54 {} 55 } 56 else 57 { 58 var focus = FCK.EditorWindow.getSelection().focusNode ; 59 if ( focus.nodeType != 1 ) 60 focus = focus.parentNode ; 61 FCKDomTools.ScrollIntoView( focus, false ) ; 62 } 63 47 64 FCK.Events.FireEvent( 'OnSelectionChange' ) ; 48 65 } 49 66 -
editor/_source/internals/fckdomtools.js
1004 1004 1005 1005 // Scroll the window to the desired position, if not already visible. 1006 1006 var currentScroll = FCKTools.GetScrollPosition( window ).Y ; 1007 if ( offset > 0 && offset > currentScroll)1007 if ( offset > 0 && ( offset > currentScroll || offset < currentScroll - windowHeight ) ) 1008 1008 window.scrollTo( 0, offset ) ; 1009 1009 }, 1010 1010