source: branches/2.2/filemanager/tp/ckeditor/_source/plugins/print/plugin.js @ 3019

Revision 3019, 896 bytes checked in by amuller, 14 years ago (diff)

Ticket #1135 - Corrigindo CSS e adicionando filemanager

Line 
1/*
2Copyright (c) 2003-2009, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.html or http://ckeditor.com/license
4*/
5
6/**
7 * @file Print Plugin
8 */
9
10CKEDITOR.plugins.add( 'print',
11{
12        init : function( editor )
13        {
14                var pluginName = 'print';
15
16                // Register the command.
17                var command = editor.addCommand( pluginName, CKEDITOR.plugins.print );
18
19                // Register the toolbar button.
20                editor.ui.addButton( 'Print',
21                        {
22                                label : editor.lang.print,
23                                command : pluginName
24                        });
25        }
26} );
27
28CKEDITOR.plugins.print =
29{
30        exec : function( editor )
31        {
32                if ( CKEDITOR.env.opera )
33                        return;
34                else if ( CKEDITOR.env.gecko )
35                        editor.window.$.print();
36                else
37                        editor.document.$.execCommand( "Print" );
38        },
39        canUndo : false,
40        modes : { wysiwyg : !( CKEDITOR.env.opera ) }           // It is imposible to print the inner document in Opera.
41};
Note: See TracBrowser for help on using the repository browser.