witten
/
luminotes
Archived
1
0
Fork 0

Some tweaks for Opera, even though it's not supported.

This commit is contained in:
Dan Helfman 2007-10-19 20:55:13 +00:00
parent cfaf607a7a
commit d44f3b9224
1 changed files with 4 additions and 4 deletions

View File

@ -171,9 +171,9 @@ Editor.prototype.finish_init = function () {
} );
}
if ( this.iframe.contentDocument ) { // browsers such as Firefox
if ( this.read_write ) this.exec_command( "styleWithCSS", false );
}
// browsers such as Firefox, but not Opera
if ( this.iframe.contentDocument && !/Opera/.test( navigator.userAgent ) && this.read_write )
this.exec_command( "styleWithCSS", false );
this.resize();
if ( this.init_highlight ) self.highlight();
@ -189,7 +189,7 @@ Editor.prototype.highlight = function ( scroll ) {
if ( scroll == undefined )
scroll = true;
if ( /Opera/.test( navigator.userAgent ) ) { // MochiKit's Highlight is broken in Opera
if ( /Opera/.test( navigator.userAgent ) ) { // MochiKit's Highlight for iframes is broken in Opera
if ( scroll ) ScrollTo( this.note_controls );
pulsate( this.iframe, options = { "pulses": 1, "duration": 0.5 } );
} else if ( this.iframe.contentDocument ) { // browsers such as Firefox