Changeset 2994
- Timestamp:
- 01/23/09 14:20:46 (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
CKEditor/branches/prototype/_source/plugins/newpage/plugin.js
r2938 r2994 13 13 init : function( editor, pluginPath ) 14 14 { 15 editor.addCommand( 'newpage', CKEDITOR.plugins.newpage ); 15 var config = editor.config.newpage, 16 data = config.resetToStartupContent ? editor.getData() : config.newPageContent; 17 18 editor.addCommand( 'newpage', 19 { 20 exec : function( editor ) 21 { 22 editor.setData( data ); 23 } 24 }); 25 16 26 editor.ui.addButton( 'NewPage', 17 27 { … … 19 29 command : 'newpage' 20 30 }); 21 if ( editor.config.newpage.resetToStartupContent )22 CKEDITOR.plugins.newpage.newContent = editor.getData();23 else24 CKEDITOR.plugins.newpage.newContent = editor.config.newpage.newPageContent;25 31 } 26 32 }); 27 33 28 CKEDITOR.plugins.newpage =29 {30 newContent : '',31 exec : function( editor )32 {33 if ( editor.config.newpage.confirmation == false || confirm( editor.lang.common.confirmNewPage ) )34 editor.setData( CKEDITOR.plugins.newpage.newContent );35 }36 };37 38 34 CKEDITOR.config.newpage = 39 35 { 40 confirmation : true,41 36 resetToStartupContent : false, 42 37 newPageContent : ''
Note: See TracChangeset
for help on using the changeset viewer.
