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