[svn r17790] FS#2867 - FCKEditor: Upgrading to version 2.6.4 Beta, 15-JAN-2009.

skala
Ivan Tcholakov 17 years ago
parent 1ec06d423e
commit bd5b8b519d
  1. 2
      main/inc/lib/fckeditor/_documentation.html
  2. 2
      main/inc/lib/fckeditor/_upgrade.html
  3. 139
      main/inc/lib/fckeditor/_whatsnew.html
  4. 4
      main/inc/lib/fckeditor/_whatsnew_history.html
  5. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckcontextmenu.js
  6. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckdataprocessor.js
  7. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckdocumentfragment_gecko.js
  8. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckdocumentfragment_ie.js
  9. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckdomrange.js
  10. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckdomrange_gecko.js
  11. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckdomrange_ie.js
  12. 271
      main/inc/lib/fckeditor/editor/_source/classes/fckdomrangeinterator.js
  13. 4
      main/inc/lib/fckeditor/editor/_source/classes/fckdomrangeiterator.js
  14. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckeditingarea.js
  15. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckelementpath.js
  16. 8
      main/inc/lib/fckeditor/editor/_source/classes/fckenterkey.js
  17. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckevents.js
  18. 4
      main/inc/lib/fckeditor/editor/_source/classes/fckhtmliterator.js
  19. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckicon.js
  20. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckiecleanup.js
  21. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckimagepreloader.js
  22. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckkeystrokehandler.js
  23. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckmenublock.js
  24. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckmenublockpanel.js
  25. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckmenuitem.js
  26. 10
      main/inc/lib/fckeditor/editor/_source/classes/fckpanel.js
  27. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckplugin.js
  28. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckspecialcombo.js
  29. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckstyle.js
  30. 59
      main/inc/lib/fckeditor/editor/_source/classes/fckstyledef.js
  31. 119
      main/inc/lib/fckeditor/editor/_source/classes/fckstyledef_gecko.js
  32. 142
      main/inc/lib/fckeditor/editor/_source/classes/fckstyledef_ie.js
  33. 88
      main/inc/lib/fckeditor/editor/_source/classes/fckstylesloader.js
  34. 2
      main/inc/lib/fckeditor/editor/_source/classes/fcktoolbar.js
  35. 2
      main/inc/lib/fckeditor/editor/_source/classes/fcktoolbarbreak_gecko.js
  36. 2
      main/inc/lib/fckeditor/editor/_source/classes/fcktoolbarbreak_ie.js
  37. 2
      main/inc/lib/fckeditor/editor/_source/classes/fcktoolbarbutton.js
  38. 2
      main/inc/lib/fckeditor/editor/_source/classes/fcktoolbarbuttonui.js
  39. 2
      main/inc/lib/fckeditor/editor/_source/classes/fcktoolbarfontformatcombo.js
  40. 2
      main/inc/lib/fckeditor/editor/_source/classes/fcktoolbarfontscombo.js
  41. 2
      main/inc/lib/fckeditor/editor/_source/classes/fcktoolbarfontsizecombo.js
  42. 2
      main/inc/lib/fckeditor/editor/_source/classes/fcktoolbarpanelbutton.js
  43. 2
      main/inc/lib/fckeditor/editor/_source/classes/fcktoolbarspecialcombo.js
  44. 2
      main/inc/lib/fckeditor/editor/_source/classes/fcktoolbarstylecombo.js
  45. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckw3crange.js
  46. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckxml.js
  47. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckxml_gecko.js
  48. 2
      main/inc/lib/fckeditor/editor/_source/classes/fckxml_ie.js
  49. 4
      main/inc/lib/fckeditor/editor/_source/commandclasses/fck_othercommands.js
  50. 2
      main/inc/lib/fckeditor/editor/_source/commandclasses/fckblockquotecommand.js
  51. 2
      main/inc/lib/fckeditor/editor/_source/commandclasses/fckcorestylecommand.js
  52. 2
      main/inc/lib/fckeditor/editor/_source/commandclasses/fckfitwindow.js
  53. 2
      main/inc/lib/fckeditor/editor/_source/commandclasses/fckindentcommands.js
  54. 2
      main/inc/lib/fckeditor/editor/_source/commandclasses/fckjustifycommands.js
  55. 2
      main/inc/lib/fckeditor/editor/_source/commandclasses/fcklistcommands.js
  56. 2
      main/inc/lib/fckeditor/editor/_source/commandclasses/fcknamedcommand.js
  57. 2
      main/inc/lib/fckeditor/editor/_source/commandclasses/fckpasteplaintextcommand.js
  58. 2
      main/inc/lib/fckeditor/editor/_source/commandclasses/fckpastewordcommand.js
  59. 2
      main/inc/lib/fckeditor/editor/_source/commandclasses/fckremoveformatcommand.js
  60. 2
      main/inc/lib/fckeditor/editor/_source/commandclasses/fckshowblocks.js
  61. 14
      main/inc/lib/fckeditor/editor/_source/commandclasses/fckspellcheckcommand_gecko.js
  62. 7
      main/inc/lib/fckeditor/editor/_source/commandclasses/fckspellcheckcommand_ie.js
  63. 2
      main/inc/lib/fckeditor/editor/_source/commandclasses/fckstylecommand.js
  64. 2
      main/inc/lib/fckeditor/editor/_source/commandclasses/fcktablecommand.js
  65. 2
      main/inc/lib/fckeditor/editor/_source/commandclasses/fcktextcolorcommand.js
  66. 2
      main/inc/lib/fckeditor/editor/_source/fckconstants.js
  67. 6
      main/inc/lib/fckeditor/editor/_source/fckeditorapi.js
  68. 2
      main/inc/lib/fckeditor/editor/_source/fckjscoreextensions.js
  69. 2
      main/inc/lib/fckeditor/editor/_source/fckscriptloader.js
  70. 2
      main/inc/lib/fckeditor/editor/_source/internals/fck.js
  71. 2
      main/inc/lib/fckeditor/editor/_source/internals/fck_contextmenu.js
  72. 9
      main/inc/lib/fckeditor/editor/_source/internals/fck_gecko.js
  73. 2
      main/inc/lib/fckeditor/editor/_source/internals/fck_ie.js
  74. 2
      main/inc/lib/fckeditor/editor/_source/internals/fckbrowserinfo.js
  75. 4
      main/inc/lib/fckeditor/editor/_source/internals/fckcodeformatter.js
  76. 2
      main/inc/lib/fckeditor/editor/_source/internals/fckcommands.js
  77. 2
      main/inc/lib/fckeditor/editor/_source/internals/fckconfig.js
  78. 2
      main/inc/lib/fckeditor/editor/_source/internals/fckdebug.js
  79. 2
      main/inc/lib/fckeditor/editor/_source/internals/fckdebug_empty.js
  80. 2
      main/inc/lib/fckeditor/editor/_source/internals/fckdialog.js
  81. 103
      main/inc/lib/fckeditor/editor/_source/internals/fckdialog_gecko.js
  82. 49
      main/inc/lib/fckeditor/editor/_source/internals/fckdialog_ie.js
  83. 4
      main/inc/lib/fckeditor/editor/_source/internals/fckdocumentprocessor.js
  84. 2
      main/inc/lib/fckeditor/editor/_source/internals/fckdomtools.js
  85. 2
      main/inc/lib/fckeditor/editor/_source/internals/fcklanguagemanager.js
  86. 2
      main/inc/lib/fckeditor/editor/_source/internals/fcklisthandler.js
  87. 2
      main/inc/lib/fckeditor/editor/_source/internals/fcklistslib.js
  88. 2
      main/inc/lib/fckeditor/editor/_source/internals/fckplugins.js
  89. 2
      main/inc/lib/fckeditor/editor/_source/internals/fckregexlib.js
  90. 2
      main/inc/lib/fckeditor/editor/_source/internals/fckselection.js
  91. 2
      main/inc/lib/fckeditor/editor/_source/internals/fckselection_gecko.js
  92. 6
      main/inc/lib/fckeditor/editor/_source/internals/fckselection_ie.js
  93. 2
      main/inc/lib/fckeditor/editor/_source/internals/fckstyles.js
  94. 104
      main/inc/lib/fckeditor/editor/_source/internals/fcktablehandler.js
  95. 2
      main/inc/lib/fckeditor/editor/_source/internals/fcktablehandler_gecko.js
  96. 2
      main/inc/lib/fckeditor/editor/_source/internals/fcktablehandler_ie.js
  97. 2
      main/inc/lib/fckeditor/editor/_source/internals/fcktoolbaritems.js
  98. 2
      main/inc/lib/fckeditor/editor/_source/internals/fcktoolbarset.js
  99. 2
      main/inc/lib/fckeditor/editor/_source/internals/fcktools.js
  100. 2
      main/inc/lib/fckeditor/editor/_source/internals/fcktools_gecko.js
  101. Some files were not shown because too many files have changed in this diff Show More

