source: sandbox/3.0/phpgwapi/js/ckeditor/_source/plugins/smiley/plugin.js @ 2862

Revision 2862, 3.2 KB checked in by rodsouza, 14 years ago (diff)

Ticket #663 - Atualizando e centralizando o CKEditor (v. 3.2.1)

Line 
1/*
2Copyright (c) 2003-2010, CKSource - Frederico Knabben. All rights reserved.
3For licensing, see LICENSE.html or http://ckeditor.com/license
4*/
5
6CKEDITOR.plugins.add( 'smiley',
7{
8        requires : [ 'dialog' ],
9
10        init : function( editor )
11        {
12                editor.config.smiley_path = editor.config.smiley_path || ( this.path + 'images/' );
13                editor.addCommand( 'smiley', new CKEDITOR.dialogCommand( 'smiley' ) );
14                editor.ui.addButton( 'Smiley',
15                        {
16                                label : editor.lang.smiley.toolbar,
17                                command : 'smiley'
18                        });
19                CKEDITOR.dialog.add( 'smiley', this.path + 'dialogs/smiley.js' );
20        }
21} );
22
23/**
24 * The base path used to build the URL for the smiley images. It must end with
25 * a slash.
26 * @name CKEDITOR.config.smiley_path
27 * @type String
28 * @default {@link CKEDITOR.basePath} + 'plugins/smiley/images/'
29 * @example
30 * config.smiley_path = 'http://www.example.com/images/smileys/';
31 * @example
32 * config.smiley_path = '/images/smileys/';
33 */
34
35/**
36 * The file names for the smileys to be displayed. These files must be
37 * contained inside the URL path defined with the
38 * {@link CKEDITOR.config.smiley_path} setting.
39 * @type Array
40 * @default (see example)
41 * @example
42 * // This is actually the default value.
43 * config.smiley_images = [
44 *     'regular_smile.gif','sad_smile.gif','wink_smile.gif','teeth_smile.gif','confused_smile.gif','tounge_smile.gif',
45 *     'embaressed_smile.gif','omg_smile.gif','whatchutalkingabout_smile.gif','angry_smile.gif','angel_smile.gif','shades_smile.gif',
46 *     'devil_smile.gif','cry_smile.gif','lightbulb.gif','thumbs_down.gif','thumbs_up.gif','heart.gif',
47 *     'broken_heart.gif','kiss.gif','envelope.gif'];
48 */
49CKEDITOR.config.smiley_images = [
50        'regular_smile.gif','sad_smile.gif','wink_smile.gif','teeth_smile.gif','confused_smile.gif','tounge_smile.gif',
51        'embaressed_smile.gif','omg_smile.gif','whatchutalkingabout_smile.gif','angry_smile.gif','angel_smile.gif','shades_smile.gif',
52        'devil_smile.gif','cry_smile.gif','lightbulb.gif','thumbs_down.gif','thumbs_up.gif','heart.gif',
53        'broken_heart.gif','kiss.gif','envelope.gif'];
54
55/**
56 * The description to be used for each of the smileys defined in the
57 * {@link CKEDITOR.config.smiley_images} setting. Each entry in this array list
58 * must match its relative pair in the {@link CKEDITOR.config.smiley_images}
59 * setting.
60 * @type Array
61 * @default  The textual descriptions of smiley.
62 * @example
63 * // Default settings.
64 * config.smiley_descriptions =
65 *     [
66 *         'smiley', 'sad', 'wink', 'laugh', 'frown', 'cheeky', 'blush', 'surprise',
67 *         'indecision', 'angry', 'angle', 'cool', 'devil', 'crying', 'enlightened', 'no',
68 *         'yes', 'heart', 'broken heart', 'kiss', 'mail'
69 *     ];
70 * @example
71 * // Use textual emoticons as description.
72 * config.smiley_descriptions =
73 *     [
74 *         ':)', ':(', ';)', ':D', ':/', ':P', ':*)', ':-o',
75 *         ':|', '>:(', 'o:)', '8-)', '>:-)', ';(', '', '', '',
76 *         '', '', ':-*', ''
77 *     ];
78 */
79CKEDITOR.config.smiley_descriptions =
80        [
81                'smiley', 'sad', 'wink', 'laugh', 'frown', 'cheeky', 'blush', 'surprise',
82                'indecision', 'angry', 'angle', 'cool', 'devil', 'crying', 'enlightened', 'no',
83                'yes', 'heart', 'broken heart', 'kiss', 'mail'
84        ];
Note: See TracBrowser for help on using the repository browser.