web/assets/libs/ckeditor/4.6.7/plugins/docprops/dialogs/docprops.js
(开头部分) 1KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
/**
* @license Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved.
* For licensing, see LICENSE.md or http://ckeditor.com/license
*/
CKEDITOR.dialog.add( 'docProps', function( editor ) {
var lang = editor.lang.docprops,
langCommon = editor.lang.common,
metaHash = {};
function getDialogValue( dialogName, callback ) {
var onOk = function() {
releaseHandlers( this );
callback( this, this._.parentDialog );
};
var releaseHandlers = function( dialog ) {
dialog.removeListener( 'ok', onOk );
dialog.removeListener( 'cancel', releaseHandlers );
};
var bindToDialog = function( dialog ) {
dialog.on( 'ok', onOk );
dialog.on( 'cancel', releaseHandlers );
};
editor.execCommand( dialogName );
if ( editor._.storedDialogs.colordialog )
bindToDialog( editor._.storedDialogs.colordialog );
else {
CKEDITOR.on( 'dialogDefinition', function( e ) {
if ( e.data.name != dialogName )
return;
var definition = e.data.definition;
e.removeListener();
definition.onLoad = CKEDITOR.tools.override( definition.onLoad, function( orginal ) {
return function() {
bindToDialog( this );
definition.onLoad = orginal;
if ( typeof orginal == 'function' )
orginal.call( this );
};
} );
} );
}
}
function handleOther() {
var dialog = this.getDialog(),
other = dialog.getContentElement( 'general', this.id + 'Other' );
if ( !other )
return;
if ( this.getValue() == 'other' ) {
other.getInputElement().removeAttribute( 'readOnly' );
other.focus();
other.getElement().removeClass( 'cke_disabled' );
} else {
other.getInputElement().setAttribute( 'readOnly', true );
other.getElement().addClass( 'cke_disabled' );
}
}
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。