@ -1,7 +1,7 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!--
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,7 +1,7 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!--
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,7 +1,7 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!--
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*
@ -33,54 +33,62 @@
<h1>
FCKeditor ChangeLog - What's New?</h1>
<h3>
Version 2.6.4 (SVN)</h3>
Version 2.6.4 Beta</h3>
<p>
New Features and Improvements:</p>
<ul>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2430">#2430</a>] In the table
dialog it's possible to create header cells in the first row (included in a thead element)
or the first column of the table. </li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/822">#822</a>] The table cell
dialog allows to switch between normal data cells or header cells (TD vs TH). </li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2685">#2685</a>] Integration
with "WebSpellChecker", a <strong>zero installation and free spell checker</strong>
provided by SpellChecker.net. This is now the default spell checker in the editor
(requires internet connection). All previous spell checking solutions are still
available.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2430">#2430</a>] In the
table dialog it's possible to create header cells in the first row (included in
a thead element) or the first column of the table. </li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/822">#822</a>] The table
cell dialog allows switching between normal data cells or header cells (TD vs. TH).
</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2515">#2515</a>] New language
file for Icelandic.</li>
</ul>
<p>
Fixed Bugs:</p>
<ul>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2381">#2381</a>] Protected the editor
from duplicate iframes</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2381">#2381</a>] Protected
the editor from duplicate iframes</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/1752">#1752</a>] Fixed
the issue with Tablecommands plugin and undefined tagName.</li>
the issue with tablecommands plugin and undefined tagName.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2333">#2333</a>] The &amp;gt;
character inside text wasn't encoded in Opera and Safari.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2467">#2467</a>] Fixed JavaScript
error with the fit window command in source mode.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2472">#2472</a>] Splitting a TH
will create a two TH, not a TH and a TD.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2467">#2467</a>] Fixed
JavaScript error with the fit window command in source mode.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2472">#2472</a>] Splitting
a TH will create a two TH, not a TH and a TD.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/1891">#1891</a>] Removed
unnecessary name attributes in dialogs. </li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/798">#798</a>,
<a target="_blank" href="http://dev.fckeditor.net/ticket/2495">#2495</a>] If an image was
placed inside a container with dimensions or floating it wasn't possible to edit its
properties from the toolbar or context menu.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/1982">#1982</a>] Submenus in IE7
now are shown properly.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2496">#2496</a>] Using the Paste
dialogs in IE might insert the content at the start of the editor.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2349">#2496</a>] Fixed RTL dialog
layout in Internet Explorer.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2488">#2488</a>] Fixed the issue
where email links in IE would take the browser to a new page in addition to calling up the
email client.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2519">#2519</a>] Fixed race
condition at registering the FCKeditorAPI object in multiple editor scenarios.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2525">#2525</a>] Fixed JavaScript
error in Google Chrome when StartupShowBlocks is set to true.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/798">#798</a>, <a target="_blank"
href="http://dev.fckeditor.net/ticket/2495">#2495</a>] If an image was placed inside
a container with dimensions or floating it wasn't possible to edit its properties
from the toolbar or context menu.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/1982">#1982</a>] Submenus
in IE7 now are shown properly.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2496">#2496</a>] Using
the Paste dialogs in IE might insert the content at the start of the editor.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2349">#2496</a>] Fixed
RTL dialog layout in Internet Explorer.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2488">#2488</a>] Fixed
the issue where email links in IE would take the browser to a new page in addition
to calling up the email client.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2519">#2519</a>] Fixed
race condition at registering the FCKeditorAPI object in multiple editor scenarios.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2525">#2525</a>] Fixed
JavaScript error in Google Chrome when StartupShowBlocks is set to true.</li>
<li>Language file updates for the following languages:
<ul>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2440">#2440</a>] Dutch</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2451">#2451</a>] Basque</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2208">#2535</a>] German
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2451">#2650</a>] Danish</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2208">#2535</a>] German
</li>
</ul>
</li>
@ -88,28 +96,51 @@
key will properly scroll to the cursor position when breaking long paragraphs.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2573">#2573</a>] The type
name in configurations for the ASP connector are now case sensitive.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2503">#2503</a>] DL, DT and DD where
missing the formatting in the generated HTML.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2516">#2516</a>] Replaced the
extension AddItem of Array with the standard "push" method.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2486">#2486</a>] Vertically splitting
cell with colspan &gt; 1 breaks table layout.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2597">#2597</a>] Fixed the issue
where dropping contents from outside of the editor doesn't work in Safari.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2412">#2412</a>] Fixed the issue
where FCK.InsertHtml() is no longer removing selected contents after content insertion
in Firefox.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2407">#2407</a>] Fixed the issue
where the Div container command and the blockquote command would break lists.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2469">#2469</a>] Fixed a minor
issue where FCK.SetData() may cause the editor to become unresponsive to the first click
after being defocused.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2611">#2611</a>] Fixed an extra slash
on quickupload of the asp connector.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2616">#2616</a>] Fixed another situation
where new elements were inserted at the beginning of the content in IE.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2634">#2634</a>] Fixed two obsolete
references to Array::AddItem() instances still in the code.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2503">#2503</a>] DL, DT
and DD where missing the formatting in the generated HTML.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2516">#2516</a>] Replaced
the extension AddItem of Array with the standard "push" method.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2486">#2486</a>] Vertically
splitting cell with colspan &gt; 1 breaks table layout.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2597">#2597</a>] Fixed
the issue where dropping contents from outside of the editor doesn't work in Safari.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2412">#2412</a>] Fixed
the issue where FCK.InsertHtml() is no longer removing selected contents after content
insertion in Firefox.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2407">#2407</a>] Fixed
the issue where the Div container command and the blockquote command would break
lists.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2469">#2469</a>] Fixed
a minor issue where FCK.SetData() may cause the editor to become unresponsive to
the first click after being defocused.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2611">#2611</a>] Fixed
an extra slash on quickupload of the asp connector.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2616">#2616</a>] Fixed
another situation where new elements were inserted at the beginning of the content
in IE.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2634">#2634</a>] Fixed
two obsolete references to Array::AddItem() instances still in the code.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2679">#2679</a>] Fixed
infinite loop problems with FCKDomRangeIterator class which causes some commands
to hang when applied to certain document structures.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2649">#2649</a>] Fixed
a JavaScript error in IE when user tries to search with the "Match whole word" option
enabled and the matched word is at exactly the end of document.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2603">#2603</a>] Changed
the <a href="http://docs.fckeditor.net/EMailProtection">EMailProtection</a> to "none"
for better compatibility.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2612">#2612</a>] The 'ForcePasteAsPlainText'
configuration option didn't work correctly in Safari and Chrome.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2696">#2696</a>] Fixed
non-working autogrow plugin.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2753">#2753</a>] Fixed
occasional exceptions in the dragersizetable plugin with IE.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/2653">#2653</a>] and [<a
target="_blank" href="http://dev.fckeditor.net/ticket/2733">#2733</a>] Enable undo
of changes to tables and table cells.</li>
<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/1865">#1865</a>] The context
menu is now working properly over the last row in a table with thead. Thanks to
Koen Willems.</li>
</ul>
<p>
<a href="_whatsnew_history.html">See previous versions history</a></p>

