1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
3 * FCKeditor - The text editor for Internet - http://www.fckeditor.net
4 * Copyright (C) 2003-2010 Frederico Caldeira Knabben
8 * Licensed under the terms of any of the following licenses at your
11 * - GNU General Public License Version 2 or later (the "GPL")
12 * http://www.gnu.org/licenses/gpl.html
14 * - GNU Lesser General Public License Version 2.1 or later (the "LGPL")
15 * http://www.gnu.org/licenses/lgpl.html
17 * - Mozilla Public License Version 1.1 or later (the "MPL")
18 * http://www.mozilla.org/MPL/MPL-1.1.html
22 * Smileys (emoticons) dialog window.
24 <html xmlns="http://www.w3.org/1999/xhtml">
27 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
28 <meta name="robots" content="noindex, nofollow" />
29 <style type="text/css">
36 <script src="common/fck_dialog_common.js" type="text/javascript"></script>
37 <script type="text/javascript">
39 var dialog = window.parent ;
40 var oEditor = dialog.InnerDialogLoaded() ;
42 window.onload = function ()
44 // First of all, translate the dialog box texts
45 oEditor.FCKLanguageManager.TranslatePage(document) ;
47 dialog.SetAutoSize( true ) ;
50 function InsertSmiley( url )
52 oEditor.FCKUndo.SaveUndoStep() ;
54 var oImg = oEditor.FCK.InsertElement( 'img' ) ;
56 oImg.setAttribute( '_fcksavedurl', url ) ;
58 // For long smileys list, it seams that IE continues loading the images in
59 // the background when you quickly select one image. so, let's clear
60 // everything before closing.
61 document.body.innerHTML = '' ;
68 td.className = 'LightBackground Hand' ;
73 td.className = 'DarkBackground Hand' ;
77 <body style="overflow: hidden">
78 <table cellpadding="2" cellspacing="2" align="center" border="0" width="100%" height="100%">
79 <script type="text/javascript">
81 var FCKConfig = oEditor.FCKConfig ;
83 var sBasePath = FCKConfig.SmileyPath ;
84 var aImages = FCKConfig.SmileyImages ;
85 var iCols = FCKConfig.SmileyColumns ;
86 var iColWidth = parseInt( 100 / iCols, 10 ) ;
89 while (i < aImages.length)
91 document.write( '<tr>' ) ;
92 for(var j = 0 ; j < iCols ; j++)
96 var sUrl = sBasePath + aImages[i] ;
97 document.write( '<td width="' + iColWidth + '%" align="center" class="DarkBackground Hand" onclick="InsertSmiley(\'' + sUrl.replace(/'/g, "\\'" ) + '\')" onmouseover="over(this)" onmouseout="out(this)">' ) ;
98 document.write( '<img src="' + sUrl + '" border="0" />' ) ;
101 document.write( '<td width="' + iColWidth + '%" class="DarkBackground"> ' ) ;
102 document.write( '<\/td>' ) ;
105 document.write('<\/tr>') ;