- bPrevent = ( FCK.Status != FCK_STATUS_COMPLETE || !FCK.Events.FireEvent( "OnPaste" ) ) ;
-
- if ( bPrevent )
- {
- e.preventDefault() ;
- e.stopPropagation() ;
- }
- }
- this.EditorDocument.addEventListener( 'keypress', oOnKeyDown, true ) ;
-
- this.ExecOnSelectionChange = function()
- {
- FCK.Events.FireEvent( "OnSelectionChange" ) ;
- }
-
- this.ExecOnSelectionChangeTimer = function()
- {
- if ( FCK.LastOnChangeTimer )
- window.clearTimeout( FCK.LastOnChangeTimer ) ;
-
- FCK.LastOnChangeTimer = window.setTimeout( FCK.ExecOnSelectionChange, 100 ) ;
- }
-
- this.EditorDocument.addEventListener( 'mouseup', this.ExecOnSelectionChange, false ) ;
-
- // On Gecko, firing the "OnSelectionChange" event on every key press started to be too much
- // slow. So, a timer has been implemented to solve performance issues when tipying to quickly.
- this.EditorDocument.addEventListener( 'keyup', this.ExecOnSelectionChangeTimer, false ) ;
-
- this._DblClickListener = function( e )
- {
- FCK.OnDoubleClick( e.target ) ;
- e.stopPropagation() ;
- }
- this.EditorDocument.addEventListener( 'dblclick', this._DblClickListener, true ) ;
-
- // Reset the context menu.
- FCK.ContextMenu._InnerContextMenu.SetMouseClickWindow( FCK.EditorWindow ) ;
- FCK.ContextMenu._InnerContextMenu.AttachToElement( FCK.EditorDocument ) ;
-}
-
-FCK.MakeEditable = function()
-{
- this.EditingArea.MakeEditable() ;
-}
-
-// Disable the context menu in the editor (outside the editing area).
-function Document_OnContextMenu( e )
-{
- if ( !e.target._FCKShowContextMenu )
- e.preventDefault() ;
-}
-document.oncontextmenu = Document_OnContextMenu ;
\ No newline at end of file
diff --git a/htdocs/includes/fckeditor/editor/_source/internals/fck_1_ie.js b/htdocs/includes/fckeditor/editor/_source/internals/fck_1_ie.js
deleted file mode 100644
index 7456243a6eb..00000000000
--- a/htdocs/includes/fckeditor/editor/_source/internals/fck_1_ie.js
+++ /dev/null
@@ -1,285 +0,0 @@
-/*
- * FCKeditor - The text editor for internet
- * Copyright (C) 2003-2006 Frederico Caldeira Knabben
- *
- * Licensed under the terms of the GNU Lesser General Public License:
- * http://www.opensource.org/licenses/lgpl-license.php
- *
- * For further information visit:
- * http://www.fckeditor.net/
- *
- * "Support Open Source software. What about a donation today?"
- *
- * File Name: fck_1_ie.js
- * This is the first part of the "FCK" object creation. This is the main
- * object that represents an editor instance.
- * (IE specific implementations)
- *
- * File Authors:
- * Frederico Caldeira Knabben (fredck@fckeditor.net)
- */
-
-FCK.Description = "FCKeditor for Internet Explorer 5.5+" ;
-
-FCK._GetBehaviorsStyle = function()
-{
- if ( !FCK._BehaviorsStyle )
- {
- var sBasePath = FCKConfig.FullBasePath ;
- var sStyle ;
-
- // The behaviors should be pointed using the FullBasePath to avoid security
- // errors when using a differente BaseHref.
- sStyle =
- '' ;
- FCK._BehaviorsStyle = sStyle ;
- }
-
- return FCK._BehaviorsStyle ;
-}
-
-function Doc_OnMouseUp()
-{
- if ( FCK.EditorWindow.event.srcElement.tagName == 'HTML' )
- {
- FCK.Focus() ;
- FCK.EditorWindow.event.cancelBubble = true ;
- FCK.EditorWindow.event.returnValue = false ;
- }
-}
-
-function Doc_OnPaste()
-{
- if ( FCK.Status == FCK_STATUS_COMPLETE )
- return FCK.Events.FireEvent( "OnPaste" ) ;
- else
- return false ;
-}
-
-/*
-function Doc_OnContextMenu()
-{
- var e = FCK.EditorWindow.event ;
-
- FCK.ShowContextMenu( e.screenX, e.screenY ) ;
- return false ;
-}
-*/
-
-function Doc_OnKeyDown()
-{
- var e = FCK.EditorWindow.event ;
-
-
- switch ( e.keyCode )
- {
- case 13 : // ENTER
- if ( FCKConfig.UseBROnCarriageReturn && !(e.ctrlKey || e.altKey || e.shiftKey) )
- {
- Doc_OnKeyDownUndo() ;
-
- // We must ignore it if we are inside a List.
- if ( FCK.EditorDocument.queryCommandState( 'InsertOrderedList' ) || FCK.EditorDocument.queryCommandState( 'InsertUnorderedList' ) )
- return true ;
-
- // Insert the
(The must be also inserted to make it work)
- FCK.InsertHtml( '
' ) ;
-
- // Remove the
- var oRange = FCK.EditorDocument.selection.createRange() ;
- oRange.moveStart( 'character', -1 ) ;
- oRange.select() ;
- FCK.EditorDocument.selection.clear() ;
-
- return false ;
- }
- break ;
-
- case 8 : // BACKSPACE
- // We must delete a control selection by code and cancels the
- // keystroke, otherwise IE will execute the browser's "back" button.
- if ( FCKSelection.GetType() == 'Control' )
- {
- FCKSelection.Delete() ;
- return false ;
- }
- break ;
-
- case 9 : // TAB
- if ( FCKConfig.TabSpaces > 0 && !(e.ctrlKey || e.altKey || e.shiftKey) )
- {
- Doc_OnKeyDownUndo() ;
-
- FCK.InsertHtml( window.FCKTabHTML ) ;
- return false ;
- }
- break ;
- case 90 : // Z
- if ( e.ctrlKey && !(e.altKey || e.shiftKey) )
- {
- FCKUndo.Undo() ;
- return false ;
- }
- break ;
- case 89 : // Y
- if ( e.ctrlKey && !(e.altKey || e.shiftKey) )
- {
- FCKUndo.Redo() ;
- return false ;
- }
- break ;
- }
-
- if ( !( e.keyCode >=16 && e.keyCode <= 18 ) )
- Doc_OnKeyDownUndo() ;
- return true ;
-}
-
-function Doc_OnKeyDownUndo()
-{
- if ( !FCKUndo.Typing )
- {
- FCKUndo.SaveUndoStep() ;
- FCKUndo.Typing = true ;
- FCK.Events.FireEvent( "OnSelectionChange" ) ;
- }
-
- FCKUndo.TypesCount++ ;
-
- if ( FCKUndo.TypesCount > FCKUndo.MaxTypes )
- {
- FCKUndo.TypesCount = 0 ;
- FCKUndo.SaveUndoStep() ;
- }
-}
-
-function Doc_OnDblClick()
-{
- FCK.OnDoubleClick( FCK.EditorWindow.event.srcElement ) ;
- FCK.EditorWindow.event.cancelBubble = true ;
-}
-
-function Doc_OnSelectionChange()
-{
- FCK.Events.FireEvent( "OnSelectionChange" ) ;
-}
-
-FCK.InitializeBehaviors = function( dontReturn )
-{
- // Set the focus to the editable area when clicking in the document area.
- // TODO: The cursor must be positioned at the end.
- this.EditorDocument.attachEvent( 'onmouseup', Doc_OnMouseUp ) ;
-
- // Intercept pasting operations
- this.EditorDocument.body.attachEvent( 'onpaste', Doc_OnPaste ) ;
-
- // Reset the context menu.
- FCK.ContextMenu._InnerContextMenu.AttachToElement( FCK.EditorDocument.body ) ;
-
- // Build the "TAB" key replacement (if necessary).
- if ( FCKConfig.TabSpaces > 0 )
- {
- window.FCKTabHTML = '' ;
- for ( i = 0 ; i < FCKConfig.TabSpaces ; i++ )
- window.FCKTabHTML += " " ;
- }
- this.EditorDocument.attachEvent("onkeydown", Doc_OnKeyDown ) ;
-
- this.EditorDocument.attachEvent("ondblclick", Doc_OnDblClick ) ;
-
- // Catch cursor movements
- this.EditorDocument.attachEvent("onselectionchange", Doc_OnSelectionChange ) ;
-
- //Enable editing
-// this.EditorDocument.body.contentEditable = true ;
-}
-
-FCK.InsertHtml = function( html )
-{
- html = FCKConfig.ProtectedSource.Protect( html ) ;
- html = FCK.ProtectUrls( html ) ;
-
- FCK.Focus() ;
-
- FCKUndo.SaveUndoStep() ;
-
- // Gets the actual selection.
- var oSel = FCK.EditorDocument.selection ;
-
- // Deletes the actual selection contents.
- if ( oSel.type.toLowerCase() == 'control' )
- oSel.clear() ;
-
- // Insert the HTML.
- oSel.createRange().pasteHTML( html ) ;
-}
-
-FCK.SetInnerHtml = function( html ) // IE Only
-{
- var oDoc = FCK.EditorDocument ;
- // Using the following trick, any comment in the begining of the HTML will
- // be preserved.
- oDoc.body.innerHTML = '
' + html ;
- oDoc.getElementById('__fakeFCKRemove__').removeNode( true ) ;
-}
-
-var FCK_PreloadImages_Count = 0 ;
-var FCK_PreloadImages_Images = new Array() ;
-
-function FCK_PreloadImages()
-{
- // Get the images to preload.
- var aImages = FCKConfig.PreloadImages || [] ;
-
- if ( typeof( aImages ) == 'string' )
- aImages = aImages.split( ';' ) ;
-
- // Add the skin icons strip.
- aImages.push( FCKConfig.SkinPath + 'fck_strip.gif' ) ;
-
- FCK_PreloadImages_Count = aImages.length ;
-
- var aImageElements = new Array() ;
-
- for ( var i = 0 ; i < aImages.length ; i++ )
- {
- var eImg = document.createElement( 'img' ) ;
- eImg.onload = eImg.onerror = FCK_PreloadImages_OnImage ;
- eImg.src = aImages[i] ;
-
- FCK_PreloadImages_Images[i] = eImg ;
- }
-}
-
-function FCK_PreloadImages_OnImage()
-{
- if ( (--FCK_PreloadImages_Count) == 0 )
- FCKTools.RunFunction( LoadToolbarSetup ) ;
-}
-
-// Disable the context menu in the editor (outside the editing area).
-function Document_OnContextMenu()
-{
- return ( event.srcElement._FCKShowContextMenu == true ) ;
-}
-document.oncontextmenu = Document_OnContextMenu ;
-
-function FCK_Cleanup()
-{
- this.EditorWindow = null ;
- this.EditorDocument = null ;
-}
\ No newline at end of file
diff --git a/htdocs/includes/fckeditor/editor/_source/internals/fck_2.js b/htdocs/includes/fckeditor/editor/_source/internals/fck_2.js
deleted file mode 100644
index ba071f92c86..00000000000
--- a/htdocs/includes/fckeditor/editor/_source/internals/fck_2.js
+++ /dev/null
@@ -1,165 +0,0 @@
-/*
- * FCKeditor - The text editor for internet
- * Copyright (C) 2003-2006 Frederico Caldeira Knabben
- *
- * Licensed under the terms of the GNU Lesser General Public License:
- * http://www.opensource.org/licenses/lgpl-license.php
- *
- * For further information visit:
- * http://www.fckeditor.net/
- *
- * "Support Open Source software. What about a donation today?"
- *
- * File Name: fck_2.js
- * This is the second part of the "FCK" object creation. This is the main
- * object that represents an editor instance.
- *
- * File Authors:
- * Frederico Caldeira Knabben (fredck@fckeditor.net)
- */
-
-// This collection is used by the browser specific implementations to tell
-// wich named commands must be handled separately.
-FCK.RedirectNamedCommands = new Object() ;
-
-FCK.ExecuteNamedCommand = function( commandName, commandParameter, noRedirect )
-{
- FCKUndo.SaveUndoStep() ;
-
- if ( !noRedirect && FCK.RedirectNamedCommands[ commandName ] != null )
- FCK.ExecuteRedirectedNamedCommand( commandName, commandParameter ) ;
- else
- {
- FCK.Focus() ;
- FCK.EditorDocument.execCommand( commandName, false, commandParameter ) ;
- FCK.Events.FireEvent( 'OnSelectionChange' ) ;
- }
-
- FCKUndo.SaveUndoStep() ;
-}
-
-FCK.GetNamedCommandState = function( commandName )
-{
- try
- {
- if ( !FCK.EditorDocument.queryCommandEnabled( commandName ) )
- return FCK_TRISTATE_DISABLED ;
- else
- return FCK.EditorDocument.queryCommandState( commandName ) ? FCK_TRISTATE_ON : FCK_TRISTATE_OFF ;
- }
- catch ( e )
- {
- return FCK_TRISTATE_OFF ;
- }
-}
-
-FCK.GetNamedCommandValue = function( commandName )
-{
- var sValue = '' ;
- var eState = FCK.GetNamedCommandState( commandName ) ;
-
- if ( eState == FCK_TRISTATE_DISABLED )
- return null ;
-
- try
- {
- sValue = this.EditorDocument.queryCommandValue( commandName ) ;
- }
- catch(e) {}
-
- return sValue ? sValue : '' ;
-}
-
-FCK.PasteFromWord = function()
-{
- FCKDialog.OpenDialog( 'FCKDialog_Paste', FCKLang.PasteFromWord, 'dialog/fck_paste.html', 400, 330, 'Word' ) ;
-}
-
-FCK.Preview = function()
-{
- var iWidth = FCKConfig.ScreenWidth * 0.8 ;
- var iHeight = FCKConfig.ScreenHeight * 0.7 ;
- var iLeft = ( FCKConfig.ScreenWidth - iWidth ) / 2 ;
- var oWindow = window.open( '', null, 'toolbar=yes,location=no,status=yes,menubar=yes,scrollbars=yes,resizable=yes,width=' + iWidth + ',height=' + iHeight + ',left=' + iLeft ) ;
-
- var sHTML ;
-
- if ( FCKConfig.FullPage )
- {
- if ( FCK.TempBaseTag.length > 0 )
- sHTML = FCK.GetXHTML().replace( FCKRegexLib.HeadOpener, '$&' + FCK.TempBaseTag ) ;
- else
- sHTML = FCK.GetXHTML() ;
- }
- else
- {
- sHTML =
- FCKConfig.DocType +
- '' +
- '' +
- FCK.TempBaseTag +
- '' + FCKLang.Preview + '' +
- FCK._GetEditorAreaStyleTags() +
- '' +
- FCK.GetXHTML() +
- '' ;
- }
-
- oWindow.document.write( sHTML );
- oWindow.document.close();
-}
-
-FCK.SwitchEditMode = function( noUndo )
-{
- var bIsWysiwyg = ( FCK.EditMode == FCK_EDITMODE_WYSIWYG ) ;
- var sHtml ;
-
- // Update the HTML in the view output to show.
- if ( bIsWysiwyg )
- {
- if ( !noUndo && FCKBrowserInfo.IsIE )
- FCKUndo.SaveUndoStep() ;
-
- sHtml = FCK.GetXHTML( FCKConfig.FormatSource ) ;
- }
- else
- sHtml = this.EditingArea.Textarea.value ;
-
- FCK.EditMode = bIsWysiwyg ? FCK_EDITMODE_SOURCE : FCK_EDITMODE_WYSIWYG ;
-
- FCK.SetHTML( sHtml ) ;
-
- if ( FCKBrowserInfo.IsGecko )
- window.onresize() ;
-
- // Set the Focus.
- FCK.Focus() ;
-
- // Update the toolbar (Running it directly causes IE to fail).
- FCKTools.RunFunction( FCK.ToolbarSet.RefreshModeState, FCK.ToolbarSet ) ;
-}
-
-FCK.CreateElement = function( tag )
-{
- var e = FCK.EditorDocument.createElement( tag ) ;
- return FCK.InsertElementAndGetIt( e ) ;
-}
-
-FCK.InsertElementAndGetIt = function( e )
-{
- e.setAttribute( 'FCKTempLabel', 'true' ) ;
-
- this.InsertElement( e ) ;
-
- var aEls = FCK.EditorDocument.getElementsByTagName( e.tagName ) ;
-
- for ( var i = 0 ; i < aEls.length ; i++ )
- {
- if ( aEls[i].getAttribute( 'FCKTempLabel' ) )
- {
- aEls[i].removeAttribute( 'FCKTempLabel' ) ;
- return aEls[i] ;
- }
- }
- return null ;
-}
diff --git a/htdocs/includes/fckeditor/editor/_source/internals/fck_2_gecko.js b/htdocs/includes/fckeditor/editor/_source/internals/fck_2_gecko.js
deleted file mode 100644
index 3c621569d88..00000000000
--- a/htdocs/includes/fckeditor/editor/_source/internals/fck_2_gecko.js
+++ /dev/null
@@ -1,461 +0,0 @@
-/*
- * FCKeditor - The text editor for internet
- * Copyright (C) 2003-2006 Frederico Caldeira Knabben
- *
- * Licensed under the terms of the GNU Lesser General Public License:
- * http://www.opensource.org/licenses/lgpl-license.php
- *
- * For further information visit:
- * http://www.fckeditor.net/
- *
- * "Support Open Source software. What about a donation today?"
- *
- * File Name: fck_2_gecko.js
- * This is the second part of the "FCK" object creation. This is the main
- * object that represents an editor instance.
- * (Gecko specific implementations)
- *
- * File Authors:
- * Frederico Caldeira Knabben (fredck@fckeditor.net)
- */
-
-// GetNamedCommandState overload for Gecko.
-FCK._BaseGetNamedCommandState = FCK.GetNamedCommandState ;
-FCK.GetNamedCommandState = function( commandName )
-{
- switch ( commandName )
- {
- case 'Unlink' :
- return FCKSelection.HasAncestorNode('A') ? FCK_TRISTATE_OFF : FCK_TRISTATE_DISABLED ;
- default :
- return FCK._BaseGetNamedCommandState( commandName ) ;
- }
-}
-
-// Named commands to be handled by this browsers specific implementation.
-FCK.RedirectNamedCommands =
-{
- Print : true,
- Paste : true,
- Cut : true,
- Copy : true
- // START iCM MODIFICATIONS
- // Include list functions so we can ensure content is wrapped
- // with P tags if not using BRs on carriage return, etc
- /*
- InsertOrderedList : true,
- InsertUnorderedList : true
- */
- // END iCM MODIFICATIONS
-}
-
-// ExecuteNamedCommand overload for Gecko.
-FCK.ExecuteRedirectedNamedCommand = function( commandName, commandParameter )
-{
- switch ( commandName )
- {
- case 'Print' :
- FCK.EditorWindow.print() ;
- break ;
- case 'Paste' :
- try { if ( FCK.Paste() ) FCK.ExecuteNamedCommand( 'Paste', null, true ) ; }
- catch (e) { alert(FCKLang.PasteErrorPaste) ; }
- break ;
- case 'Cut' :
- try { FCK.ExecuteNamedCommand( 'Cut', null, true ) ; }
- catch (e) { alert(FCKLang.PasteErrorCut) ; }
- break ;
- case 'Copy' :
- try { FCK.ExecuteNamedCommand( 'Copy', null, true ) ; }
- catch (e) { alert(FCKLang.PasteErrorCopy) ; }
- break ;
-
- // START iCM MODIFICATIONS
- /*
- case 'InsertOrderedList' :
- case 'InsertUnorderedList' :
-
- if ( !FCKConfig.UseBROnCarriageReturn && FCK.EditorDocument.queryCommandState( commandName ) )
- {
- // We're in a list item which is in the same type of list as the toolbar button clicked
- // Therefore, move the selected list item out of the list as is done on an ENTER key within
- // an empty list item.
- var oSel = FCK.EditorWindow.getSelection() ;
- var oSelNode = oSel.focusNode ;
- var oLINode = FCKTools.GetElementAscensor( oSelNode, "LI" ) ;
- FCK.ToggleListItem( oLINode, oSelNode ) ;
- }
- else
- {
- // Let the default handler do its stuff
- FCK.Focus() ;
- FCK.EditorDocument.execCommand( commandName, false, commandParameter ) ;
- }
-
- FCK.Events.FireEvent( 'OnSelectionChange' ) ;
- break ;
- */
- // END iCM MODIFICATIONS
-
- default :
- FCK.ExecuteNamedCommand( commandName, commandParameter ) ;
- }
-}
-
-FCK.AttachToOnSelectionChange = function( functionPointer )
-{
- this.Events.AttachEvent( 'OnSelectionChange', functionPointer ) ;
-}
-
-FCK.Paste = function()
-{
- if ( FCKConfig.ForcePasteAsPlainText )
- {
- FCK.PasteAsPlainText() ;
- return false ;
- }
-/* For now, the AutoDetectPasteFromWord feature is IE only.
- else if ( FCKConfig.AutoDetectPasteFromWord )
- {
- var sHTML = FCK.GetClipboardHTML() ;
- var re = /<\w[^>]* class="?MsoNormal"?/gi ;
- if ( re.test( sHTML ) )
- {
- if ( confirm( FCKLang["PasteWordConfirm"] ) )
- {
- FCK.PasteFromWord() ;
- return false ;
- }
- }
- }
-*/
- else
- return true ;
-}
-
-//**
-// FCK.InsertHtml: Inserts HTML at the current cursor location. Deletes the
-// selected content if any.
-FCK.InsertHtml = function( html )
-{
- html = FCKConfig.ProtectedSource.Protect( html ) ;
- html = FCK.ProtectUrls( html ) ;
-
- // Delete the actual selection.
- var oSel = FCKSelection.Delete() ;
-
- // Get the first available range.
- var oRange = oSel.getRangeAt(0) ;
-
- // Create a fragment with the input HTML.
- var oFragment = oRange.createContextualFragment( html ) ;
-
- // Get the last available node.
- var oLastNode = oFragment.lastChild ;
-
- // Insert the fragment in the range.
- oRange.insertNode(oFragment) ;
-
- // Set the cursor after the inserted fragment.
- FCKSelection.SelectNode( oLastNode ) ;
- FCKSelection.Collapse( false ) ;
-
- this.Focus() ;
-}
-
-FCK.InsertElement = function( element )
-{
- // Deletes the actual selection.
- var oSel = FCKSelection.Delete() ;
-
- // Gets the first available range.
- var oRange = oSel.getRangeAt(0) ;
-
- // Inserts the element in the range.
- oRange.insertNode( element ) ;
-
- // Set the cursor after the inserted fragment.
- FCKSelection.SelectNode( element ) ;
- FCKSelection.Collapse( false ) ;
-
- this.Focus() ;
-}
-
-FCK.PasteAsPlainText = function()
-{
- // TODO: Implement the "Paste as Plain Text" code.
-
- FCKDialog.OpenDialog( 'FCKDialog_Paste', FCKLang.PasteAsText, 'dialog/fck_paste.html', 400, 330, 'PlainText' ) ;
-
-/*
- var sText = FCKTools.HTMLEncode( clipboardData.getData("Text") ) ;
- sText = sText.replace( /\n/g, '
' ) ;
- this.InsertHtml( sText ) ;
-*/
-}
-/*
-FCK.PasteFromWord = function()
-{
- // TODO: Implement the "Paste as Plain Text" code.
-
- FCKDialog.OpenDialog( 'FCKDialog_Paste', FCKLang.PasteFromWord, 'dialog/fck_paste.html', 400, 330, 'Word' ) ;
-
-// FCK.CleanAndPaste( FCK.GetClipboardHTML() ) ;
-}
-*/
-FCK.GetClipboardHTML = function()
-{
- return '' ;
-}
-
-FCK.CreateLink = function( url )
-{
- FCK.ExecuteNamedCommand( 'Unlink' ) ;
-
- if ( url.length > 0 )
- {
- // Generate a temporary name for the link.
- var sTempUrl = 'javascript:void(0);/*' + ( new Date().getTime() ) + '*/' ;
-
- // Use the internal "CreateLink" command to create the link.
- FCK.ExecuteNamedCommand( 'CreateLink', sTempUrl ) ;
-
- // Retrieve the just created link using XPath.
- var oLink = document.evaluate("//a[@href='" + sTempUrl + "']", this.EditorDocument.body, null, 9, null).singleNodeValue ;
-
- if ( oLink )
- {
- oLink.href = url ;
- return oLink ;
- }
- }
-}
-
-// START iCM Modifications
-/*
-// Ensure that behaviour of the ENTER key or the list toolbar button works correctly for a list item.
-// ENTER in empty list item at top of list should result in the empty list item being
-// removed and selection being moved out of the list into a P tag above it.
-// ENTER in empty list item at bottom of list should result in the empty list item being
-// removed and selection being moved out of the list into a P tag below it.
-// ENTER in empty list item in middle of the list should result in the list being split
-// into two and the selection being moved into a P tag between the two resulting lists.
-// Clicking the list toolbar button in a list item at top of list should result in the list item's contents being
-// moved out of the list into a P tag above it.
-// Clicking the list toolbar button in a list item at the bottom of list should result in the list item's contents being
-// moved out of the list into a P tag below it.
-// Clicking the list toolbar button in a list item in the middle of the list should result in the list being split
-// into two and the list item's contents being moved into a P tag between the two resulting lists.
-FCK.ToggleListItem = function( oLINode, oSelNode )
-{
- var oListNode = FCKTools.GetElementAscensor( oLINode, "UL,OL" ) ;
- var oRange = FCK.EditorDocument.createRange() ;
-
- // Create a new block element
- var oBlockNode = FCK.EditorDocument.createElement( "P" ) ;
- oBlockNode.innerHTML = oLINode.innerHTML ; // Transfer any list item contents
- if ( FCKTools.NodeIsEmpty( oBlockNode ) )
- oBlockNode.innerHTML = GECKO_BOGUS ; // Ensure it has some content, required for Gecko
- if ( oLINode.className && oLINode.className != '' )
- oBlockNode.className = oLINode.className ; // Transfer across any class attribute
-
- var oCursorNode = oBlockNode ;
-
- // Then, perform list processing and locate the point at which the new P tag is to be inserted
- if ( oListNode.childNodes[0] == oLINode )
- {
- // First LI was empty so want to leave list and insert P above it
- oListNode.removeChild( oLINode );
- // Need to insert a new P tag (or other suitable block element) just before the list
- oRange.setStartBefore( oListNode ) ;
- oRange.setEndBefore( oListNode ) ;
- }
- else if ( oListNode.childNodes[oListNode.childNodes.length-1] == oLINode )
- {
- // Last LI was empty so want to leave list and insert new block element in the parent
- oListNode.removeChild( oLINode );
- // Need to insert a new P tag (or other suitable block element) just after the list
- oRange.setEndAfter( oListNode ) ;
- oRange.setStartAfter( oListNode ) ;
- }
- else
- {
- // A middle LI was empty so want to break list into two and insert the new block/text node in between them
- oListNode = FCKTools.SplitNode( oListNode, oSelNode, 0 ) ;
- oListNode.removeChild( oListNode.childNodes[0] ) ;
- oRange.setStartBefore( oListNode ) ;
- oRange.setEndBefore( oListNode ) ;
- }
-
- // Insert new block/text node
- oRange.insertNode( oBlockNode ) ;
-
- // Ensure that we don't leave empty UL/OL tags behind
- if ( oListNode.childNodes.length == 0 )
- oListNode.parentNode.removeChild( oListNode ) ;
-
- // Reset cursor position to start of the new P tag's contents ready for typing
- FCK.Selection.SetCursorPosition( oCursorNode ) ;
-}
-
-FCK.ListItemEnter = function( oLINode, oSelNode, nSelOffset )
-{
- // Ensure that behaviour of ENTER key within an empty list element works correctly.
- // ENTER in empty list item at top of list should result in the empty list item being
- // removed and selection being moved out of the list into a P tag above it.
- // ENTER in empty list item at bottom of list should result in the empty list item being
- // removed and selection being moved out of the list into a P tag below it.
- // ENTER in empty list item in middle of the list should result in the list being split
- // into two and the selection being moved into a P tag between the two resulting lists.
- if ( FCKTools.NodeIsEmpty( oLINode ) )
- {
- FCK.ToggleListItem( oLINode, oSelNode ) ;
- return false ; // Job done, perform no default handling
- }
-
- return true ; // If non-empty list item, let default handler do its stuff
-}
-
-FCK.ListItemBackSpace = function( oSelNode, nSelOffset )
-{
- // Ensure that behaviour of BACKSPACE key within an empty list element works correctly.
- // BACKSPACE in empty list item at top of list should result in the empty list item being
- // removed and selection being moved out of the list into a P tag above it.
- // Allow the default handler to do its stuff for backspace in other list elements.
- var oListNode = oSelNode.parentNode ;
-
- if ( FCKTools.NodeIsEmpty( oSelNode ) && ( oListNode.childNodes[0] == oSelNode ) )
- {
- var oRange = FCK.EditorDocument.createRange() ;
-
- // Create a new P element
- var oBlockNode = FCK.EditorDocument.createElement( "P" ) ;
- if ( FCKTools.NodeIsEmpty( oBlockNode ) )
- oBlockNode.innerHTML = GECKO_BOGUS ; // Ensure it has some content, required for Gecko
-
- // First LI was empty so want to leave list and insert P above it
- oListNode.removeChild( oSelNode );
- oRange.setStartBefore( oListNode ) ;
- oRange.setEndBefore( oListNode ) ;
-
- // Insert new P tag
- oRange.insertNode( oBlockNode ) ;
-
- // Ensure that we don't leave empty UL/OL tags behind
- if ( oListNode.childNodes.length == 0 )
- oListNode.parentNode.removeChild( oListNode ) ;
-
- // Reset cursor position to start of the new P tag's contents ready for typing
- FCK.Selection.SetCursorPosition( oBlockNode ) ;
-
- return false ; // Job done, perform no default handling
- }
-
- return true ; // Let default handler do its stuff if not backspacing in an empty first LI
-}
-
-FCK.Enter = function()
-{
- // Remove any selected content before we begin so we end up with a single selection point
- FCK.Selection.Delete() ;
-
- // Determine the current cursor (selection) point, the node it's within and the offset
- // position of the cursor within that node
- var oSel = FCK.EditorWindow.getSelection() ;
- var nSelOffset = oSel.focusOffset;
- var oSelNode = oSel.focusNode ;
-
- // Guard against a null focus node.
- if ( !oSelNode )
- return false ;
-
- var oLINode = FCKTools.GetElementAscensor( oSelNode, "LI" ) ;
-
- if ( oLINode ) // An LI element is selected
- {
- // Handle list items separately as need to handle termination of the list, etc
- return FCK.ListItemEnter( oLINode, oSelNode, nSelOffset ) ;
- }
- else if ( oSelNode.nodeType == 3 ) // A TEXT node is selected
- {
- // Split it at the selection point and ensure both halves have a suitable enclosing block element
- var oParentBlockNode = FCKTools.GetParentBlockNode( oSelNode ) ;
- var oBlockNode2 = FCKTools.SplitNode( oParentBlockNode ? oParentBlockNode : FCK.EditorDocument.body, oSelNode, nSelOffset ) ;
-
- FCK.Selection.SetCursorPosition( oBlockNode2 );
-
- return false ;
- }
- else // An ELEMENT node is selected
- {
- // Cater for ENTER being pressed after very last element in the editor e.g. pressing ENTER after table element at very end of the editor's content
- if ( nSelOffset >= oSelNode.childNodes.length )
- {
- var oBlockNode = FCK.EditorDocument.createElement( "P" ) ;
- if ( FCKTools.NodeIsEmpty( oBlockNode ) )
- oBlockNode.innerHTML = GECKO_BOGUS ; // Ensure it has some content, required for Gecko
- oSelNode.appendChild( oBlockNode ) ;
- FCK.Selection.SetCursorPosition( oBlockNode ) ;
- return false ;
- }
-
- var oBlockNode2 = FCKTools.SplitNode( oSelNode, oSelNode.childNodes[nSelOffset] ) ;
-
- FCK.Selection.SetCursorPosition( oBlockNode2 );
-
- return false ;
- }
-
- return true ;
-}
-
-FCK.BackSpace = function()
-{
- var oSel = FCK.EditorWindow.getSelection() ;
- var oSelNode = oSel.focusNode ;
- var nSelOffset = oSel.focusOffset;
- var oParentNode = null ;
-
- // Guard against a null focus node.
- if ( !oSelNode )
- return false ;
-
- if ( oSelNode.nodeName.toUpperCase() == "LI" ) // An LI element is selected
- {
- // Handle list items separately as need to handle termination of the list, etc
- return FCK.ListItemBackSpace( oSelNode, nSelOffset ) ;
- }
- else
- {
- // If we are anything other than a TEXT node, move to the child indicated by the selection offset
- if ( oSelNode.nodeType != 3 )
- {
- oSelNode = oSelNode.childNodes[nSelOffset] ;
- nSelOffset = 0 ;
- }
-
- // If we are the first child and the previous sibling of the parent is an empty block element (containing nothing or just the filler element)
- // want the backspace to completely remove the empty block element
- if ( !oSelNode.previousSibling && nSelOffset <= 0 )
- {
- oParentNode = oSelNode.parentNode ;
-
- if ( oParentNode && oParentNode.previousSibling && FCKRegexLib.BlockElements.test( oParentNode.previousSibling.nodeName ) )
- {
- if ( FCKTools.NodeIsEmpty( oParentNode.previousSibling ) )
- {
- var oRange = FCK.EditorDocument.createRange() ;
- oRange.selectNode ( oParentNode.previousSibling );
- oRange.deleteContents() ;
-
- // Don't do any default processing
- return false ;
- }
- }
- }
- }
- return true ; // Let default processing do its stuff
-}
-*/
-// END iCM Modifications
-
diff --git a/htdocs/includes/fckeditor/editor/_source/internals/fck_2_ie.js b/htdocs/includes/fckeditor/editor/_source/internals/fck_2_ie.js
deleted file mode 100644
index 2b16e3916b1..00000000000
--- a/htdocs/includes/fckeditor/editor/_source/internals/fck_2_ie.js
+++ /dev/null
@@ -1,157 +0,0 @@
-/*
- * FCKeditor - The text editor for internet
- * Copyright (C) 2003-2006 Frederico Caldeira Knabben
- *
- * Licensed under the terms of the GNU Lesser General Public License:
- * http://www.opensource.org/licenses/lgpl-license.php
- *
- * For further information visit:
- * http://www.fckeditor.net/
- *
- * "Support Open Source software. What about a donation today?"
- *
- * File Name: fck_2_ie.js
- * This is the second part of the "FCK" object creation. This is the main
- * object that represents an editor instance.
- * (IE specific implementations)
- *
- * File Authors:
- * Frederico Caldeira Knabben (fredck@fckeditor.net)
- */
-
-/*
-if ( FCKConfig.UseBROnCarriageReturn )
-{
- // Named commands to be handled by this browsers specific implementation.
- FCK.RedirectNamedCommands =
- {
- InsertOrderedList : true,
- InsertUnorderedList : true
- }
-
- FCK.ExecuteRedirectedNamedCommand = function( commandName, commandParameter )
- {
- if ( commandName == 'InsertOrderedList' || commandName == 'InsertUnorderedList' )
- {
- if ( !(FCK.EditorDocument.queryCommandState( 'InsertOrderedList' ) || FCK.EditorDocument.queryCommandState( 'InsertUnorderedList' )) )
- {
- }
- }
-
- FCK.ExecuteNamedCommand( commandName, commandParameter ) ;
- }
-}
-*/
-
-FCK.Paste = function()
-{
- if ( FCKConfig.ForcePasteAsPlainText )
- {
- FCK.PasteAsPlainText() ;
- return false ;
- }
- else if ( FCKConfig.AutoDetectPasteFromWord )
- {
- var sHTML = FCK.GetClipboardHTML() ;
- var re = /<\w[^>]*(( class="?MsoNormal"?)|(="mso-))/gi ;
- if ( re.test( sHTML ) )
- {
- if ( confirm( FCKLang["PasteWordConfirm"] ) )
- {
- FCK.PasteFromWord() ;
- return false ;
- }
- }
- }
- else
- return true ;
-}
-
-FCK.PasteAsPlainText = function()
-{
- // Get the data available in the clipboard and encodes it in HTML.
- var sText = FCKTools.HTMLEncode( clipboardData.getData("Text") ) ;
-
- // Replace the carriage returns with
- sText = sText.replace( /\n/g, '
' ) ;
-
- // Insert the resulting data in the editor.
- this.InsertHtml( sText ) ;
-}
-/*
-FCK.PasteFromWord = function()
-{
- FCK.CleanAndPaste( FCK.GetClipboardHTML() ) ;
-}
-*/
-FCK.InsertElement = function( element )
-{
- FCK.InsertHtml( element.outerHTML ) ;
-}
-
-FCK.GetClipboardHTML = function()
-{
- var oDiv = document.getElementById( '___FCKHiddenDiv' ) ;
-
- if ( !oDiv )
- {
- var oDiv = document.createElement( 'DIV' ) ;
- oDiv.id = '___FCKHiddenDiv' ;
- oDiv.style.visibility = 'hidden' ;
- oDiv.style.overflow = 'hidden' ;
- oDiv.style.position = 'absolute' ;
- oDiv.style.width = 1 ;
- oDiv.style.height = 1 ;
-
- document.body.appendChild( oDiv ) ;
- }
-
- oDiv.innerHTML = '' ;
-
- var oTextRange = document.body.createTextRange() ;
- oTextRange.moveToElementText( oDiv ) ;
- oTextRange.execCommand( 'Paste' ) ;
-
- var sData = oDiv.innerHTML ;
- oDiv.innerHTML = '' ;
-
- return sData ;
-}
-
-FCK.AttachToOnSelectionChange = function( functionPointer )
-{
- this.Events.AttachEvent( 'OnSelectionChange', functionPointer ) ;
-}
-
-/*
-FCK.AttachToOnSelectionChange = function( functionPointer )
-{
- FCK.EditorDocument.attachEvent( 'onselectionchange', functionPointer ) ;
-}
-*/
-
-FCK.CreateLink = function( url )
-{
- FCK.ExecuteNamedCommand( 'Unlink' ) ;
-
- if ( url.length > 0 )
- {
- // Generate a temporary name for the link.
- var sTempUrl = 'javascript:void(0);/*' + ( new Date().getTime() ) + '*/' ;
-
- // Use the internal "CreateLink" command to create the link.
- FCK.ExecuteNamedCommand( 'CreateLink', sTempUrl ) ;
-
- // Loof for the just create link.
- var oLinks = this.EditorDocument.links ;
-
- for ( i = 0 ; i < oLinks.length ; i++ )
- {
- if ( oLinks[i].href == sTempUrl )
- {
- oLinks[i].href = url ;
- return oLinks[i] ;
- }
- }
- }
-}
diff --git a/htdocs/includes/fckeditor/editor/_source/internals/fck_contextmenu.js b/htdocs/includes/fckeditor/editor/_source/internals/fck_contextmenu.js
deleted file mode 100644
index cd181f5d870..00000000000
--- a/htdocs/includes/fckeditor/editor/_source/internals/fck_contextmenu.js
+++ /dev/null
@@ -1,287 +0,0 @@
-/*
- * FCKeditor - The text editor for internet
- * Copyright (C) 2003-2006 Frederico Caldeira Knabben
- *
- * Licensed under the terms of the GNU Lesser General Public License:
- * http://www.opensource.org/licenses/lgpl-license.php
- *
- * For further information visit:
- * http://www.fckeditor.net/
- *
- * "Support Open Source software. What about a donation today?"
- *
- * File Name: fck_contextmenu.js
- * Defines the FCK.ContextMenu object that is responsible for all
- * Context Menu operations in the editing area.
- *
- * File Authors:
- * Frederico Caldeira Knabben (fredck@fckeditor.net)
- */
-
-FCK.ContextMenu = new Object() ;
-FCK.ContextMenu.Listeners = new Array() ;
-
-FCK.ContextMenu.RegisterListener = function( listener )
-{
- if ( listener )
- this.Listeners.push( listener ) ;
-}
-
-function FCK_ContextMenu_Init()
-{
- var oInnerContextMenu = FCK.ContextMenu._InnerContextMenu = new FCKContextMenu( FCKBrowserInfo.IsIE ? window : window.parent, FCK.EditorWindow, FCKLang.Dir ) ;
- oInnerContextMenu.OnBeforeOpen = FCK_ContextMenu_OnBeforeOpen ;
- oInnerContextMenu.OnItemClick = FCK_ContextMenu_OnItemClick ;
-
- // Get the registering function.
- var oMenu = FCK.ContextMenu ;
-
- // Register all configured context menu listeners.
- for ( var i = 0 ; i < FCKConfig.ContextMenu.length ; i++ )
- oMenu.RegisterListener( FCK_ContextMenu_GetListener( FCKConfig.ContextMenu[i] ) ) ;
-}
-
-function FCK_ContextMenu_GetListener( listenerName )
-{
- switch ( listenerName )
- {
- case 'Generic' :
- return {
- AddItems : function( menu, tag, tagName )
- {
- menu.AddItem( 'Cut' , FCKLang.Cut , 7, FCKCommands.GetCommand( 'Cut' ).GetState() == FCK_TRISTATE_DISABLED ) ;
- menu.AddItem( 'Copy' , FCKLang.Copy , 8, FCKCommands.GetCommand( 'Copy' ).GetState() == FCK_TRISTATE_DISABLED ) ;
- menu.AddItem( 'Paste' , FCKLang.Paste , 9, FCKCommands.GetCommand( 'Paste' ).GetState() == FCK_TRISTATE_DISABLED ) ;
- }} ;
-
- case 'Table' :
- return {
- AddItems : function( menu, tag, tagName )
- {
- var bIsTable = ( tagName == 'TABLE' ) ;
- var bIsCell = ( !bIsTable && FCKSelection.HasAncestorNode( 'TABLE' ) ) ;
-
- if ( bIsCell )
- {
- menu.AddSeparator() ;
- var oItem = menu.AddItem( 'Cell' , FCKLang.CellCM ) ;
- oItem.AddItem( 'TableInsertCell' , FCKLang.InsertCell, 58 ) ;
- oItem.AddItem( 'TableDeleteCells' , FCKLang.DeleteCells, 59 ) ;
- oItem.AddItem( 'TableMergeCells' , FCKLang.MergeCells, 60 ) ;
- oItem.AddItem( 'TableSplitCell' , FCKLang.SplitCell, 61 ) ;
- oItem.AddSeparator() ;
- oItem.AddItem( 'TableCellProp' , FCKLang.CellProperties, 57 ) ;
-
- menu.AddSeparator() ;
- oItem = menu.AddItem( 'Row' , FCKLang.RowCM ) ;
- oItem.AddItem( 'TableInsertRow' , FCKLang.InsertRow, 62 ) ;
- oItem.AddItem( 'TableDeleteRows' , FCKLang.DeleteRows, 63 ) ;
-
- menu.AddSeparator() ;
- oItem = menu.AddItem( 'Column' , FCKLang.ColumnCM ) ;
- oItem.AddItem( 'TableInsertColumn' , FCKLang.InsertColumn, 64 ) ;
- oItem.AddItem( 'TableDeleteColumns' , FCKLang.DeleteColumns, 65 ) ;
- }
-
- if ( bIsTable || bIsCell )
- {
- menu.AddSeparator() ;
- menu.AddItem( 'TableDelete' , FCKLang.TableDelete ) ;
- menu.AddItem( 'TableProp' , FCKLang.TableProperties, 39 ) ;
- }
- }} ;
-
- case 'Link' :
- return {
- AddItems : function( menu, tag, tagName )
- {
- if ( FCK.GetNamedCommandState( 'Unlink' ) != FCK_TRISTATE_DISABLED )
- {
- menu.AddSeparator() ;
- menu.AddItem( 'Link' , FCKLang.EditLink , 34 ) ;
- menu.AddItem( 'Unlink' , FCKLang.RemoveLink , 35 ) ;
- }
- }} ;
-
- case 'Image' :
- return {
- AddItems : function( menu, tag, tagName )
- {
- if ( tagName == 'IMG' && !tag.getAttribute( '_fckfakelement' ) )
- {
- menu.AddSeparator() ;
- menu.AddItem( 'Image', FCKLang.ImageProperties, 37 ) ;
- }
- }} ;
-
- case 'Anchor' :
- return {
- AddItems : function( menu, tag, tagName )
- {
- if ( tagName == 'IMG' && tag.getAttribute( '_fckanchor' ) )
- {
- menu.AddSeparator() ;
- menu.AddItem( 'Anchor', FCKLang.AnchorProp, 36 ) ;
- }
- }} ;
-
- case 'Flash' :
- return {
- AddItems : function( menu, tag, tagName )
- {
- if ( tagName == 'IMG' && tag.getAttribute( '_fckflash' ) )
- {
- menu.AddSeparator() ;
- menu.AddItem( 'Flash', FCKLang.FlashProperties, 38 ) ;
- }
- }} ;
-
- case 'Form' :
- return {
- AddItems : function( menu, tag, tagName )
- {
- if ( FCKSelection.HasAncestorNode('FORM') )
- {
- menu.AddSeparator() ;
- menu.AddItem( 'Form', FCKLang.FormProp, 48 ) ;
- }
- }} ;
-
- case 'Checkbox' :
- return {
- AddItems : function( menu, tag, tagName )
- {
- if ( tagName == 'INPUT' && tag.type == 'checkbox' )
- {
- menu.AddSeparator() ;
- menu.AddItem( 'Checkbox', FCKLang.CheckboxProp, 49 ) ;
- }
- }} ;
-
- case 'Radio' :
- return {
- AddItems : function( menu, tag, tagName )
- {
- if ( tagName == 'INPUT' && tag.type == 'radio' )
- {
- menu.AddSeparator() ;
- menu.AddItem( 'Radio', FCKLang.RadioButtonProp, 50 ) ;
- }
- }} ;
-
- case 'TextField' :
- return {
- AddItems : function( menu, tag, tagName )
- {
- if ( tagName == 'INPUT' && ( tag.type == 'text' || tag.type == 'password' ) )
- {
- menu.AddSeparator() ;
- menu.AddItem( 'TextField', FCKLang.TextFieldProp, 51 ) ;
- }
- }} ;
-
- case 'HiddenField' :
- return {
- AddItems : function( menu, tag, tagName )
- {
- if ( tagName == 'INPUT' && tag.type == 'hidden' )
- {
- menu.AddSeparator() ;
- menu.AddItem( 'HiddenField', FCKLang.HiddenFieldProp, 56 ) ;
- }
- }} ;
-
- case 'ImageButton' :
- return {
- AddItems : function( menu, tag, tagName )
- {
- if ( tagName == 'INPUT' && tag.type == 'image' )
- {
- menu.AddSeparator() ;
- menu.AddItem( 'ImageButton', FCKLang.ImageButtonProp, 55 ) ;
- }
- }} ;
-
- case 'Button' :
- return {
- AddItems : function( menu, tag, tagName )
- {
- if ( tagName == 'INPUT' && ( tag.type == 'button' || tag.type == 'submit' || tag.type == 'reset' ) )
- {
- menu.AddSeparator() ;
- menu.AddItem( 'Button', FCKLang.ButtonProp, 54 ) ;
- }
- }} ;
-
- case 'Select' :
- return {
- AddItems : function( menu, tag, tagName )
- {
- if ( tagName == 'SELECT' )
- {
- menu.AddSeparator() ;
- menu.AddItem( 'Select', FCKLang.SelectionFieldProp, 53 ) ;
- }
- }} ;
-
- case 'Textarea' :
- return {
- AddItems : function( menu, tag, tagName )
- {
- if ( tagName == 'TEXTAREA' )
- {
- menu.AddSeparator() ;
- menu.AddItem( 'Textarea', FCKLang.TextareaProp, 52 ) ;
- }
- }} ;
-
- case 'BulletedList' :
- return {
- AddItems : function( menu, tag, tagName )
- {
- if ( FCKSelection.HasAncestorNode('UL') )
- {
- menu.AddSeparator() ;
- menu.AddItem( 'BulletedList', FCKLang.BulletedListProp, 27 ) ;
- }
- }} ;
-
- case 'NumberedList' :
- return {
- AddItems : function( menu, tag, tagName )
- {
- if ( FCKSelection.HasAncestorNode('OL') )
- {
- menu.AddSeparator() ;
- menu.AddItem( 'NumberedList', FCKLang.NumberedListProp, 26 ) ;
- }
- }} ;
- }
-}
-
-function FCK_ContextMenu_OnBeforeOpen()
-{
- // Update the UI.
- FCK.Events.FireEvent( "OnSelectionChange" ) ;
-
- // Get the actual selected tag (if any).
- var oTag, sTagName ;
-
- if ( oTag = FCKSelection.GetSelectedElement() )
- sTagName = oTag.tagName ;
-
- // Cleanup the current menu items.
- var oMenu = FCK.ContextMenu._InnerContextMenu ;
- oMenu.RemoveAllItems() ;
-
- // Loop through the listeners.
- var aListeners = FCK.ContextMenu.Listeners ;
- for ( var i = 0 ; i < aListeners.length ; i++ )
- aListeners[i].AddItems( oMenu, oTag, sTagName ) ;
-}
-
-function FCK_ContextMenu_OnItemClick( item )
-{
- FCK.Focus() ;
- FCKCommands.GetCommand( item.Name ).Execute() ;
-}
\ No newline at end of file
diff --git a/htdocs/includes/fckeditor/editor/_source/internals/fckbrowserinfo.js b/htdocs/includes/fckeditor/editor/_source/internals/fckbrowserinfo.js
deleted file mode 100644
index d0e22e346e8..00000000000
--- a/htdocs/includes/fckeditor/editor/_source/internals/fckbrowserinfo.js
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * FCKeditor - The text editor for internet
- * Copyright (C) 2003-2006 Frederico Caldeira Knabben
- *
- * Licensed under the terms of the GNU Lesser General Public License:
- * http://www.opensource.org/licenses/lgpl-license.php
- *
- * For further information visit:
- * http://www.fckeditor.net/
- *
- * "Support Open Source software. What about a donation today?"
- *
- * File Name: fckbrowserinfo.js
- * Contains browser detection information.
- *
- * File Authors:
- * Frederico Caldeira Knabben (fredck@fckeditor.net)
- */
-
-var s = navigator.userAgent.toLowerCase() ;
-
-var FCKBrowserInfo =
-{
- IsIE : s.Contains('msie'),
- IsIE7 : s.Contains('msie 7'),
- IsGecko : s.Contains('gecko/'),
- IsSafari : s.Contains('safari'),
- IsOpera : s.Contains('opera')
-}
-
-FCKBrowserInfo.IsGeckoLike = FCKBrowserInfo.IsGecko || FCKBrowserInfo.IsSafari || FCKBrowserInfo.IsOpera ;
-
-if ( FCKBrowserInfo.IsGecko )
-{
- var sGeckoVersion = s.match( /gecko\/(\d+)/ )[1] ;
- FCKBrowserInfo.IsGecko10 = sGeckoVersion < 20051111 ; // Actually "10" refers to versions before Firefox 1.5, where Gecko 20051111 has been released.
-}
\ No newline at end of file
diff --git a/htdocs/includes/fckeditor/editor/_source/internals/fckcodeformatter.js b/htdocs/includes/fckeditor/editor/_source/internals/fckcodeformatter.js
deleted file mode 100644
index f4a59e00cbe..00000000000
--- a/htdocs/includes/fckeditor/editor/_source/internals/fckcodeformatter.js
+++ /dev/null
@@ -1,96 +0,0 @@
-/*
- * FCKeditor - The text editor for internet
- * Copyright (C) 2003-2006 Frederico Caldeira Knabben
- *
- * Licensed under the terms of the GNU Lesser General Public License:
- * http://www.opensource.org/licenses/lgpl-license.php
- *
- * For further information visit:
- * http://www.fckeditor.net/
- *
- * "Support Open Source software. What about a donation today?"
- *
- * File Name: fckcodeformatter.js
- * Format the HTML.
- *
- * File Authors:
- * Frederico Caldeira Knabben (fredck@fckeditor.net)
- */
-
-var FCKCodeFormatter = new Object() ;
-
-FCKCodeFormatter.Init = function()
-{
- var oRegex = this.Regex = new Object() ;
-
- // Regex for line breaks.
- oRegex.BlocksOpener = /\<(P|DIV|H1|H2|H3|H4|H5|H6|ADDRESS|PRE|OL|UL|LI|TITLE|META|LINK|BASE|SCRIPT|LINK|TD|TH|AREA|OPTION)[^\>]*\>/gi ;
- oRegex.BlocksCloser = /\<\/(P|DIV|H1|H2|H3|H4|H5|H6|ADDRESS|PRE|OL|UL|LI|TITLE|META|LINK|BASE|SCRIPT|LINK|TD|TH|AREA|OPTION)[^\>]*\>/gi ;
-
- oRegex.NewLineTags = /\<(BR|HR)[^\>]*\>/gi ;
-
- oRegex.MainTags = /\<\/?(HTML|HEAD|BODY|FORM|TABLE|TBODY|THEAD|TR)[^\>]*\>/gi ;
-
- oRegex.LineSplitter = /\s*\n+\s*/g ;
-
- // Regex for indentation.
- oRegex.IncreaseIndent = /^\<(HTML|HEAD|BODY|FORM|TABLE|TBODY|THEAD|TR|UL|OL)[ \/\>]/i ;
- oRegex.DecreaseIndent = /^\<\/(HTML|HEAD|BODY|FORM|TABLE|TBODY|THEAD|TR|UL|OL)[ \>]/i ;
- oRegex.FormatIndentatorRemove = new RegExp( '^' + FCKConfig.FormatIndentator ) ;
-
- oRegex.ProtectedTags = /(]*>)([\s\S]*?)(<\/PRE>)/gi ;
-}
-
-FCKCodeFormatter._ProtectData = function( outer, opener, data, closer )
-{
- return opener + '___FCKpd___' + FCKCodeFormatter.ProtectedData.AddItem( data ) + closer ;
-}
-
-FCKCodeFormatter.Format = function( html )
-{
- if ( !this.Regex )
- this.Init() ;
-
- // Protected content that remain untouched during the
- // process go in the following array.
- FCKCodeFormatter.ProtectedData = new Array() ;
-
- var sFormatted = html.replace( this.Regex.ProtectedTags, FCKCodeFormatter._ProtectData ) ;
-
- // Line breaks.
- sFormatted = sFormatted.replace( this.Regex.BlocksOpener, '\n$&' ) ; ;
- sFormatted = sFormatted.replace( this.Regex.BlocksCloser, '$&\n' ) ;
- sFormatted = sFormatted.replace( this.Regex.NewLineTags, '$&\n' ) ;
- sFormatted = sFormatted.replace( this.Regex.MainTags, '\n$&\n' ) ;
-
- // Indentation.
- var sIndentation = '' ;
-
- var asLines = sFormatted.split( this.Regex.LineSplitter ) ;
- sFormatted = '' ;
-
- for ( var i = 0 ; i < asLines.length ; i++ )
- {
- var sLine = asLines[i] ;
-
- if ( sLine.length == 0 )
- continue ;
-
- if ( this.Regex.DecreaseIndent.test( sLine ) )
- sIndentation = sIndentation.replace( this.Regex.FormatIndentatorRemove, '' ) ;
-
- sFormatted += sIndentation + sLine + '\n' ;
-
- if ( this.Regex.IncreaseIndent.test( sLine ) )
- sIndentation += FCKConfig.FormatIndentator ;
- }
-
- // Now we put back the protected data.
- for ( var i = 0 ; i < FCKCodeFormatter.ProtectedData.length ; i++ )
- {
- var oRegex = new RegExp( '___FCKpd___' + i ) ;
- sFormatted = sFormatted.replace( oRegex, FCKCodeFormatter.ProtectedData[i].replace( /\$/g, '$$$$' ) ) ;
- }
-
- return sFormatted.trim() ;
-}
\ No newline at end of file
diff --git a/htdocs/includes/fckeditor/editor/_source/internals/fckcommands.js b/htdocs/includes/fckeditor/editor/_source/internals/fckcommands.js
deleted file mode 100644
index 0ad66647a63..00000000000
--- a/htdocs/includes/fckeditor/editor/_source/internals/fckcommands.js
+++ /dev/null
@@ -1,126 +0,0 @@
-/*
- * FCKeditor - The text editor for internet
- * Copyright (C) 2003-2006 Frederico Caldeira Knabben
- *
- * Licensed under the terms of the GNU Lesser General Public License:
- * http://www.opensource.org/licenses/lgpl-license.php
- *
- * For further information visit:
- * http://www.fckeditor.net/
- *
- * "Support Open Source software. What about a donation today?"
- *
- * File Name: fckcommands.js
- * Define all commands available in the editor.
- *
- * File Authors:
- * Frederico Caldeira Knabben (fredck@fckeditor.net)
- */
-
-var FCKCommands = FCK.Commands = new Object() ;
-FCKCommands.LoadedCommands = new Object() ;
-
-FCKCommands.RegisterCommand = function( commandName, command )
-{
- this.LoadedCommands[ commandName ] = command ;
-}
-
-FCKCommands.GetCommand = function( commandName )
-{
- var oCommand = FCKCommands.LoadedCommands[ commandName ] ;
-
- if ( oCommand )
- return oCommand ;
-
- switch ( commandName )
- {
- case 'DocProps' : oCommand = new FCKDialogCommand( 'DocProps' , FCKLang.DocProps , 'dialog/fck_docprops.html' , 400, 390, FCKCommands.GetFullPageState ) ; break ;
- case 'Templates' : oCommand = new FCKDialogCommand( 'Templates' , FCKLang.DlgTemplatesTitle , 'dialog/fck_template.html' , 380, 450 ) ; break ;
- case 'Link' : oCommand = new FCKDialogCommand( 'Link' , FCKLang.DlgLnkWindowTitle , 'dialog/fck_link.html' , 400, 330, FCK.GetNamedCommandState, 'CreateLink' ) ; break ;
- case 'Unlink' : oCommand = new FCKUnlinkCommand() ; break ;
- case 'Anchor' : oCommand = new FCKDialogCommand( 'Anchor' , FCKLang.DlgAnchorTitle , 'dialog/fck_anchor.html' , 370, 170 ) ; break ;
- case 'BulletedList' : oCommand = new FCKDialogCommand( 'BulletedList', FCKLang.BulletedListProp , 'dialog/fck_listprop.html' , 370, 170 ) ; break ;
- case 'NumberedList' : oCommand = new FCKDialogCommand( 'NumberedList', FCKLang.NumberedListProp , 'dialog/fck_listprop.html' , 370, 170 ) ; break ;
- case 'About' : oCommand = new FCKDialogCommand( 'About' , FCKLang.About , 'dialog/fck_about.html' , 400, 330 ) ; break ;
-
- case 'Find' : oCommand = new FCKDialogCommand( 'Find' , FCKLang.DlgFindTitle , 'dialog/fck_find.html' , 340, 170 ) ; break ;
- case 'Replace' : oCommand = new FCKDialogCommand( 'Replace' , FCKLang.DlgReplaceTitle , 'dialog/fck_replace.html' , 340, 200 ) ; break ;
-
- case 'Image' : oCommand = new FCKDialogCommand( 'Image' , FCKLang.DlgImgTitle , 'dialog/fck_image.html' , 450, 400 ) ; break ;
- case 'Flash' : oCommand = new FCKDialogCommand( 'Flash' , FCKLang.DlgFlashTitle , 'dialog/fck_flash.html' , 450, 400 ) ; break ;
- case 'SpecialChar' : oCommand = new FCKDialogCommand( 'SpecialChar', FCKLang.DlgSpecialCharTitle , 'dialog/fck_specialchar.html' , 400, 320 ) ; break ;
- case 'Smiley' : oCommand = new FCKDialogCommand( 'Smiley' , FCKLang.DlgSmileyTitle , 'dialog/fck_smiley.html' , FCKConfig.SmileyWindowWidth, FCKConfig.SmileyWindowHeight ) ; break ;
- case 'Table' : oCommand = new FCKDialogCommand( 'Table' , FCKLang.DlgTableTitle , 'dialog/fck_table.html' , 450, 250 ) ; break ;
- case 'TableProp' : oCommand = new FCKDialogCommand( 'Table' , FCKLang.DlgTableTitle , 'dialog/fck_table.html?Parent', 400, 250 ) ; break ;
- case 'TableCellProp': oCommand = new FCKDialogCommand( 'TableCell' , FCKLang.DlgCellTitle , 'dialog/fck_tablecell.html' , 500, 250 ) ; break ;
- case 'UniversalKey' : oCommand = new FCKDialogCommand( 'UniversalKey', FCKLang.UniversalKeyboard , 'dialog/fck_universalkey.html', 415, 300 ) ; break ;
-
- case 'Style' : oCommand = new FCKStyleCommand() ; break ;
-
- case 'FontName' : oCommand = new FCKFontNameCommand() ; break ;
- case 'FontSize' : oCommand = new FCKFontSizeCommand() ; break ;
- case 'FontFormat' : oCommand = new FCKFormatBlockCommand() ; break ;
-
- case 'Source' : oCommand = new FCKSourceCommand() ; break ;
- case 'Preview' : oCommand = new FCKPreviewCommand() ; break ;
- case 'Save' : oCommand = new FCKSaveCommand() ; break ;
- case 'NewPage' : oCommand = new FCKNewPageCommand() ; break ;
- case 'PageBreak' : oCommand = new FCKPageBreakCommand() ; break ;
-
- case 'TextColor' : oCommand = new FCKTextColorCommand('ForeColor') ; break ;
- case 'BGColor' : oCommand = new FCKTextColorCommand('BackColor') ; break ;
-
- case 'PasteText' : oCommand = new FCKPastePlainTextCommand() ; break ;
- case 'PasteWord' : oCommand = new FCKPasteWordCommand() ; break ;
-
- case 'TableInsertRow' : oCommand = new FCKTableCommand('TableInsertRow') ; break ;
- case 'TableDeleteRows' : oCommand = new FCKTableCommand('TableDeleteRows') ; break ;
- case 'TableInsertColumn' : oCommand = new FCKTableCommand('TableInsertColumn') ; break ;
- case 'TableDeleteColumns' : oCommand = new FCKTableCommand('TableDeleteColumns') ; break ;
- case 'TableInsertCell' : oCommand = new FCKTableCommand('TableInsertCell') ; break ;
- case 'TableDeleteCells' : oCommand = new FCKTableCommand('TableDeleteCells') ; break ;
- case 'TableMergeCells' : oCommand = new FCKTableCommand('TableMergeCells') ; break ;
- case 'TableSplitCell' : oCommand = new FCKTableCommand('TableSplitCell') ; break ;
- case 'TableDelete' : oCommand = new FCKTableCommand('TableDelete') ; break ;
-
- case 'Form' : oCommand = new FCKDialogCommand( 'Form' , FCKLang.Form , 'dialog/fck_form.html' , 380, 230 ) ; break ;
- case 'Checkbox' : oCommand = new FCKDialogCommand( 'Checkbox' , FCKLang.Checkbox , 'dialog/fck_checkbox.html' , 380, 230 ) ; break ;
- case 'Radio' : oCommand = new FCKDialogCommand( 'Radio' , FCKLang.RadioButton , 'dialog/fck_radiobutton.html' , 380, 230 ) ; break ;
- case 'TextField' : oCommand = new FCKDialogCommand( 'TextField' , FCKLang.TextField , 'dialog/fck_textfield.html' , 380, 230 ) ; break ;
- case 'Textarea' : oCommand = new FCKDialogCommand( 'Textarea' , FCKLang.Textarea , 'dialog/fck_textarea.html' , 380, 230 ) ; break ;
- case 'HiddenField' : oCommand = new FCKDialogCommand( 'HiddenField', FCKLang.HiddenField , 'dialog/fck_hiddenfield.html' , 380, 230 ) ; break ;
- case 'Button' : oCommand = new FCKDialogCommand( 'Button' , FCKLang.Button , 'dialog/fck_button.html' , 380, 230 ) ; break ;
- case 'Select' : oCommand = new FCKDialogCommand( 'Select' , FCKLang.SelectionField, 'dialog/fck_select.html' , 400, 380 ) ; break ;
- case 'ImageButton' : oCommand = new FCKDialogCommand( 'ImageButton', FCKLang.ImageButton , 'dialog/fck_image.html?ImageButton', 450, 400 ) ; break ;
-
- case 'SpellCheck' : oCommand = new FCKSpellCheckCommand() ; break ;
- case 'FitWindow' : oCommand = new FCKFitWindow() ; break ;
-
- case 'Undo' : oCommand = new FCKUndoCommand() ; break ;
- case 'Redo' : oCommand = new FCKRedoCommand() ; break ;
-
- // Generic Undefined command (usually used when a command is under development).
- case 'Undefined' : oCommand = new FCKUndefinedCommand() ; break ;
-
- // By default we assume that it is a named command.
- default:
- if ( FCKRegexLib.NamedCommands.test( commandName ) )
- oCommand = new FCKNamedCommand( commandName ) ;
- else
- {
- alert( FCKLang.UnknownCommand.replace( /%1/g, commandName ) ) ;
- return null ;
- }
- }
-
- FCKCommands.LoadedCommands[ commandName ] = oCommand ;
-
- return oCommand ;
-}
-
-// Gets the state of the "Document Properties" button. It must be enabled only
-// when "Full Page" editing is available.
-FCKCommands.GetFullPageState = function()
-{
- return FCKConfig.FullPage ? FCK_TRISTATE_OFF : FCK_TRISTATE_DISABLED ;
-}
diff --git a/htdocs/includes/fckeditor/editor/_source/internals/fckconfig.js b/htdocs/includes/fckeditor/editor/_source/internals/fckconfig.js
deleted file mode 100644
index 793f5a4b9a0..00000000000
--- a/htdocs/includes/fckeditor/editor/_source/internals/fckconfig.js
+++ /dev/null
@@ -1,175 +0,0 @@
-/*
- * FCKeditor - The text editor for internet
- * Copyright (C) 2003-2006 Frederico Caldeira Knabben
- *
- * Licensed under the terms of the GNU Lesser General Public License:
- * http://www.opensource.org/licenses/lgpl-license.php
- *
- * For further information visit:
- * http://www.fckeditor.net/
- *
- * "Support Open Source software. What about a donation today?"
- *
- * File Name: fckconfig.js
- * Creates and initializes the FCKConfig object.
- *
- * File Authors:
- * Frederico Caldeira Knabben (fredck@fckeditor.net)
- */
-
-var FCKConfig = FCK.Config = new Object() ;
-
-/*
- For the next major version (probably 3.0) we should move all this stuff to
- another dedicated object and leave FCKConfig as a holder object for settings only).
-*/
-
-// Editor Base Path
-if ( document.location.protocol == 'file:' )
-{
- FCKConfig.BasePath = unescape( document.location.pathname.substr(1) ) ;
- FCKConfig.BasePath = FCKConfig.BasePath.replace( /\\/gi, '/' ) ;
- FCKConfig.BasePath = 'file://' + FCKConfig.BasePath.substring(0,FCKConfig.BasePath.lastIndexOf('/')+1) ;
- FCKConfig.FullBasePath = FCKConfig.BasePath ;
-}
-else
-{
- FCKConfig.BasePath = document.location.pathname.substring(0,document.location.pathname.lastIndexOf('/')+1) ;
- FCKConfig.FullBasePath = document.location.protocol + '//' + document.location.host + FCKConfig.BasePath ;
-}
-
-FCKConfig.EditorPath = FCKConfig.BasePath.replace( /editor\/$/, '' ) ;
-
-// There is a bug in Gecko. If the editor is hidden on startup, an error is
-// thrown when trying to get the screen dimentions.
-try
-{
- FCKConfig.ScreenWidth = screen.width ;
- FCKConfig.ScreenHeight = screen.height ;
-}
-catch (e)
-{
- FCKConfig.ScreenWidth = 800 ;
- FCKConfig.ScreenHeight = 600 ;
-}
-
-// Override the actual configuration values with the values passed throw the
-// hidden field "___Config".
-FCKConfig.ProcessHiddenField = function()
-{
- this.PageConfig = new Object() ;
-
- // Get the hidden field.
- var oConfigField = window.parent.document.getElementById( FCK.Name + '___Config' ) ;
-
- // Do nothing if the config field was not defined.
- if ( ! oConfigField ) return ;
-
- var aCouples = oConfigField.value.split('&') ;
-
- for ( var i = 0 ; i < aCouples.length ; i++ )
- {
- if ( aCouples[i].length == 0 )
- continue ;
-
- var aConfig = aCouples[i].split( '=' ) ;
- var sKey = unescape( aConfig[0] ) ;
- var sVal = unescape( aConfig[1] ) ;
-
- if ( sKey == 'CustomConfigurationsPath' ) // The Custom Config File path must be loaded immediately.
- FCKConfig[ sKey ] = sVal ;
-
- else if ( sVal.toLowerCase() == "true" ) // If it is a boolean TRUE.
- this.PageConfig[ sKey ] = true ;
-
- else if ( sVal.toLowerCase() == "false" ) // If it is a boolean FALSE.
- this.PageConfig[ sKey ] = false ;
-
- else if ( ! isNaN( sVal ) ) // If it is a number.
- this.PageConfig[ sKey ] = parseInt( sVal ) ;
-
- else // In any other case it is a string.
- this.PageConfig[ sKey ] = sVal ;
- }
-}
-
-function FCKConfig_LoadPageConfig()
-{
- var oPageConfig = FCKConfig.PageConfig ;
- for ( var sKey in oPageConfig )
- FCKConfig[ sKey ] = oPageConfig[ sKey ] ;
-}
-
-function FCKConfig_PreProcess()
-{
- var oConfig = FCKConfig ;
-
- // Force debug mode if fckdebug=true in the QueryString (main page).
- if ( oConfig.AllowQueryStringDebug && (/fckdebug=true/i).test( window.top.location.search ) )
- oConfig.Debug = true ;
-
- // Certifies that the "PluginsPath" configuration ends with a slash.
- if ( !oConfig.PluginsPath.endsWith('/') )
- oConfig.PluginsPath += '/' ;
-
- // EditorAreaCSS accepts an array of paths or a single path (as string).
- // In the last case, transform it in an array.
- if ( typeof( oConfig.EditorAreaCSS ) == 'string' )
- oConfig.EditorAreaCSS = [ oConfig.EditorAreaCSS ] ;
-}
-
-// Define toolbar sets collection.
-FCKConfig.ToolbarSets = new Object() ;
-
-// Defines the plugins collection.
-FCKConfig.Plugins = new Object() ;
-FCKConfig.Plugins.Items = new Array() ;
-
-FCKConfig.Plugins.Add = function( name, langs, path )
-{
- FCKConfig.Plugins.Items.AddItem( [name, langs, path] ) ;
-}
-
-// FCKConfig.ProtectedSource: object that holds a collection of Regular
-// Expressions that defined parts of the raw HTML that must remain untouched
-// like custom tags, scripts, server side code, etc...
-FCKConfig.ProtectedSource = new Object() ;
-FCKConfig.ProtectedSource.RegexEntries = new Array() ;
-
-FCKConfig.ProtectedSource.Add = function( regexPattern )
-{
- this.RegexEntries.AddItem( regexPattern ) ;
-}
-
-FCKConfig.ProtectedSource.Protect = function( html )
-{
- function _Replace( protectedSource )
- {
- var index = FCKTempBin.AddElement( protectedSource ) ;
- return '' ;
- }
-
- for ( var i = 0 ; i < this.RegexEntries.length ; i++ )
- {
- html = html.replace( this.RegexEntries[i], _Replace ) ;
- }
-
- return html ;
-}
-
-
-FCKConfig.ProtectedSource.Revert = function( html, clearBin )
-{
- function _Replace( m, opener, index )
- {
- var protectedValue = clearBin ? FCKTempBin.RemoveElement( index ) : FCKTempBin.Elements[ index ] ;
- // There could be protected source inside another one.
- return FCKConfig.ProtectedSource.Revert( protectedValue, clearBin ) ;
- }
-
- return html.replace( /(<|<)!--\{PS..(\d+)\}--(>|>)/g, _Replace ) ;
-}
-
-// First of any other protection, we must protect all comments to avoid
-// loosing them (of course, IE related).
-FCKConfig.ProtectedSource.Add( //g ) ;
\ No newline at end of file
diff --git a/htdocs/includes/fckeditor/editor/_source/internals/fckdebug.js b/htdocs/includes/fckeditor/editor/_source/internals/fckdebug.js
deleted file mode 100644
index 78b1b352174..00000000000
--- a/htdocs/includes/fckeditor/editor/_source/internals/fckdebug.js
+++ /dev/null
@@ -1,77 +0,0 @@
-/*
- * FCKeditor - The text editor for internet
- * Copyright (C) 2003-2006 Frederico Caldeira Knabben
- *
- * Licensed under the terms of the GNU Lesser General Public License:
- * http://www.opensource.org/licenses/lgpl-license.php
- *
- * For further information visit:
- * http://www.fckeditor.net/
- *
- * "Support Open Source software. What about a donation today?"
- *
- * File Name: fckdebug.js
- * Debug window control and operations.
- *
- * File Authors:
- * Frederico Caldeira Knabben (fredck@fckeditor.net)
- */
-
-var FCKDebug = new Object() ;
-
-FCKDebug.Output = function( message, color, noParse )
-{
- if ( ! FCKConfig.Debug ) return ;
-
- if ( !noParse && message != null && isNaN( message ) )
- message = message.replace(/' ;
-
- for (var prop in anyObject)
- {
- try
- {
- var sVal = anyObject[ prop ] ? anyObject[ prop ] + '' : '[null]' ;
- message += '' + prop + ' : ' + sVal.replace(/' ;
- }
- catch (e)
- {
- try
- {
- message += '' + prop + ' : [' + typeof( anyObject[ prop ] ) + ']
' ;
- }
- catch (e)
- {
- message += '' + prop + ' : [-error-]
' ;
- }
- }
- }
-
- message += '
' ;
- } else
- message = 'OutputObject : Object is "null".' ;
-
- FCKDebug.Output( message, color, true ) ;
-}
\ No newline at end of file
diff --git a/htdocs/includes/fckeditor/editor/_source/internals/fckdialog.js b/htdocs/includes/fckeditor/editor/_source/internals/fckdialog.js
deleted file mode 100644
index c84f13d1944..00000000000
--- a/htdocs/includes/fckeditor/editor/_source/internals/fckdialog.js
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * FCKeditor - The text editor for internet
- * Copyright (C) 2003-2006 Frederico Caldeira Knabben
- *
- * Licensed under the terms of the GNU Lesser General Public License:
- * http://www.opensource.org/licenses/lgpl-license.php
- *
- * For further information visit:
- * http://www.fckeditor.net/
- *
- * "Support Open Source software. What about a donation today?"
- *
- * File Name: fckdialog.js
- * Dialog windows operations.
- *
- * File Authors:
- * Frederico Caldeira Knabben (fredck@fckeditor.net)
- */
-
-var FCKDialog = new Object() ;
-
-// This method opens a dialog window using the standard dialog template.
-FCKDialog.OpenDialog = function( dialogName, dialogTitle, dialogPage, width, height, customValue, parentWindow, resizable )
-{
- // Setup the dialog info.
- var oDialogInfo = new Object() ;
- oDialogInfo.Title = dialogTitle ;
- oDialogInfo.Page = dialogPage ;
- oDialogInfo.Editor = window ;
- oDialogInfo.CustomValue = customValue ; // Optional
-
- var sUrl = FCKConfig.BasePath + 'fckdialog.html' ;
- this.Show( oDialogInfo, dialogName, sUrl, width, height, parentWindow, resizable ) ;
-}
diff --git a/htdocs/includes/fckeditor/editor/_source/internals/fckdialog_gecko.js b/htdocs/includes/fckeditor/editor/_source/internals/fckdialog_gecko.js
deleted file mode 100644
index ce7b4b776fc..00000000000
--- a/htdocs/includes/fckeditor/editor/_source/internals/fckdialog_gecko.js
+++ /dev/null
@@ -1,101 +0,0 @@
-/*
- * FCKeditor - The text editor for internet
- * Copyright (C) 2003-2006 Frederico Caldeira Knabben
- *
- * Licensed under the terms of the GNU Lesser General Public License:
- * http://www.opensource.org/licenses/lgpl-license.php
- *
- * For further information visit:
- * http://www.fckeditor.net/
- *
- * "Support Open Source software. What about a donation today?"
- *
- * File Name: fckdialog_gecko.js
- * Dialog windows operations. (Gecko specific implementations)
- *
- * File Authors:
- * Frederico Caldeira Knabben (fredck@fckeditor.net)
- */
-
-FCKDialog.Show = function( dialogInfo, dialogName, pageUrl, dialogWidth, dialogHeight, parentWindow, resizable )
-{
- var iTop = (FCKConfig.ScreenHeight - dialogHeight) / 2 ;
- var iLeft = (FCKConfig.ScreenWidth - dialogWidth) / 2 ;
-
- var sOption = "location=no,menubar=no,toolbar=no,dependent=yes,dialog=yes,minimizable=no,modal=yes,alwaysRaised=yes" +
- ",resizable=" + ( resizable ? 'yes' : 'no' ) +
- ",width=" + dialogWidth +
- ",height=" + dialogHeight +
- ",top=" + iTop +
- ",left=" + iLeft ;
-
- if ( !parentWindow )
- parentWindow = window ;
-
- FCKFocusManager.Lock() ;
-
- var oWindow = parentWindow.open( '', 'FCKeditorDialog_' + dialogName, sOption, true ) ;
-
- if ( !oWindow )
- {
- alert( FCKLang.DialogBlocked ) ;
- FCKFocusManager.Unlock() ;
- return ;
- }
-
- oWindow.moveTo( iLeft, iTop ) ;
- oWindow.resizeTo( dialogWidth, dialogHeight ) ;
- oWindow.focus() ;
- oWindow.location.href = pageUrl ;
-
- oWindow.dialogArguments = dialogInfo ;
-
- // On some Gecko browsers (probably over slow connections) the
- // "dialogArguments" are not set to the target window so we must
- // put it in the opener window so it can be used by the target one.
- parentWindow.FCKLastDialogInfo = dialogInfo ;
-
- this.Window = oWindow ;
-
- // Try/Catch must be used to avoit an error when using a frameset
- // on a different domain:
- // "Permission denied to get property Window.releaseEvents".
- try
- {
- window.top.captureEvents( Event.CLICK | Event.MOUSEDOWN | Event.MOUSEUP | Event.FOCUS ) ;
- window.top.parent.addEventListener( 'mousedown', this.CheckFocus, true ) ;
- window.top.parent.addEventListener( 'mouseup', this.CheckFocus, true ) ;
- window.top.parent.addEventListener( 'click', this.CheckFocus, true ) ;
- window.top.parent.addEventListener( 'focus', this.CheckFocus, true ) ;
- }
- catch (e)
- {}
-}
-
-FCKDialog.CheckFocus = function()
-{
- // It is strange, but we have to check the FCKDialog existence to avoid a
- // random error: "FCKDialog is not defined".
- if ( typeof( FCKDialog ) != "object" )
- return false ;
-
- if ( FCKDialog.Window && !FCKDialog.Window.closed )
- FCKDialog.Window.focus() ;
- else
- {
- // Try/Catch must be used to avoit an error when using a frameset
- // on a different domain:
- // "Permission denied to get property Window.releaseEvents".
- try
- {
- window.top.releaseEvents(Event.CLICK | Event.MOUSEDOWN | Event.MOUSEUP | Event.FOCUS) ;
- window.top.parent.removeEventListener( 'onmousedown', FCKDialog.CheckFocus, true ) ;
- window.top.parent.removeEventListener( 'mouseup', FCKDialog.CheckFocus, true ) ;
- window.top.parent.removeEventListener( 'click', FCKDialog.CheckFocus, true ) ;
- window.top.parent.removeEventListener( 'onfocus', FCKDialog.CheckFocus, true ) ;
- }
- catch (e)
- {}
- }
- return false ;
-}
diff --git a/htdocs/includes/fckeditor/editor/_source/internals/fckdialog_ie.js b/htdocs/includes/fckeditor/editor/_source/internals/fckdialog_ie.js
deleted file mode 100644
index 2de32396340..00000000000
--- a/htdocs/includes/fckeditor/editor/_source/internals/fckdialog_ie.js
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * FCKeditor - The text editor for internet
- * Copyright (C) 2003-2006 Frederico Caldeira Knabben
- *
- * Licensed under the terms of the GNU Lesser General Public License:
- * http://www.opensource.org/licenses/lgpl-license.php
- *
- * For further information visit:
- * http://www.fckeditor.net/
- *
- * "Support Open Source software. What about a donation today?"
- *
- * File Name: fckdialog_ie.js
- * Dialog windows operations. (IE specific implementations)
- *
- * File Authors:
- * Frederico Caldeira Knabben (fredck@fckeditor.net)
- */
-
-FCKDialog.Show = function( dialogInfo, dialogName, pageUrl, dialogWidth, dialogHeight, parentWindow )
-{
- if ( !parentWindow )
- parentWindow = window ;
-
- FCKFocusManager.Lock() ;
-
- var oReturn = parentWindow.showModalDialog( pageUrl, dialogInfo, "dialogWidth:" + dialogWidth + "px;dialogHeight:" + dialogHeight + "px;help:no;scroll:no;status:no") ;
-
- if ( !oReturn )
- alert( FCKLang.DialogBlocked ) ;
-
- FCKFocusManager.Unlock() ;
-}
diff --git a/htdocs/includes/fckeditor/editor/_source/internals/fckdocumentprocessor.js b/htdocs/includes/fckeditor/editor/_source/internals/fckdocumentprocessor.js
deleted file mode 100644
index 2b59faec6bd..00000000000
--- a/htdocs/includes/fckeditor/editor/_source/internals/fckdocumentprocessor.js
+++ /dev/null
@@ -1,230 +0,0 @@
-/*
- * FCKeditor - The text editor for internet
- * Copyright (C) 2003-2006 Frederico Caldeira Knabben
- *
- * Licensed under the terms of the GNU Lesser General Public License:
- * http://www.opensource.org/licenses/lgpl-license.php
- *
- * For further information visit:
- * http://www.fckeditor.net/
- *
- * "Support Open Source software. What about a donation today?"
- *
- * File Name: fckdocumentprocessor.js
- * Advanced document processors.
- *
- * File Authors:
- * Frederico Caldeira Knabben (fredck@fckeditor.net)
- */
-
-var FCKDocumentProcessor = new Object() ;
-FCKDocumentProcessor._Items = new Array() ;
-
-FCKDocumentProcessor.AppendNew = function()
-{
- var oNewItem = new Object() ;
- this._Items.AddItem( oNewItem ) ;
- return oNewItem ;
-}
-
-FCKDocumentProcessor.Process = function( document )
-{
- var oProcessor, i = 0 ;
- while( ( oProcessor = this._Items[i++] ) )
- oProcessor.ProcessDocument( document ) ;
-}
-
-var FCKDocumentProcessor_CreateFakeImage = function( fakeClass, realElement )
-{
- var oImg = FCK.EditorDocument.createElement( 'IMG' ) ;
- oImg.className = fakeClass ;
- oImg.src = FCKConfig.FullBasePath + 'images/spacer.gif' ;
- oImg.setAttribute( '_fckfakelement', 'true', 0 ) ;
- oImg.setAttribute( '_fckrealelement', FCKTempBin.AddElement( realElement ), 0 ) ;
- return oImg ;
-}
-
-// Link Anchors
-var FCKAnchorsProcessor = FCKDocumentProcessor.AppendNew() ;
-FCKAnchorsProcessor.ProcessDocument = function( document )
-{
- var aLinks = document.getElementsByTagName( 'A' ) ;
-
- var oLink ;
- var i = aLinks.length - 1 ;
- while ( i >= 0 && ( oLink = aLinks[i--] ) )
- {
- // If it is anchor.
- if ( oLink.name.length > 0 && ( !oLink.getAttribute('href') || oLink.getAttribute('href').length == 0 ) )
- {
- var oImg = FCKDocumentProcessor_CreateFakeImage( 'FCK__Anchor', oLink.cloneNode(true) ) ;
- oImg.setAttribute( '_fckanchor', 'true', 0 ) ;
-
- oLink.parentNode.insertBefore( oImg, oLink ) ;
- oLink.parentNode.removeChild( oLink ) ;
- }
- }
-}
-
-// Page Breaks
-var FCKPageBreaksProcessor = FCKDocumentProcessor.AppendNew() ;
-FCKPageBreaksProcessor.ProcessDocument = function( document )
-{
- var aDIVs = document.getElementsByTagName( 'DIV' ) ;
-
- var eDIV ;
- var i = aDIVs.length - 1 ;
- while ( i >= 0 && ( eDIV = aDIVs[i--] ) )
- {
- if ( eDIV.style.pageBreakAfter == 'always' && eDIV.childNodes.length == 1 && eDIV.childNodes[0].style && eDIV.childNodes[0].style.display == 'none' )
- {
- var oFakeImage = FCKDocumentProcessor_CreateFakeImage( 'FCK__PageBreak', eDIV.cloneNode(true) ) ;
-
- eDIV.parentNode.insertBefore( oFakeImage, eDIV ) ;
- eDIV.parentNode.removeChild( eDIV ) ;
- }
- }
-/*
- var aCenters = document.getElementsByTagName( 'CENTER' ) ;
-
- var oCenter ;
- var i = aCenters.length - 1 ;
- while ( i >= 0 && ( oCenter = aCenters[i--] ) )
- {
- if ( oCenter.style.pageBreakAfter == 'always' && oCenter.innerHTML.trim().length == 0 )
- {
- var oFakeImage = FCKDocumentProcessor_CreateFakeImage( 'FCK__PageBreak', oCenter.cloneNode(true) ) ;
-
- oCenter.parentNode.insertBefore( oFakeImage, oCenter ) ;
- oCenter.parentNode.removeChild( oCenter ) ;
- }
- }
-*/
-}
-
-// Flash Embeds.
-var FCKFlashProcessor = FCKDocumentProcessor.AppendNew() ;
-FCKFlashProcessor.ProcessDocument = function( document )
-{
- /*
- Sample code:
- This is some sample text. You are using FCKeditor.
- */
-
- var aEmbeds = document.getElementsByTagName( 'EMBED' ) ;
-
- var oEmbed ;
- var i = aEmbeds.length - 1 ;
- while ( i >= 0 && ( oEmbed = aEmbeds[i--] ) )
- {
- if ( oEmbed.src.endsWith( '.swf', true ) )
- {
- var oCloned = oEmbed.cloneNode( true ) ;
-
- // On IE, some properties are not getting clonned properly, so we
- // must fix it. Thanks to Alfonso Martinez.
- if ( FCKBrowserInfo.IsIE )
- {
- var oAtt ;
- if ( oAtt = oEmbed.getAttribute( 'scale' ) ) oCloned.setAttribute( 'scale', oAtt ) ;
- if ( oAtt = oEmbed.getAttribute( 'play' ) ) oCloned.setAttribute( 'play', oAtt ) ;
- if ( oAtt = oEmbed.getAttribute( 'loop' ) ) oCloned.setAttribute( 'loop', oAtt ) ;
- if ( oAtt = oEmbed.getAttribute( 'menu' ) ) oCloned.setAttribute( 'menu', oAtt ) ;
- if ( oAtt = oEmbed.getAttribute( 'wmode' ) ) oCloned.setAttribute( 'wmode', oAtt ) ;
- if ( oAtt = oEmbed.getAttribute( 'quality' ) ) oCloned.setAttribute( 'quality', oAtt ) ;
- }
-
- var oImg = FCKDocumentProcessor_CreateFakeImage( 'FCK__Flash', oCloned ) ;
- oImg.setAttribute( '_fckflash', 'true', 0 ) ;
-
- FCKFlashProcessor.RefreshView( oImg, oEmbed ) ;
-
- oEmbed.parentNode.insertBefore( oImg, oEmbed ) ;
- oEmbed.parentNode.removeChild( oEmbed ) ;
-
-// oEmbed.setAttribute( '_fckdelete', 'true', 0) ;
-// oEmbed.style.display = 'none' ;
-// oEmbed.hidden = true ;
- }
- }
-}
-
-FCKFlashProcessor.RefreshView = function( placholderImage, originalEmbed )
-{
- if ( originalEmbed.width > 0 )
- placholderImage.style.width = FCKTools.ConvertHtmlSizeToStyle( originalEmbed.width ) ;
-
- if ( originalEmbed.height > 0 )
- placholderImage.style.height = FCKTools.ConvertHtmlSizeToStyle( originalEmbed.height ) ;
-}
-
-FCK.GetRealElement = function( fakeElement )
-{
- var e = FCKTempBin.Elements[ fakeElement.getAttribute('_fckrealelement') ] ;
-
- if ( fakeElement.getAttribute('_fckflash') )
- {
- if ( fakeElement.style.width.length > 0 )
- e.width = FCKTools.ConvertStyleSizeToHtml( fakeElement.style.width ) ;
-
- if ( fakeElement.style.height.length > 0 )
- e.height = FCKTools.ConvertStyleSizeToHtml( fakeElement.style.height ) ;
- }
-
- return e ;
-}
-
-// START iCM MODIFICATIONS
-/*
-var FCKTablesProcessor = FCKDocumentProcessor.AppendNew() ;
-FCKTablesProcessor.ProcessDocument = function( document )
-{
- FCKTablesProcessor.CheckTablesNesting( document ) ;
-}
-
-// Ensure that tables are not incorrectly nested within P, H1, H2, etc tags
-FCKTablesProcessor.CheckTablesNesting = function( document )
-{
- var aTables = document.getElementsByTagName( "TABLE" ) ;
- var oParentNode ;
-
- for ( var i=0; i= 5 )
- {
- sUserLang = sUserLang.substr(0,5) ;
- if ( this.AvailableLanguages[sUserLang] ) return sUserLang ;
- }
-
- // If the user's browser is set to, for example, "pt-br" but only the
- // "pt" language file is available then get that file.
- if ( sUserLang.length >= 2 )
- {
- sUserLang = sUserLang.substr(0,2) ;
- if ( this.AvailableLanguages[sUserLang] ) return sUserLang ;
- }
- }
-
- return this.DefaultLanguage ;
-}
-
-FCKLanguageManager.TranslateElements = function( targetDocument, tag, propertyToSet, encode )
-{
- var e = targetDocument.getElementsByTagName(tag) ;
- var sKey, s ;
- for ( var i = 0 ; i < e.length ; i++ )
- {
- if ( sKey = e[i].getAttribute( 'fckLang' ) )
- {
- if ( s = FCKLang[ sKey ] )
- {
- if ( encode )
- s = FCKTools.HTMLEncode( s ) ;
- eval( 'e[i].' + propertyToSet + ' = s' ) ;
- }
- }
- }
-}
-
-FCKLanguageManager.TranslatePage = function( targetDocument )
-{
- this.TranslateElements( targetDocument, 'INPUT', 'value' ) ;
- this.TranslateElements( targetDocument, 'SPAN', 'innerHTML' ) ;
- this.TranslateElements( targetDocument, 'LABEL', 'innerHTML' ) ;
- this.TranslateElements( targetDocument, 'OPTION', 'innerHTML', true ) ;
-}
-
-FCKLanguageManager.Initialize = function()
-{
- if ( this.AvailableLanguages[ FCKConfig.DefaultLanguage ] )
- this.DefaultLanguage = FCKConfig.DefaultLanguage ;
- else
- this.DefaultLanguage = 'en' ;
-
- this.ActiveLanguage = new Object() ;
- this.ActiveLanguage.Code = this.GetActiveLanguage() ;
- this.ActiveLanguage.Name = this.AvailableLanguages[ this.ActiveLanguage.Code ] ;
-}
\ No newline at end of file