@ -1,7 +1,7 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!--
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*
@ -33,7 +33,7 @@
<h1>
FCKeditor ChangeLog - What's New?</h1>
<h3>
Version 2.6.3 (SVN)</h3>
Version 2.6.3</h3>
<p>
Fixed Bugs:</p>
<ul>

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,271 +0,0 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2007 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*
* Licensed under the terms of any of the following licenses at your
* choice:
*
* - GNU General Public License Version 2 or later (the "GPL")
* http://www.gnu.org/licenses/gpl.html
*
* - GNU Lesser General Public License Version 2.1 or later (the "LGPL")
* http://www.gnu.org/licenses/lgpl.html
*
* - Mozilla Public License Version 1.1 or later (the "MPL")
* http://www.mozilla.org/MPL/MPL-1.1.html
*
* == END LICENSE ==
*
* This class can be used to interate through nodes inside a range.
*
* During interation, the provided range can become invalid, due to document
* mutations, so CreateBookmark() used to restore it after processing, if
* needed.
*/
var FCKDomRangeInterator = function( range )
{
/**
* The FCKDomRange object that marks the interation boundaries.
*/
this.Range = range ;
/**
* Indicates that <br> elements must be used as paragraph boundaries.
*/
this.ForceBrBreak = false ;
/**
* Guarantees that the interator will always return "real" block elements.
* If "false", elements like <li>, <th> and <td> are returned. If "true", a
* dedicated block element block element will be created inside those
* elements to hold the selected content.
*/
this.EnforceRealBlocks = false ;
}
FCKDomRangeInterator.CreateFromSelection = function( targetWindow )
{
var range = new FCKDomRange( targetWindow ) ;
range.MoveToSelection() ;
return new FCKDomRangeInterator( range ) ;
}
FCKDomRangeInterator.prototype =
{
/**
* Get the next paragraph element. It automatically breaks the document
* when necessary to generate block elements for the paragraphs.
*/
GetNextParagraph : function()
{
var block ;
var range ;
var isLast ;
var boundarySet = this.ForceBrBreak ? FCKListsLib.ListBoundaries : FCKListsLib.BlockBoundaries ;
// This is the first interaction. Let's initialize it.
if ( !this._LastNode )
{
var range = this.Range.Clone() ;
range.Expand( this.ForceBrBreak ? 'list_contents' : 'block_contents' ) ;
this._NextNode = range.StartNode ;
this._LastNode = range.EndNode ;
// Let's reuse this variable.
range = null ;
}
var currentNode = this._NextNode ;
var lastNode = this._LastNode ;
while ( currentNode )
{
// closeRange indicates that a paragraph boundary has been found,
// so the range can be closed.
var closeRange = false ;
// includeNode indicates that the current node is good to be part
// of the range. By default, any non-element node is ok for it.
var includeNode = ( currentNode.nodeType != 1 ) ;
var continueFromSibling = false ;
// If it is an element node, let's check if it can be part of the
// range.
if ( !includeNode )
{
var nodeName = currentNode.nodeName.toLowerCase() ;
if ( boundarySet[ nodeName ] )
{
// <br> boundaries must be part of the range. It will
// happen only if ForceBrBreak.
if ( nodeName == 'br' )
includeNode = true ;
else if ( !range && currentNode.childNodes.length == 0 && nodeName != 'hr' )
{
// If we have found an empty block, and haven't started
// the range yet, it means we must return this block.
block = currentNode ;
break ;
}
closeRange = true ;
}
else
{
// If we have child nodes, let's check them.
if ( currentNode.firstChild )
{
// If we don't have a range yet, let's start it.
if ( !range )
{
range = new FCKDomRange( this.Range.Window ) ;
range.SetStart( currentNode, 3, true ) ;
}
currentNode = currentNode.firstChild ;
continue ;
}
includeNode = true ;
}
}
else if ( currentNode.nodeType == 3 )
{
// Ignore normal whitespaces (i.e. not including &nbsp; or
// other unicode whitespaces) before/after a block node.
if ( /^[\r\n\t ]+$/.test( currentNode.nodeValue ) )
includeNode = false ;
}
// The current node is good to be part of the range and we are
// starting a new range, initialize it first.
if ( includeNode && !range )
{
range = new FCKDomRange( this.Range.Window ) ;
range.SetStart( currentNode, 3, true ) ;
}
// The last node has been found.
isLast = ( currentNode == lastNode ) ;
// If we are in an element boundary, let's check if it is time
// to close the range, otherwise we include the parent within it.
if ( range && !closeRange )
{
var parentNode = currentNode.parentNode ;
while ( currentNode == parentNode.lastChild && !isLast )
{
if ( boundarySet[ parentNode.nodeName.toLowerCase() ] )
{
closeRange = true ;
break ;
}
currentNode = parentNode ;
continueFromSibling = true ;
}
}
// Now finally include the node.
if ( includeNode )
range.SetEnd( currentNode, 4, true ) ;
// We have found a block boundary. Let's close the range and move out of the
// loop.
if ( ( closeRange && range ) || isLast )
{
if ( range )
range._UpdateElementInfo() ;
break ;
}
currentNode = FCKDomTools.GetNextSourceNode( currentNode, continueFromSibling ) ;
}
// Now, based on the processed range, look for (or create) the block to be returned.
if ( !block )
{
// If no range has been found, this is the end.
if ( !range )
{
this._NextNode = null ;
return null ;
}
block = range.StartBlock ;
if ( !block
&& !this.EnforceRealBlocks
&& range.StartBlockLimit.nodeName.IEquals( 'DIV', 'TH', 'TD' )
&& range.CheckStartOfBlock()
&& range.CheckEndOfBlock() )
{
block = range.StartBlockLimit ;
}
else if ( !block || ( this.EnforceRealBlocks && block.nodeName.toLowerCase() == 'li' ) )
{
// Create the fixed block.
block = this.Range.Window.document.createElement( FCKConfig.EnterMode == 'p' ? 'p' : 'div' ) ;
// Move the contents of the temporary range to the fixed block.
range.ExtractContents().AppendTo( block ) ;
FCKDomTools.TrimNode( block ) ;
// Insert the fixed block into the DOM.
range.InsertNode( block ) ;
// When fixing a block, we can safely remove any remaining <br>
// before of it.
var previousSibling = block.previousSibling ;
if ( previousSibling && previousSibling.nodeType == 1 && previousSibling.nodeName.toLowerCase() == 'br' )
previousSibling.parentNode.removeChild( previousSibling ) ;
}
else if ( block.nodeName.toLowerCase() != 'li' )
{
// If the range doesn't includes the entire contents of the
// block, we must split it, isolating the range in a dedicated
// block.
if ( !range.CheckStartOfBlock() || !range.CheckEndOfBlock() )
{
// The resulting block will be a clone of the current one.
block = block.cloneNode( false ) ;
// Extract the range contents, moving it to the new block.
range.ExtractContents().AppendTo( block ) ;
FCKDomTools.TrimNode( block ) ;
// Split the block. At this point, the range will be in the
// right position for our intents.
range.SplitBlock() ;
// Insert the new block into the DOM.
range.InsertNode( block ) ;
}
}
else if ( !isLast )
{
// LIs are returned as is, with all their children (due to the
// nested lists). But, the next node is the node right after
// the current range, which could be an <li> child (nested
// lists) or the next sibling <li>.
this._NextNode = FCKDomTools.GetNextSourceNode( range.EndNode, true ) ;
return block ;
}
}
// Get a reference for the next element. This is important because the
// above block can be removed or changed, so we can rely on it for the
// next interation.
this._NextNode = isLast ? null : FCKDomTools.GetNextSourceNode( block, true ) ;
return block ;
}
} ;

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*
@ -136,7 +136,7 @@ FCKDomRangeIterator.prototype =
// The found boundary must be set as the next one at this
// point. (#1717)
if ( nodeName != 'br' )
this._NextNode = FCKDomTools.GetNextSourceNode( currentNode, true, null, lastNode ) ;
this._NextNode = FCKDomTools.GetNextSourceNode( currentNode, true, null, lastNode ) || currentNode ;
}
closeRange = true ;

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*
@ -537,10 +537,10 @@ FCKEnterKey.prototype._ExecuteEnterBlock = function( blockTag, range )
// If we have split the block, adds a temporary span at the
// range position and scroll relatively to it.
var tmpNode = this.Window.document.createElement( 'span' ) ;
// We need some content for Safari.
tmpNode.innerHTML = '&nbsp;';
oRange.InsertNode( tmpNode ) ;
FCKDomTools.ScrollIntoView( tmpNode, false ) ;
oRange.DeleteContents() ;
@ -552,7 +552,7 @@ FCKEnterKey.prototype._ExecuteEnterBlock = function( blockTag, range )
FCKDomTools.ScrollIntoView( eNextBlock || eNewBlock, false ) ;
}
}
oRange.Select() ;
}

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*
@ -71,7 +71,7 @@ FCKHtmlIterator.prototype =
} ;
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*
@ -149,8 +149,8 @@ FCKPanel.prototype.ResizeForSubpanel = function( panel, width, height )
if (this.Subpanel !== panel)
return false ;
// Reset values.
// We leave the IncreasedY untouched to avoid vertical movement of the
// Reset values.
// We leave the IncreasedY untouched to avoid vertical movement of the
// menu if the submenu is higher than the main menu.
this.Subpanel = null ;
this.IncreasedX = 0 ;
@ -170,8 +170,8 @@ FCKPanel.prototype.ResizeForSubpanel = function( panel, width, height )
var w = this.IncreasedX ;
if ( this.IsRTL )
x = x - w ;
// Horizontally increase as needed (sum of widths).
// Horizontally increase as needed (sum of widths).
// Vertically, use only the maximum of this menu or the submenu
var finalWidth = this.ShowRect.w + w ;
var finalHeight = Math.max( this.ShowRect.h, this.IncreasedY ) ;

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,59 +0,0 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2007 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*
* Licensed under the terms of any of the following licenses at your
* choice:
*
* - GNU General Public License Version 2 or later (the "GPL")
* http://www.gnu.org/licenses/gpl.html
*
* - GNU Lesser General Public License Version 2.1 or later (the "LGPL")
* http://www.gnu.org/licenses/lgpl.html
*
* - Mozilla Public License Version 1.1 or later (the "MPL")
* http://www.mozilla.org/MPL/MPL-1.1.html
*
* == END LICENSE ==
*
* FCKStyleDef Class: represents a single style definition.
*/
var FCKStyleDef = function( name, element )
{
this.Name = name ;
this.Element = element.toUpperCase() ;
this.IsObjectElement = FCKRegexLib.ObjectElements.test( this.Element ) ;
this.Attributes = new Object() ;
}
FCKStyleDef.prototype.AddAttribute = function( name, value )
{
this.Attributes[ name ] = value ;
}
FCKStyleDef.prototype.GetOpenerTag = function()
{
var s = '<' + this.Element ;
for ( var a in this.Attributes )
s += ' ' + a + '="' + this.Attributes[a] + '"' ;
return s + '>' ;
}
FCKStyleDef.prototype.GetCloserTag = function()
{
return '</' + this.Element + '>' ;
}
FCKStyleDef.prototype.RemoveFromSelection = function()
{
if ( FCKSelection.GetType() == 'Control' )
this._RemoveMe( FCK.ToolbarSet.CurrentInstance.Selection.GetSelectedElement() ) ;
else
this._RemoveMe( FCK.ToolbarSet.CurrentInstance.Selection.GetParentElement() ) ;
}

