Autosave focus grab fix from masquerade. fixes #3040

git-svn-id: http://svn.automattic.com/wordpress/trunk@4101 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
ryan 2006-08-16 02:50:03 +00:00
parent 44b3783d36
commit 0bc3bd75b9
3 changed files with 7 additions and 3 deletions

View File

@ -83,6 +83,7 @@ function autosave() {
if ( typeof tinyMCE == "undefined" || tinyMCE.configs.length < 1 ) {
autosaveAjax.setVar("content", form.content.value);
} else {
if(tinyMCE.selectedInstance.spellcheckerOn) return;
tinyMCE.wpTriggerSave();
autosaveAjax.setVar("content", form.content.value);
}

View File

@ -424,7 +424,10 @@ wpInstTriggerSave = function (skip_cleanup, skip_callback) {
}
tinyMCE._customCleanup(this, "submit_content_dom", this.contentWindow.document.body);
var htm = skip_cleanup ? this.getBody().innerHTML : tinyMCE._cleanupHTML(this, this.getDoc(), this.settings, this.getBody(), tinyMCE.visualAid, true, true);
tinyMCE.selectedInstance.getWin().oldfocus=tinyMCE.selectedInstance.getWin().focus;
tinyMCE.selectedInstance.getWin().focus=function() {};
var htm = tinyMCE._cleanupHTML(this, this.getDoc(), this.settings, this.getBody(), tinyMCE.visualAid, true, true);
tinyMCE.selectedInstance.getWin().focus=tinyMCE.selectedInstance.getWin().oldfocus;
htm = tinyMCE._customCleanup(this, "submit_content", htm);
if (!skip_callback && tinyMCE.settings['save_callback'] != "")

View File

@ -15,10 +15,10 @@ class WP_Scripts {
$this->add( 'sack', '/wp-includes/js/tw-sack.js', false, '1.6.1' );
$this->add( 'quicktags', '/wp-includes/js/quicktags.js', false, '3517' );
$this->add( 'colorpicker', '/wp-includes/js/colorpicker.js', false, '3517' );
$this->add( 'tiny_mce', '/wp-includes/js/tinymce/tiny_mce_gzip.php', false, '08112006' );
$this->add( 'tiny_mce', '/wp-includes/js/tinymce/tiny_mce_gzip.php', false, '08152006' );
$this->add( 'wp_tiny_mce', '/wp-includes/js/tinymce/tiny_mce_config.php', array('tiny_mce'), '04162006' );
$this->add( 'prototype', '/wp-includes/js/prototype.js', false, '1.5.0');
$this->add( 'autosave', '/wp-includes/js/autosave.js.php', array('prototype', 'sack'), '4096');
$this->add( 'autosave', '/wp-includes/js/autosave.js.php', array('prototype', 'sack'), '4101');
if ( is_admin() ) {
$this->add( 'dbx-admin-key', '/wp-admin/dbx-admin-key-js.php', array('dbx'), '3651' );
$this->add( 'listman', '/wp-admin/list-manipulation-js.php', array('sack', 'fat'), '4042' ); // Make changeset # the correct one