mirror of
https://github.com/WordPress/WordPress.git
synced 2024-09-12 15:48:34 +02:00
git-svn-id: http://svn.automattic.com/wordpress/trunk@4747 1a063a9b-81f0-0310-95a4-ce76da25c4cd
31 lines
817 B
JavaScript
31 lines
817 B
JavaScript
/* Import plugin specific language pack */
|
|
tinyMCE.importPluginLanguagePack('autosave', 'en,sv,cs,he,no,hu,de,da,ru,ru_KOI8-R,ru_UTF-8,fi,cy,es,is,pl');
|
|
|
|
function TinyMCE_autosave_getInfo() {
|
|
return {
|
|
longname : 'Auto save',
|
|
author : 'Moxiecode Systems',
|
|
authorurl : 'http://tinymce.moxiecode.com',
|
|
infourl : 'http://tinymce.moxiecode.com/tinymce/docs/plugin_autosave.html',
|
|
version : tinyMCE.majorVersion + "." + tinyMCE.minorVersion
|
|
};
|
|
};
|
|
|
|
function TinyMCE_autosave_beforeUnloadHandler() {
|
|
var msg = tinyMCE.getLang("lang_autosave_unload_msg");
|
|
|
|
var anyDirty = false;
|
|
for (var n in tinyMCE.instances) {
|
|
var inst = tinyMCE.instances[n];
|
|
if (!tinyMCE.isInstance(inst))
|
|
continue;
|
|
|
|
if (inst.isDirty())
|
|
return msg;
|
|
}
|
|
|
|
return;
|
|
}
|
|
|
|
window.onbeforeunload = TinyMCE_autosave_beforeUnloadHandler;
|