@ -1,119 +0,0 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2007 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*
* Licensed under the terms of any of the following licenses at your
* choice:
*
* - GNU General Public License Version 2 or later (the "GPL")
* http://www.gnu.org/licenses/gpl.html
*
* - GNU Lesser General Public License Version 2.1 or later (the "LGPL")
* http://www.gnu.org/licenses/lgpl.html
*
* - Mozilla Public License Version 1.1 or later (the "MPL")
* http://www.mozilla.org/MPL/MPL-1.1.html
*
* == END LICENSE ==
*
* FCKStyleDef Class: represents a single style definition. (Gecko specific)
*/
FCKStyleDef.prototype.ApplyToSelection = function()
{
if ( FCKSelection.GetType() == 'Text' && !this.IsObjectElement )
{
var oSelection = FCK.ToolbarSet.CurrentInstance.EditorWindow.getSelection() ;
// Create the main element.
var e = FCK.ToolbarSet.CurrentInstance.EditorDocument.createElement( this.Element ) ;
for ( var i = 0 ; i < oSelection.rangeCount ; i++ )
{
e.appendChild( oSelection.getRangeAt(i).extractContents() ) ;
}
// Set the attributes.
this._AddAttributes( e ) ;
// Remove the duplicated elements.
this._RemoveDuplicates( e ) ;
var oRange = oSelection.getRangeAt(0) ;
oRange.insertNode( e ) ;
}
else
{
var oControl = FCK.ToolbarSet.CurrentInstance.Selection.GetSelectedElement() ;
if ( oControl.tagName == this.Element )
this._AddAttributes( oControl ) ;
}
}
FCKStyleDef.prototype._AddAttributes = function( targetElement )
{
for ( var a in this.Attributes )
{
switch ( a.toLowerCase() )
{
case 'src' :
targetElement.setAttribute( '_fcksavedurl', this.Attributes[a], 0 ) ;
default :
targetElement.setAttribute( a, this.Attributes[a], 0 ) ;
}
}
}
FCKStyleDef.prototype._RemoveDuplicates = function( parent )
{
for ( var i = 0 ; i < parent.childNodes.length ; i++ )
{
var oChild = parent.childNodes[i] ;
if ( oChild.nodeType != 1 )
continue ;
this._RemoveDuplicates( oChild ) ;
if ( this.IsEqual( oChild ) )
FCKTools.RemoveOuterTags( oChild ) ;
}
}
FCKStyleDef.prototype.IsEqual = function( e )
{
if ( e.tagName != this.Element )
return false ;
for ( var a in this.Attributes )
{
if ( e.getAttribute( a ) != this.Attributes[a] )
return false ;
}
return true ;
}
FCKStyleDef.prototype._RemoveMe = function( elementToCheck )
{
if ( ! elementToCheck )
return ;
var oParent = elementToCheck.parentNode ;
if ( elementToCheck.nodeType == 1 && this.IsEqual( elementToCheck ) )
{
if ( this.IsObjectElement )
{
for ( var a in this.Attributes )
elementToCheck.removeAttribute( a, 0 ) ;
return ;
}
else
FCKTools.RemoveOuterTags( elementToCheck ) ;
}
this._RemoveMe( oParent ) ;
}

