Archived
1
0

When scrolling the window, scroll to the top of the note controls instead of just the top of the iframe.

This commit is contained in:
Dan Helfman 2007-07-23 23:49:57 +00:00
parent 120c29954c
commit c05e143269

View File

@ -160,13 +160,13 @@ Editor.prototype.highlight = function ( scroll ) {
scroll = true;
if ( /Opera/.test( navigator.userAgent ) ) { // MochiKit's Highlight is broken in Opera
if ( scroll ) ScrollTo( this.iframe );
if ( scroll ) ScrollTo( this.note_controls );
pulsate( this.iframe, options = { "pulses": 1, "duration": 0.5 } );
} else if ( this.iframe.contentDocument ) { // browsers such as Firefox
if ( scroll ) ScrollTo( this.iframe );
if ( scroll ) ScrollTo( this.note_controls );
Highlight( this.iframe, options = { "queue": { "scope": "highlight", "limit": 1 } } );
} else { // browsers such as IE
if ( scroll ) ScrollTo( this.iframe );
if ( scroll ) ScrollTo( this.note_controls );
if ( this.document && this.document.body )
Highlight( this.document.body, options = { "queue": { "scope": "highlight", "limit": 1 } } );
}