@ -1,142 +0,0 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2007 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*
* Licensed under the terms of any of the following licenses at your
* choice:
*
* - GNU General Public License Version 2 or later (the "GPL")
* http://www.gnu.org/licenses/gpl.html
*
* - GNU Lesser General Public License Version 2.1 or later (the "LGPL")
* http://www.gnu.org/licenses/lgpl.html
*
* - Mozilla Public License Version 1.1 or later (the "MPL")
* http://www.mozilla.org/MPL/MPL-1.1.html
*
* == END LICENSE ==
*
* FCKStyleDef Class: represents a single style definition. (IE specific)
*/
FCKStyleDef.prototype.ApplyToSelection = function()
{
var oSelection = FCK.ToolbarSet.CurrentInstance.EditorDocument.selection ;
if ( oSelection.type == 'Text' )
{
var oRange = oSelection.createRange() ;
// Create the main element.
var e = document.createElement( this.Element ) ;
e.innerHTML = oRange.htmlText ;
// Set the attributes.
this._AddAttributes( e ) ;
// Remove the duplicated elements.
this._RemoveDuplicates( e ) ;
// Replace the selection with the resulting HTML.
oRange.pasteHTML( e.outerHTML ) ;
}
else if ( oSelection.type == 'Control' )
{
var oControl = FCK.ToolbarSet.CurrentInstance.Selection.GetSelectedElement() ;
if ( oControl.tagName == this.Element )
this._AddAttributes( oControl ) ;
}
}
FCKStyleDef.prototype._AddAttributes = function( targetElement )
{
for ( var a in this.Attributes )
{
switch ( a.toLowerCase() )
{
case 'style' :
targetElement.style.cssText = this.Attributes[a] ;
break ;
case 'class' :
targetElement.setAttribute( 'className', this.Attributes[a], 0 ) ;
break ;
case 'src' :
targetElement.setAttribute( '_fcksavedurl', this.Attributes[a], 0 ) ;
default :
targetElement.setAttribute( a, this.Attributes[a], 0 ) ;
}
}
}
FCKStyleDef.prototype._RemoveDuplicates = function( parent )
{
for ( var i = 0 ; i < parent.children.length ; i++ )
{
var oChild = parent.children[i] ;
this._RemoveDuplicates( oChild ) ;
if ( this.IsEqual( oChild ) )
FCKTools.RemoveOuterTags( oChild ) ;
}
}
FCKStyleDef.prototype.IsEqual = function( e )
{
if ( e.tagName != this.Element )
return false ;
for ( var a in this.Attributes )
{
switch ( a.toLowerCase() )
{
case 'style' :
if ( e.style.cssText.toLowerCase() != this.Attributes[a].toLowerCase() )
return false ;
break ;
case 'class' :
if ( e.getAttribute( 'className', 0 ) != this.Attributes[a] )
return false ;
break ;
default :
if ( e.getAttribute( a, 0 ) != this.Attributes[a] )
return false ;
}
}
return true ;
}
FCKStyleDef.prototype._RemoveMe = function( elementToCheck )
{
if ( ! elementToCheck )
return ;
var oParent = elementToCheck.parentElement ;
if ( this.IsEqual( elementToCheck ) )
{
if ( this.IsObjectElement )
{
for ( var a in this.Attributes )
{
switch ( a.toLowerCase() )
{
case 'class' :
elementToCheck.removeAttribute( 'className', 0 ) ;
break ;
default :
elementToCheck.removeAttribute( a, 0 ) ;
}
}
return ;
}
else
FCKTools.RemoveOuterTags( elementToCheck ) ;
}
this._RemoveMe( oParent ) ;
}

@ -1,88 +0,0 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2007 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*
* Licensed under the terms of any of the following licenses at your
* choice:
*
* - GNU General Public License Version 2 or later (the "GPL")
* http://www.gnu.org/licenses/gpl.html
*
* - GNU Lesser General Public License Version 2.1 or later (the "LGPL")
* http://www.gnu.org/licenses/lgpl.html
*
* - Mozilla Public License Version 1.1 or later (the "MPL")
* http://www.mozilla.org/MPL/MPL-1.1.html
*
* == END LICENSE ==
*
* FCKStylesLoader Class: this class define objects that are responsible
* for loading the styles defined in the XML file.
*/
var FCKStylesLoader = function()
{
this.Styles = new Object() ;
this.StyleGroups = new Object() ;
this.Loaded = false ;
this.HasObjectElements = false ;
}
FCKStylesLoader.prototype.Load = function( stylesXmlUrl )
{
// Load the XML file into a FCKXml object.
var oXml = new FCKXml() ;
oXml.LoadUrl( stylesXmlUrl ) ;
// Get the "Style" nodes defined in the XML file.
var aStyleNodes = oXml.SelectNodes( 'Styles/Style' ) ;
// Add each style to our "Styles" collection.
for ( var i = 0 ; i < aStyleNodes.length ; i++ )
{
var sElement = aStyleNodes[i].attributes.getNamedItem('element').value.toUpperCase() ;
// Create the style definition object.
var oStyleDef = new FCKStyleDef( aStyleNodes[i].attributes.getNamedItem('name').value, sElement ) ;
if ( oStyleDef.IsObjectElement )
this.HasObjectElements = true ;
// Get the attributes defined for the style (if any).
var aAttNodes = oXml.SelectNodes( 'Attribute', aStyleNodes[i] ) ;
// Add the attributes to the style definition object.
for ( var j = 0 ; j < aAttNodes.length ; j++ )
{
var sAttName = aAttNodes[j].attributes.getNamedItem('name').value ;
var sAttValue = aAttNodes[j].attributes.getNamedItem('value').value ;
// IE changes the "style" attribute value when applied to an element
// so we must get the final resulting value (for comparison issues).
if ( sAttName.toLowerCase() == 'style' )
{
var oTempE = document.createElement( 'SPAN' ) ;
oTempE.style.cssText = sAttValue ;
sAttValue = oTempE.style.cssText ;
}
oStyleDef.AddAttribute( sAttName, sAttValue ) ;
}
// Add the style to the "Styles" collection using it's name as the key.
this.Styles[ oStyleDef.Name ] = oStyleDef ;
// Add the style to the "StyleGroups" collection.
var aGroup = this.StyleGroups[sElement] ;
if ( aGroup == null )
{
this.StyleGroups[sElement] = new Array() ;
aGroup = this.StyleGroups[sElement] ;
}
aGroup[aGroup.length] = oStyleDef ;
}
this.Loaded = true ;
}

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*
@ -311,7 +311,7 @@ FCKUnlinkCommand.prototype.GetState = function()
return state ;
}
FCKVisitLinkCommand = function()
var FCKVisitLinkCommand = function()
{
this.Name = 'VisitLink';
}

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*
@ -25,12 +25,20 @@
var FCKSpellCheckCommand = function()
{
this.Name = 'SpellCheck' ;
this.IsEnabled = ( FCKConfig.SpellChecker == 'SpellerPages' ) ;
this.IsEnabled = ( FCKConfig.SpellChecker != 'ieSpell' ) ;
}
FCKSpellCheckCommand.prototype.Execute = function()
{
FCKDialog.OpenDialog( 'FCKDialog_SpellCheck', 'Spell Check', 'dialog/fck_spellerpages.html', 440, 480 ) ;
switch ( FCKConfig.SpellChecker )
{
case 'SpellerPages' :
FCKDialog.OpenDialog( 'FCKDialog_SpellCheck', 'Spell Check', 'dialog/fck_spellerpages.html', 440, 480 ) ;
break;
case 'WSC' :
FCKDialog.OpenDialog( 'FCKDialog_SpellCheck', 'Spell Check', 'wsc/w.html', 530, 480 ) ;
}
}
FCKSpellCheckCommand.prototype.GetState = function()

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*
@ -25,7 +25,7 @@
var FCKSpellCheckCommand = function()
{
this.Name = 'SpellCheck' ;
this.IsEnabled = ( FCKConfig.SpellChecker == 'ieSpell' || FCKConfig.SpellChecker == 'SpellerPages' ) ;
this.IsEnabled = true ;
}
FCKSpellCheckCommand.prototype.Execute = function()
@ -39,6 +39,9 @@ FCKSpellCheckCommand.prototype.Execute = function()
case 'SpellerPages' :
FCKDialog.OpenDialog( 'FCKDialog_SpellCheck', 'Spell Check', 'dialog/fck_spellerpages.html', 440, 480 ) ;
break ;
case 'WSC' :
FCKDialog.OpenDialog( 'FCKDialog_SpellCheck', 'Spell Check', 'wsc/w.html', 530, 480 ) ;
}
}

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*
@ -40,8 +40,8 @@ function InitializeAPI()
// objects that aren't really FCKeditor instances.
var sScript =
'window.FCKeditorAPI = {' +
'Version : "2.5 SVN",' +
'VersionBuild : "21065",' +
'Version : "2.6.4 Beta",' +
'VersionBuild : "21469",' +
'Instances : window.FCKeditorAPI && window.FCKeditorAPI.Instances || {},' +
'GetInstance : function( name )' +

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*
@ -321,7 +321,12 @@ FCK.ExecuteRedirectedNamedCommand = function( commandName, commandParameter )
if ( FCK.Paste() )
FCK.ExecuteNamedCommand( 'Paste', null, true ) ;
}
catch (e) { FCKDialog.OpenDialog( 'FCKDialog_Paste', FCKLang.Paste, 'dialog/fck_paste.html', 400, 330, 'Security' ) ; }
catch (e) {
if ( FCKConfig.ForcePasteAsPlainText )
FCK.PasteAsPlainText() ;
else
FCKDialog.OpenDialog( 'FCKDialog_Paste', FCKLang.Paste, 'dialog/fck_paste.html', 400, 330, 'Security' ) ;
}
break ;
default :
FCK.ExecuteNamedCommand( commandName, commandParameter ) ;

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*
@ -47,7 +47,7 @@ FCKCodeFormatter.Init = function()
FCKCodeFormatter._ProtectData = function( outer, opener, data, closer )
{
return opener + '___FCKpd___' + FCKCodeFormatter.ProtectedData.push( data ) + closer ;
return opener + '___FCKpd___' + ( FCKCodeFormatter.ProtectedData.push( data ) - 1 ) + closer ;
}
FCKCodeFormatter.Format = function( html )

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,103 +0,0 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2007 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*
* Licensed under the terms of any of the following licenses at your
* choice:
*
* - GNU General Public License Version 2 or later (the "GPL")
* http://www.gnu.org/licenses/gpl.html
*
* - GNU Lesser General Public License Version 2.1 or later (the "LGPL")
* http://www.gnu.org/licenses/lgpl.html
*
* - Mozilla Public License Version 1.1 or later (the "MPL")
* http://www.mozilla.org/MPL/MPL-1.1.html
*
* == END LICENSE ==
*
* Dialog windows operations. (Gecko specific implementations)
*/
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,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 avoid an error when using a frameset
// on a different domain:
// "Permission denied to get property Window.releaseEvents".
try
{
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 avoid an error when using a frameset
// on a different domain:
// "Permission denied to get property Window.releaseEvents".
try
{
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 ;
}

@ -1,49 +0,0 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2007 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*
* Licensed under the terms of any of the following licenses at your
* choice:
*
* - GNU General Public License Version 2 or later (the "GPL")
* http://www.gnu.org/licenses/gpl.html
*
* - GNU Lesser General Public License Version 2.1 or later (the "LGPL")
* http://www.gnu.org/licenses/lgpl.html
*
* - Mozilla Public License Version 1.1 or later (the "MPL")
* http://www.mozilla.org/MPL/MPL-1.1.html
*
* == END LICENSE ==
*
* Dialog windows operations. (IE specific implementations)
*/
FCKDialog.Show = function( dialogInfo, dialogName, pageUrl, dialogWidth, dialogHeight, parentWindow, resizable )
{
if ( !parentWindow )
parentWindow = window ;
var sOptions = 'help:no;scroll:no;status:no' +
';resizable:' + ( resizable ? 'yes' : 'no' ) +
';dialogWidth:' + dialogWidth + 'px' +
';dialogHeight:' + dialogHeight + 'px' ;
FCKFocusManager.Lock() ;
var oReturn = 'B' ;
try
{
dialogInfo.DialogName = dialogName ;
oReturn = parentWindow.showModalDialog( pageUrl, dialogInfo, sOptions ) ;
}
catch( e ) {}
if ( 'B' === oReturn )
alert( FCKLang.DialogBlocked ) ;
FCKFocusManager.Unlock() ;
}

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*
@ -122,7 +122,7 @@ FCKPageBreaksProcessor.ProcessDocument = function( document )
}
// EMBED and OBJECT tags.
FCKEmbedAndObjectProcessor = (function()
var FCKEmbedAndObjectProcessor = (function()
{
var customProcessors = [] ;

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*
@ -227,7 +227,7 @@ FCKSelection.Save = function( lock )
if ( selection )
{
// The call might fail if the document doesn't have the focus (#1801),
// The call might fail if the document doesn't have the focus (#1801),
// but we don't want to modify the current selection (#2495) with a call to FCK.Focus() ;
try {
range = selection.createRange() ;
@ -260,7 +260,7 @@ FCKSelection._GetSelectionDocument = function( selection )
FCKSelection.Restore = function()
{
if ( this.SelectionData )
if ( this.SelectionData )
{
FCK.IsSelectionChangeLocked = true ;

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*
@ -52,7 +52,7 @@ FCKTableHandler.DeleteRows = function( row )
//queue up the rows -- it's possible ( and likely ) that we may get duplicates
for ( var i = 0; i < aCells.length; i++ )
{
var oRow = FCKTools.GetElementAscensor( aCells[i],'TR' ) ;
var oRow = aCells[i].parentNode ;
aRowsToDelete[oRow.rowIndex] = oRow ;
}
for ( var i = aRowsToDelete.length; i >= 0; i-- )
@ -118,13 +118,13 @@ FCKTableHandler.InsertColumn = function( insertBefore )
var iIndex = oCell.cellIndex ;
// Loop throw all rows available in the table.
// Loop through all rows available in the table.
for ( var i = 0 ; i < oTable.rows.length ; i++ )
{
// Get the row.
var oRow = oTable.rows[i] ;
// If the row doens't have enough cells, ignore it.
// If the row doesn't have enough cells, ignore it.
if ( oRow.cells.length < ( iIndex + 1 ) )
continue ;
@ -136,12 +136,7 @@ FCKTableHandler.InsertColumn = function( insertBefore )
// Get back the currently selected cell.
var oBaseCell = oRow.cells[iIndex] ;
if ( insertBefore )
oRow.insertBefore( oCell, oBaseCell ) ;
else if ( oBaseCell.nextSibling )
oRow.insertBefore( oCell, oBaseCell.nextSibling ) ;
else
oRow.appendChild( oCell ) ;
oRow.insertBefore( oCell, ( insertBefore ? oBaseCell : oBaseCell.nextSibling ) ) ;
}
}
@ -218,7 +213,7 @@ FCKTableHandler.DeleteCell = function( cell )
if ( cell.parentNode.cells.length == 1 )
{
// Delete the entire row.
FCKTableHandler.DeleteRows( FCKTools.GetElementAscensor( cell, 'TR' ) ) ;
FCKTableHandler.DeleteRows( cell.parentNode ) ;
return ;
}
@ -246,10 +241,7 @@ FCKTableHandler._UnmarkCells = function( cells, label )
{
for ( var i = 0 ; i < cells.length ; i++ )
{
if ( FCKBrowserInfo.IsIE )
cells[i].removeAttribute( label ) ;
else
delete cells[i][label] ;
FCKDomTools.ClearElementJSProperty(cells[i], label ) ;
}
}
@ -385,12 +377,12 @@ FCKTableHandler.MergeCells = function()
}
}
if ( rowChildNodesCount > 0 )
cellContents.appendChild( FCKTools.GetElementDocument( refCell ).createElement( 'br' ) ) ;
cellContents.appendChild( FCK.EditorDocument.createElement( 'br' ) ) ;
}
this._ReplaceCellsByMarker( tableMap, '_SelectedCells', refCell ) ;
this._UnmarkCells( cells, '_SelectedCells' ) ;
this._InstallTableMap( tableMap, refCell.parentNode.parentNode ) ;
this._InstallTableMap( tableMap, refCell.parentNode.parentNode.parentNode ) ;
refCell.appendChild( cellContents ) ;
if ( FCKBrowserInfo.IsGeckoLike && ( ! refCell.firstChild ) )
@ -416,7 +408,7 @@ FCKTableHandler.MergeRight = function()
refCell.appendChild( cellContents ) ;
this._MarkCells( [nextCell], '_Replace' ) ;
this._ReplaceCellsByMarker( tableMap, '_Replace', refCell ) ;
this._InstallTableMap( tableMap, refCell.parentNode.parentNode ) ;
this._InstallTableMap( tableMap, refCell.parentNode.parentNode.parentNode ) ;
this._MoveCaretToCell( refCell, false ) ;
}
@ -434,11 +426,11 @@ FCKTableHandler.MergeDown = function()
while ( nextCell && nextCell.childNodes && nextCell.childNodes.length > 0 )
cellContents.appendChild( nextCell.removeChild( nextCell.firstChild ) ) ;
if ( cellContents.firstChild )
cellContents.insertBefore( FCKTools.GetElementDocument( nextCell ).createElement( 'br' ), cellContents.firstChild ) ;
cellContents.insertBefore( FCK.EditorDocument.createElement( 'br' ), cellContents.firstChild ) ;
refCell.appendChild( cellContents ) ;
this._MarkCells( [nextCell], '_Replace' ) ;
this._ReplaceCellsByMarker( tableMap, '_Replace', refCell ) ;
this._InstallTableMap( tableMap, refCell.parentNode.parentNode ) ;
this._InstallTableMap( tableMap, refCell.parentNode.parentNode.parentNode ) ;
this._MoveCaretToCell( refCell, false ) ;
}
@ -504,7 +496,7 @@ FCKTableHandler.HorizontalSplitCell = function()
tableMap = newTableMap ;
}
this._InstallTableMap( tableMap, refCell.parentNode.parentNode ) ;
this._InstallTableMap( tableMap, refCell.parentNode.parentNode.parentNode ) ;
}
FCKTableHandler.VerticalSplitCell = function()
@ -518,7 +510,7 @@ FCKTableHandler.VerticalSplitCell = function()
var currentRowIndex = currentCell.parentNode.rowIndex ;
var cellIndex = FCKTableHandler._GetCellIndexSpan( tableMap, currentRowIndex, currentCell ) ;
// Save current cell colSpan
var currentColSpan = isNaN( currentCell.colSpan ) ? 1 : currentCell.colSpan ;
var currentColSpan = isNaN( currentCell.colSpan ) ? 1 : currentCell.colSpan ;
var currentRowSpan = currentCell.rowSpan ;
if ( isNaN( currentRowSpan ) )
currentRowSpan = 1 ;
@ -548,18 +540,18 @@ FCKTableHandler.VerticalSplitCell = function()
newCell.colSpan = currentColSpan ;
if ( FCKBrowserInfo.IsGeckoLike )
FCKTools.AppendBogusBr( newCell ) ;
currentCell.parentNode.parentNode.rows[newCellRowIndex].insertBefore( newCell, insertMarker ) ;
currentCell.parentNode.parentNode.parentNode.rows[newCellRowIndex].insertBefore( newCell, insertMarker ) ;
}
else
{
// 1. Insert a new row.
var newCellRowIndex = currentRowIndex + 1 ;
var newSectionRowIdx = currentCell.parentNode.sectionRowIndex + 1 ;
var newRow = FCK.EditorDocument.createElement( 'tr' ) ;
var tBody = currentCell.parentNode.parentNode ;
if ( tBody.rows.length > newCellRowIndex )
tBody.insertBefore( newRow, tBody.rows[newCellRowIndex] ) ;
var tSection = currentCell.parentNode.parentNode ;
if ( tSection.rows.length > newSectionRowIdx )
tSection.insertBefore( newRow, tSection.rows[newSectionRowIdx] ) ;
else
tBody.appendChild( newRow ) ;
tSection.appendChild( newRow ) ;
// 2. +1 to rowSpan for all cells crossing currentCell's row.
for ( var i = 0 ; i < tableMap[currentRowIndex].length ; )
@ -582,7 +574,7 @@ FCKTableHandler.VerticalSplitCell = function()
// 3. Insert a new cell to new row. Set colSpan on the new cell.
var newCell = FCK.EditorDocument.createElement( currentCell.nodeName ) ;
if ( currentColSpan > 1 )
newCell.colSpan = currentColSpan ;
newCell.colSpan = currentColSpan ;
if ( FCKBrowserInfo.IsGeckoLike )
FCKTools.AppendBogusBr( newCell ) ;
newRow.appendChild( newCell ) ;
@ -619,31 +611,16 @@ FCKTableHandler._GetCellLocation = function( tableMap, cell )
return null ;
}
// Get the cells available in a column of a TableMap.
FCKTableHandler._GetColumnCells = function( tableMap, columnIndex )
{
var aCollCells = new Array() ;
for ( var r = 0 ; r < tableMap.length ; r++ )
{
var oCell = tableMap[r][columnIndex] ;
if ( oCell && ( aCollCells.length == 0 || aCollCells[ aCollCells.length - 1 ] != oCell ) )
aCollCells[ aCollCells.length ] = oCell ;
}
return aCollCells ;
}
// This function is quite hard to explain. It creates a matrix representing all cells in a table.
// The difference here is that the "spanned" cells (colSpan and rowSpan) are duplicated on the matrix
// cells that are "spanned". For example, a row with 3 cells where the second cell has colSpan=2 and rowSpan=3
// will produce a bi-dimensional matrix with the following values (representing the cells):
// Cell1, Cell2, Cell2, Cell2, Cell 3
// Cell4, Cell2, Cell2, Cell2, Cell 5
// Cell1, Cell2, Cell2, Cell3
// Cell4, Cell2, Cell2, Cell5
// Cell6, Cell2, Cell2, Cell7
FCKTableHandler._CreateTableMap = function( refCell )
{
// It's really a tbody, thead or tfoot. This is only temporary.
var table = (refCell.nodeName == 'TABLE' ? refCell : refCell.parentNode.parentNode ) ;
var table = (refCell.nodeName == 'TABLE' ? refCell : refCell.parentNode.parentNode.parentNode ) ;
var aRows = table.rows ;
@ -696,13 +673,6 @@ FCKTableHandler._InstallTableMap = function( tableMap, table )
// for storing the calculated rowSpan in IE.
var rowSpanAttr = FCKBrowserInfo.IsIE ? "_fckrowspan" : "rowSpan" ;
// Clear the table of all rows first.
while ( table.rows.length > 0 )
{
var row = table.rows[0] ;
row.parentNode.removeChild( row ) ;
}
// Disconnect all the cells in tableMap from their parents, set all colSpan and rowSpan attributes to 1.
for ( var i = 0 ; i < tableMap.length ; i++ )
{
@ -758,23 +728,15 @@ FCKTableHandler._InstallTableMap = function( tableMap, table )
for ( var j = 0 ; j < tableMap[i].length ; j++)
{
var cell = tableMap[i][j] ;
if ( FCKBrowserInfo.IsIE )
{
cell.removeAttribute( '_colScanned' ) ;
cell.removeAttribute( '_rowScanned' ) ;
}
else
{
delete cell._colScanned ;
delete cell._rowScanned ;
}
FCKDomTools.ClearElementJSProperty(cell, '_colScanned' ) ;
FCKDomTools.ClearElementJSProperty(cell, '_rowScanned' ) ;
}
}
// Insert physical rows and columns to the table.
for ( var i = 0 ; i < tableMap.length ; i++ )
{
var rowObj = FCKTools.GetElementDocument( table ).createElement( 'tr' ) ;
var rowObj = FCK.EditorDocument.createElement( 'tr' ) ;
for ( var j = 0 ; j < tableMap[i].length ; )
{
var cell = tableMap[i][j] ;
@ -795,7 +757,15 @@ FCKTableHandler._InstallTableMap = function( tableMap, table )
if ( cell.rowSpan == 1 )
cell.removeAttribute( 'rowspan' ) ;
}
table.appendChild( rowObj ) ;
if ( FCKBrowserInfo.IsIE )
{
table.rows[i].replaceNode( rowObj ) ;
}
else
{
table.rows[i].innerHTML = '' ;
FCKDomTools.MoveChildren( rowObj, table.rows[i] ) ;
}
}
}

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

@ -1,6 +1,6 @@
/*
* FCKeditor - The text editor for Internet - http://www.fckeditor.net
* Copyright (C) 2003-2008 Frederico Caldeira Knabben
* Copyright (C) 2003-2009 Frederico Caldeira Knabben
*
* == BEGIN LICENSE ==
*

Some files were not shown because too many files have changed in this diff Show More

Loading…
Cancel
Save