locomotive-tinymce-rails 3.4.7.5 → 3.5.8.1
Sign up to get free protection for your applications and to get access to all the features.
- data/README.md +3 -21
- data/Rakefile +15 -16
- data/app/assets/javascripts/tinymce-jquery.js +1 -1
- data/lib/tinymce/rails/version.rb +2 -2
- data/vendor/assets/javascripts/tinymce/jquery.tinymce.js +1 -1
- data/vendor/assets/javascripts/tinymce/langs/de.js +1 -1
- data/vendor/assets/javascripts/tinymce/langs/en.js +1 -1
- data/vendor/assets/javascripts/tinymce/langs/es.js +1 -1
- data/vendor/assets/javascripts/tinymce/langs/et.js +0 -0
- data/vendor/assets/javascripts/tinymce/langs/fr.js +0 -0
- data/vendor/assets/javascripts/tinymce/langs/it.js +0 -0
- data/vendor/assets/javascripts/tinymce/langs/nb.js +1 -0
- data/vendor/assets/javascripts/tinymce/langs/nl.js +0 -0
- data/vendor/assets/javascripts/tinymce/langs/pl.js +0 -0
- data/vendor/assets/javascripts/tinymce/langs/pt.js +0 -0
- data/vendor/assets/javascripts/tinymce/langs/ru.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advhr/langs/de_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advhr/langs/es_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advhr/langs/et_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advhr/langs/fr_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advhr/langs/it_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advhr/langs/nb_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/advhr/langs/nl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advhr/langs/pl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advhr/langs/pt_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advhr/langs/ru_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advimage/js/image.js +5 -3
- data/vendor/assets/javascripts/tinymce/plugins/advimage/langs/de_dlg.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/advimage/langs/es_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advimage/langs/et_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advimage/langs/fr_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advimage/langs/it_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advimage/langs/nb_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/advimage/langs/nl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advimage/langs/pl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advimage/langs/pt_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advimage/langs/ru_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advlink/js/advlink.js +16 -5
- data/vendor/assets/javascripts/tinymce/plugins/advlink/langs/de_dlg.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/advlink/langs/es_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advlink/langs/et_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advlink/langs/fr_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advlink/langs/it_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advlink/langs/nb_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/advlink/langs/nl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advlink/langs/pl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advlink/langs/pt_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/advlink/langs/ru_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/autolink/editor_plugin.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/autolink/editor_plugin_src.js +24 -12
- data/vendor/assets/javascripts/tinymce/plugins/autoresize/editor_plugin.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/autoresize/editor_plugin_src.js +20 -38
- data/vendor/assets/javascripts/tinymce/plugins/autosave/editor_plugin.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/autosave/editor_plugin_src.js +4 -2
- data/vendor/assets/javascripts/tinymce/plugins/contextmenu/editor_plugin.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/contextmenu/editor_plugin_src.js +10 -7
- data/vendor/assets/javascripts/tinymce/plugins/directionality/editor_plugin.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/directionality/editor_plugin_src.js +22 -19
- data/vendor/assets/javascripts/tinymce/plugins/emotions/emotions.htm +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/emotions/langs/de_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/emotions/langs/en_dlg.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/emotions/langs/es_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/emotions/langs/et_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/emotions/langs/fr_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/emotions/langs/it_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/emotions/langs/nb_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/emotions/langs/nl_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/emotions/langs/pl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/emotions/langs/pt_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/emotions/langs/ru_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/fullpage/langs/de_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/fullpage/langs/es_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/fullpage/langs/et_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/fullpage/langs/fr_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/fullpage/langs/it_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/fullpage/langs/nb_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/fullpage/langs/nl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/fullpage/langs/pl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/fullpage/langs/pt_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/fullpage/langs/ru_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/fullscreen/editor_plugin.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/fullscreen/editor_plugin_src.js +5 -5
- data/vendor/assets/javascripts/tinymce/plugins/legacyoutput/editor_plugin.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/legacyoutput/editor_plugin_src.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/lists/editor_plugin.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/lists/editor_plugin_src.js +98 -68
- data/vendor/assets/javascripts/tinymce/plugins/media/editor_plugin.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/media/editor_plugin_src.js +23 -15
- data/vendor/assets/javascripts/tinymce/plugins/media/js/media.js +75 -26
- data/vendor/assets/javascripts/tinymce/plugins/media/langs/de_dlg.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/media/langs/en_dlg.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/media/langs/es_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/media/langs/et_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/media/langs/fr_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/media/langs/it_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/media/langs/nb_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/media/langs/nl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/media/langs/pl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/media/langs/pt_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/media/langs/ru_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/noneditable/editor_plugin.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/noneditable/editor_plugin_src.js +499 -57
- data/vendor/assets/javascripts/tinymce/plugins/paste/editor_plugin.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/paste/editor_plugin_src.js +17 -3
- data/vendor/assets/javascripts/tinymce/plugins/paste/langs/de_dlg.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/paste/langs/es_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/paste/langs/et_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/paste/langs/fr_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/paste/langs/it_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/paste/langs/nb_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/paste/langs/nl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/paste/langs/pl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/paste/langs/pt_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/paste/langs/ru_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/searchreplace/langs/de_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/searchreplace/langs/es_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/searchreplace/langs/et_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/searchreplace/langs/fr_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/searchreplace/langs/it_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/searchreplace/langs/nb_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/searchreplace/langs/nl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/searchreplace/langs/pl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/searchreplace/langs/pt_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/searchreplace/langs/ru_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/searchreplace/searchreplace.htm +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/spellchecker/editor_plugin.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/spellchecker/editor_plugin_src.js +4 -4
- data/vendor/assets/javascripts/tinymce/plugins/style/css/props.css +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/style/editor_plugin.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/style/editor_plugin_src.js +19 -3
- data/vendor/assets/javascripts/tinymce/plugins/style/js/props.js +77 -3
- data/vendor/assets/javascripts/tinymce/plugins/style/langs/de_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/style/langs/es_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/style/langs/et_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/style/langs/fr_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/style/langs/it_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/style/langs/nb_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/style/langs/nl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/style/langs/pl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/style/langs/pt_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/style/langs/ru_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/style/props.htm +6 -1
- data/vendor/assets/javascripts/tinymce/plugins/style/readme.txt +19 -0
- data/vendor/assets/javascripts/tinymce/plugins/tabfocus/editor_plugin.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/tabfocus/editor_plugin_src.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/table/editor_plugin.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/table/editor_plugin_src.js +88 -40
- data/vendor/assets/javascripts/tinymce/plugins/table/js/cell.js +2 -2
- data/vendor/assets/javascripts/tinymce/plugins/table/js/row.js +17 -0
- data/vendor/assets/javascripts/tinymce/plugins/table/js/table.js +20 -3
- data/vendor/assets/javascripts/tinymce/plugins/table/langs/de_dlg.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/table/langs/es_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/table/langs/et_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/table/langs/fr_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/table/langs/it_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/table/langs/nb_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/table/langs/nl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/table/langs/pl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/table/langs/pt_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/table/langs/ru_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/table/row.htm +15 -15
- data/vendor/assets/javascripts/tinymce/plugins/template/langs/de_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/template/langs/es_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/template/langs/et_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/template/langs/fr_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/template/langs/it_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/template/langs/nb_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/template/langs/nl_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/template/langs/pl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/template/langs/pt_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/template/langs/ru_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/visualblocks/css/visualblocks.css +21 -0
- data/vendor/assets/javascripts/tinymce/plugins/visualblocks/editor_plugin.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/visualblocks/editor_plugin_src.js +63 -0
- data/vendor/assets/javascripts/tinymce/plugins/wordcount/editor_plugin.js +1 -1
- data/vendor/assets/javascripts/tinymce/plugins/wordcount/editor_plugin_src.js +14 -6
- data/vendor/assets/javascripts/tinymce/plugins/xhtmlxtras/langs/de_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/xhtmlxtras/langs/es_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/xhtmlxtras/langs/et_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/xhtmlxtras/langs/fr_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/xhtmlxtras/langs/it_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/xhtmlxtras/langs/nb_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/plugins/xhtmlxtras/langs/nl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/xhtmlxtras/langs/pl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/xhtmlxtras/langs/pt_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/plugins/xhtmlxtras/langs/ru_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/themes/advanced/color_picker.htm +2 -6
- data/vendor/assets/javascripts/tinymce/themes/advanced/editor_template.js +1 -1
- data/vendor/assets/javascripts/tinymce/themes/advanced/editor_template_src.js +176 -48
- data/vendor/assets/javascripts/tinymce/themes/advanced/img/icons.gif +0 -0
- data/vendor/assets/javascripts/tinymce/themes/advanced/js/anchor.js +19 -6
- data/vendor/assets/javascripts/tinymce/themes/advanced/js/color_picker.js +345 -329
- data/vendor/assets/javascripts/tinymce/themes/advanced/js/image.js +4 -2
- data/vendor/assets/javascripts/tinymce/themes/advanced/js/link.js +9 -3
- data/vendor/assets/javascripts/tinymce/themes/advanced/js/source_editor.js +27 -5
- data/vendor/assets/javascripts/tinymce/themes/advanced/langs/de.js +1 -1
- data/vendor/assets/javascripts/tinymce/themes/advanced/langs/de_dlg.js +1 -1
- data/vendor/assets/javascripts/tinymce/themes/advanced/langs/en.js +1 -1
- data/vendor/assets/javascripts/tinymce/themes/advanced/langs/en_dlg.js +1 -1
- data/vendor/assets/javascripts/tinymce/themes/advanced/langs/es.js +0 -0
- data/vendor/assets/javascripts/tinymce/themes/advanced/langs/es_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/themes/advanced/langs/et.js +0 -0
- data/vendor/assets/javascripts/tinymce/themes/advanced/langs/et_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/themes/advanced/langs/fr.js +0 -0
- data/vendor/assets/javascripts/tinymce/themes/advanced/langs/fr_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/themes/advanced/langs/it.js +0 -0
- data/vendor/assets/javascripts/tinymce/themes/advanced/langs/it_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/themes/advanced/langs/nb.js +1 -0
- data/vendor/assets/javascripts/tinymce/themes/advanced/langs/nb_dlg.js +1 -0
- data/vendor/assets/javascripts/tinymce/themes/advanced/langs/nl.js +0 -0
- data/vendor/assets/javascripts/tinymce/themes/advanced/langs/nl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/themes/advanced/langs/pl.js +0 -0
- data/vendor/assets/javascripts/tinymce/themes/advanced/langs/pl_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/themes/advanced/langs/pt.js +0 -0
- data/vendor/assets/javascripts/tinymce/themes/advanced/langs/pt_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/themes/advanced/langs/ru.js +0 -0
- data/vendor/assets/javascripts/tinymce/themes/advanced/langs/ru_dlg.js +0 -0
- data/vendor/assets/javascripts/tinymce/themes/advanced/skins/default/dialog.css +3 -2
- data/vendor/assets/javascripts/tinymce/themes/advanced/skins/default/ui.css +6 -1
- data/vendor/assets/javascripts/tinymce/themes/advanced/skins/highcontrast/dialog.css +4 -3
- data/vendor/assets/javascripts/tinymce/themes/advanced/skins/highcontrast/ui.css +5 -1
- data/vendor/assets/javascripts/tinymce/themes/advanced/skins/o2k7/dialog.css +3 -2
- data/vendor/assets/javascripts/tinymce/themes/advanced/skins/o2k7/ui.css +6 -1
- data/vendor/assets/javascripts/tinymce/themes/advanced/source_editor.htm +1 -1
- data/vendor/assets/javascripts/tinymce/themes/simple/langs/de.js +1 -0
- data/vendor/assets/javascripts/tinymce/themes/simple/langs/es.js +1 -0
- data/vendor/assets/javascripts/tinymce/themes/simple/langs/et.js +1 -0
- data/vendor/assets/javascripts/tinymce/themes/simple/langs/fr.js +1 -0
- data/vendor/assets/javascripts/tinymce/themes/simple/langs/it.js +1 -0
- data/vendor/assets/javascripts/tinymce/themes/simple/langs/nb.js +1 -0
- data/vendor/assets/javascripts/tinymce/themes/simple/langs/nl.js +1 -0
- data/vendor/assets/javascripts/tinymce/themes/simple/langs/pl.js +0 -0
- data/vendor/assets/javascripts/tinymce/themes/simple/langs/pt.js +1 -0
- data/vendor/assets/javascripts/tinymce/themes/simple/langs/ru.js +1 -0
- data/vendor/assets/javascripts/tinymce/tiny_mce.js +1 -1
- data/vendor/assets/javascripts/tinymce/tiny_mce_popup.js +1 -1
- data/vendor/assets/javascripts/tinymce/tiny_mce_src.js +9799 -8716
- data/vendor/assets/javascripts_old/tinymce/jquery.tinymce.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/langs/de.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/langs/en.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/langs/es.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/langs/et.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/langs/fr.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/langs/it.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/langs/nl.js +1 -0
- data/vendor/assets/{javascripts → javascripts_old}/tinymce/langs/no.js +0 -0
- data/vendor/assets/javascripts_old/tinymce/langs/pl.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/langs/pt.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/langs/ru.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/license.txt +504 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advhr/css/advhr.css +5 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advhr/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advhr/editor_plugin_src.js +57 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advhr/js/rule.js +43 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advhr/langs/de_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advhr/langs/en_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advhr/langs/es_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advhr/langs/et_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advhr/langs/fr_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advhr/langs/it_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advhr/langs/nl_dlg.js +1 -0
- data/vendor/assets/{javascripts → javascripts_old}/tinymce/plugins/advhr/langs/no_dlg.js +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advhr/langs/pl_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advhr/langs/pt_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advhr/langs/ru_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advhr/rule.htm +58 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advimage/css/advimage.css +13 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advimage/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advimage/editor_plugin_src.js +50 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advimage/image.htm +235 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advimage/img/sample.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advimage/js/image.js +462 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advimage/langs/de_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advimage/langs/en_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advimage/langs/es_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advimage/langs/et_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advimage/langs/fr_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advimage/langs/it_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advimage/langs/nl_dlg.js +1 -0
- data/vendor/assets/{javascripts → javascripts_old}/tinymce/plugins/advimage/langs/no_dlg.js +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advimage/langs/pl_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advimage/langs/pt_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advimage/langs/ru_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advlink/css/advlink.css +8 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advlink/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advlink/editor_plugin_src.js +61 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advlink/js/advlink.js +532 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advlink/langs/de_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advlink/langs/en_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advlink/langs/es_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advlink/langs/et_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advlink/langs/fr_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advlink/langs/it_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advlink/langs/nl_dlg.js +1 -0
- data/vendor/assets/{javascripts → javascripts_old}/tinymce/plugins/advlink/langs/no_dlg.js +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advlink/langs/pl_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advlink/langs/pt_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advlink/langs/ru_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advlink/link.htm +338 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advlist/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/advlist/editor_plugin_src.js +176 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/autolink/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/autolink/editor_plugin_src.js +172 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/autoresize/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/autoresize/editor_plugin_src.js +137 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/autosave/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/autosave/editor_plugin_src.js +431 -0
- data/vendor/assets/{javascripts → javascripts_old}/tinymce/plugins/autosave/langs/en.js +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/bbcode/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/bbcode/editor_plugin_src.js +120 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/contextmenu/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/contextmenu/editor_plugin_src.js +160 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/directionality/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/directionality/editor_plugin_src.js +82 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/emotions/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/emotions/editor_plugin_src.js +43 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/emotions/emotions.htm +42 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/emotions/img/smiley-cool.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/emotions/img/smiley-cry.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/emotions/img/smiley-embarassed.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/emotions/img/smiley-foot-in-mouth.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/emotions/img/smiley-frown.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/emotions/img/smiley-innocent.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/emotions/img/smiley-kiss.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/emotions/img/smiley-laughing.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/emotions/img/smiley-money-mouth.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/emotions/img/smiley-sealed.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/emotions/img/smiley-smile.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/emotions/img/smiley-surprised.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/emotions/img/smiley-tongue-out.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/emotions/img/smiley-undecided.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/emotions/img/smiley-wink.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/emotions/img/smiley-yell.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/emotions/js/emotions.js +43 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/emotions/langs/en_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/emotions/langs/pl_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/example/dialog.htm +22 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/example/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/example/editor_plugin_src.js +84 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/example/img/example.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/example/js/dialog.js +19 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/example/langs/en.js +3 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/example/langs/en_dlg.js +3 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/example_dependency/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/example_dependency/editor_plugin_src.js +50 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/fullpage/css/fullpage.css +143 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/fullpage/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/fullpage/editor_plugin_src.js +405 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/fullpage/fullpage.htm +259 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/fullpage/js/fullpage.js +232 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/fullpage/langs/de_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/fullpage/langs/en_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/fullpage/langs/es_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/fullpage/langs/et_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/fullpage/langs/fr_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/fullpage/langs/it_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/fullpage/langs/nl_dlg.js +1 -0
- data/vendor/assets/{javascripts → javascripts_old}/tinymce/plugins/fullpage/langs/no_dlg.js +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/fullpage/langs/pl_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/fullpage/langs/pt_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/fullpage/langs/ru_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/fullscreen/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/fullscreen/editor_plugin_src.js +159 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/fullscreen/fullscreen.htm +110 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/iespell/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/iespell/editor_plugin_src.js +54 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/inlinepopups/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/inlinepopups/editor_plugin_src.js +699 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/inlinepopups/skins/clearlooks2/img/alert.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/inlinepopups/skins/clearlooks2/img/button.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/inlinepopups/skins/clearlooks2/img/buttons.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/inlinepopups/skins/clearlooks2/img/confirm.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/inlinepopups/skins/clearlooks2/img/corners.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/inlinepopups/skins/clearlooks2/img/horizontal.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/inlinepopups/skins/clearlooks2/img/vertical.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/inlinepopups/skins/clearlooks2/window.css +90 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/inlinepopups/template.htm +387 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/insertdatetime/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/insertdatetime/editor_plugin_src.js +83 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/layer/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/layer/editor_plugin_src.js +262 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/legacyoutput/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/legacyoutput/editor_plugin_src.js +139 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/lists/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/lists/editor_plugin_src.js +925 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/media/css/media.css +17 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/media/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/media/editor_plugin_src.js +890 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/media/js/embed.js +73 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/media/js/media.js +464 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/media/langs/de_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/media/langs/en_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/media/langs/es_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/media/langs/et_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/media/langs/fr_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/media/langs/it_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/media/langs/nl_dlg.js +1 -0
- data/vendor/assets/{javascripts → javascripts_old}/tinymce/plugins/media/langs/no_dlg.js +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/media/langs/pl_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/media/langs/pt_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/media/langs/ru_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/media/media.htm +922 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/media/moxieplayer.swf +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/nonbreaking/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/nonbreaking/editor_plugin_src.js +54 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/noneditable/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/noneditable/editor_plugin_src.js +95 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/pagebreak/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/pagebreak/editor_plugin_src.js +74 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/paste/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/paste/editor_plugin_src.js +871 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/paste/js/pastetext.js +36 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/paste/js/pasteword.js +51 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/paste/langs/de_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/paste/langs/en_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/paste/langs/es_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/paste/langs/et_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/paste/langs/fr_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/paste/langs/it_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/paste/langs/nl_dlg.js +1 -0
- data/vendor/assets/{javascripts → javascripts_old}/tinymce/plugins/paste/langs/no_dlg.js +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/paste/langs/pl_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/paste/langs/pt_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/paste/langs/ru_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/paste/pastetext.htm +27 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/paste/pasteword.htm +21 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/preview/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/preview/editor_plugin_src.js +53 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/preview/example.html +28 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/preview/jscripts/embed.js +73 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/preview/preview.html +17 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/print/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/print/editor_plugin_src.js +34 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/save/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/save/editor_plugin_src.js +101 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/searchreplace/css/searchreplace.css +6 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/searchreplace/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/searchreplace/editor_plugin_src.js +61 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/searchreplace/js/searchreplace.js +142 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/searchreplace/langs/de_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/searchreplace/langs/en_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/searchreplace/langs/es_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/searchreplace/langs/et_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/searchreplace/langs/fr_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/searchreplace/langs/it_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/searchreplace/langs/nl_dlg.js +1 -0
- data/vendor/assets/{javascripts → javascripts_old}/tinymce/plugins/searchreplace/langs/no_dlg.js +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/searchreplace/langs/pl_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/searchreplace/langs/pt_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/searchreplace/langs/ru_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/searchreplace/searchreplace.htm +100 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/spellchecker/css/content.css +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/spellchecker/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/spellchecker/editor_plugin_src.js +436 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/spellchecker/img/wline.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/style/css/props.css +13 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/style/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/style/editor_plugin_src.js +55 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/style/js/props.js +635 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/style/langs/de_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/style/langs/en_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/style/langs/es_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/style/langs/et_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/style/langs/fr_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/style/langs/it_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/style/langs/nl_dlg.js +1 -0
- data/vendor/assets/{javascripts → javascripts_old}/tinymce/plugins/style/langs/no_dlg.js +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/style/langs/pl_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/style/langs/pt_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/style/langs/ru_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/style/props.htm +840 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/tabfocus/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/tabfocus/editor_plugin_src.js +122 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/table/cell.htm +180 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/table/css/cell.css +17 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/table/css/row.css +25 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/table/css/table.css +13 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/table/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/table/editor_plugin_src.js +1408 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/table/js/cell.js +319 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/table/js/merge_cells.js +27 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/table/js/row.js +237 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/table/js/table.js +484 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/table/langs/de_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/table/langs/en_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/table/langs/es_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/table/langs/et_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/table/langs/fr_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/table/langs/it_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/table/langs/nl_dlg.js +1 -0
- data/vendor/assets/{javascripts → javascripts_old}/tinymce/plugins/table/langs/no_dlg.js +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/table/langs/pl_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/table/langs/pt_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/table/langs/ru_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/table/merge_cells.htm +32 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/table/row.htm +158 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/table/table.htm +188 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/template/blank.htm +12 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/template/css/template.css +23 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/template/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/template/editor_plugin_src.js +159 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/template/js/template.js +106 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/template/langs/en_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/template/langs/pl_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/template/template.htm +31 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/visualchars/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/visualchars/editor_plugin_src.js +83 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/wordcount/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/wordcount/editor_plugin_src.js +114 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/abbr.htm +142 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/acronym.htm +142 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/attributes.htm +149 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/cite.htm +142 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/css/attributes.css +11 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/css/popup.css +9 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/del.htm +162 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/editor_plugin.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/editor_plugin_src.js +132 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/ins.htm +162 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/js/abbr.js +28 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/js/acronym.js +28 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/js/attributes.js +111 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/js/cite.js +28 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/js/del.js +53 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/js/element_common.js +229 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/js/ins.js +53 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/langs/de_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/langs/en_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/langs/es_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/langs/et_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/langs/fr_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/langs/it_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/langs/nl_dlg.js +1 -0
- data/vendor/assets/{javascripts → javascripts_old}/tinymce/plugins/xhtmlxtras/langs/no_dlg.js +0 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/langs/pl_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/langs/pt_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/plugins/xhtmlxtras/langs/ru_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/about.htm +52 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/anchor.htm +26 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/charmap.htm +55 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/color_picker.htm +74 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/editor_template.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/editor_template_src.js +1362 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/image.htm +80 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/img/colorpicker.jpg +0 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/img/flash.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/img/icons.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/img/iframe.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/img/pagebreak.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/img/quicktime.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/img/realmedia.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/img/shockwave.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/img/trans.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/img/video.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/img/windowsmedia.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/js/about.js +73 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/js/anchor.js +43 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/js/charmap.js +363 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/js/color_picker.js +329 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/js/image.js +251 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/js/link.js +153 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/js/source_editor.js +56 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/langs/de.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/langs/de_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/langs/en.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/langs/en_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/langs/es.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/langs/es_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/langs/et.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/langs/et_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/langs/fr.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/langs/fr_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/langs/it.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/langs/it_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/langs/nl.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/langs/nl_dlg.js +1 -0
- data/vendor/assets/{javascripts → javascripts_old}/tinymce/themes/advanced/langs/no.js +0 -0
- data/vendor/assets/{javascripts → javascripts_old}/tinymce/themes/advanced/langs/no_dlg.js +0 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/langs/pl.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/langs/pl_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/langs/pt.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/langs/pt_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/langs/ru.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/langs/ru_dlg.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/link.htm +57 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/shortcuts.htm +47 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/skins/default/content.css +50 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/skins/default/dialog.css +117 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/skins/default/img/buttons.png +0 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/skins/default/img/items.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/skins/default/img/menu_arrow.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/skins/default/img/menu_check.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/skins/default/img/progress.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/skins/default/img/tabs.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/skins/default/ui.css +214 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/skins/highcontrast/content.css +24 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/skins/highcontrast/dialog.css +105 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/skins/highcontrast/ui.css +102 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/skins/o2k7/content.css +48 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/skins/o2k7/dialog.css +117 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/skins/o2k7/img/button_bg.png +0 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/skins/o2k7/img/button_bg_black.png +0 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/skins/o2k7/img/button_bg_silver.png +0 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/skins/o2k7/ui.css +217 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/skins/o2k7/ui_black.css +8 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/skins/o2k7/ui_silver.css +5 -0
- data/vendor/assets/javascripts_old/tinymce/themes/advanced/source_editor.htm +25 -0
- data/vendor/assets/javascripts_old/tinymce/themes/simple/editor_template.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/simple/editor_template_src.js +84 -0
- data/vendor/assets/javascripts_old/tinymce/themes/simple/img/icons.gif +0 -0
- data/vendor/assets/javascripts_old/tinymce/themes/simple/langs/en.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/simple/langs/pl.js +1 -0
- data/vendor/assets/javascripts_old/tinymce/themes/simple/skins/default/content.css +25 -0
- data/vendor/assets/javascripts_old/tinymce/themes/simple/skins/default/ui.css +32 -0
- data/vendor/assets/javascripts_old/tinymce/themes/simple/skins/o2k7/content.css +17 -0
- data/vendor/assets/javascripts_old/tinymce/themes/simple/skins/o2k7/img/button_bg.png +0 -0
- data/vendor/assets/javascripts_old/tinymce/themes/simple/skins/o2k7/ui.css +35 -0
- data/vendor/assets/javascripts_old/tinymce/tiny_mce.js +1 -0
- data/vendor/assets/{javascripts → javascripts_old}/tinymce/tiny_mce_jquery.js +0 -0
- data/vendor/assets/{javascripts → javascripts_old}/tinymce/tiny_mce_jquery_src.js +0 -0
- data/vendor/assets/javascripts_old/tinymce/tiny_mce_popup.js +5 -0
- data/vendor/assets/javascripts_old/tinymce/tiny_mce_src.js +16728 -0
- data/vendor/assets/javascripts_old/tinymce/utils/editable_selects.js +70 -0
- data/vendor/assets/javascripts_old/tinymce/utils/form_utils.js +210 -0
- data/vendor/assets/javascripts_old/tinymce/utils/mctabs.js +162 -0
- data/vendor/assets/javascripts_old/tinymce/utils/validate.js +252 -0
- metadata +437 -20
@@ -1 +1 @@
|
|
1
|
-
(function(){var c=tinymce.each,a={paste_auto_cleanup_on_paste:true,paste_enable_default_filters:true,paste_block_drop:false,paste_retain_style_properties:"none",paste_strip_class_attributes:"mso",paste_remove_spans:false,paste_remove_styles:false,paste_remove_styles_if_webkit:true,paste_convert_middot_lists:true,paste_convert_headers_to_strong:false,paste_dialog_width:"450",paste_dialog_height:"400",paste_text_use_dialog:false,paste_text_sticky:false,paste_text_sticky_default:false,paste_text_notifyalways:false,paste_text_linebreaktype:"combined",paste_text_replacements:[[/\u2026/g,"..."],[/[\x93\x94\u201c\u201d]/g,'"'],[/[\x60\x91\x92\u2018\u2019]/g,"'"]]};function b(d,e){return d.getParam(e,a[e])}tinymce.create("tinymce.plugins.PastePlugin",{init:function(d,e){var f=this;f.editor=d;f.url=e;f.onPreProcess=new tinymce.util.Dispatcher(f);f.onPostProcess=new tinymce.util.Dispatcher(f);f.onPreProcess.add(f._preProcess);f.onPostProcess.add(f._postProcess);f.onPreProcess.add(function(i,j){d.execCallback("paste_preprocess",i,j)});f.onPostProcess.add(function(i,j){d.execCallback("paste_postprocess",i,j)});d.onKeyDown.addToTop(function(i,j){if(((tinymce.isMac?j.metaKey:j.ctrlKey)&&j.keyCode==86)||(j.shiftKey&&j.keyCode==45)){return false}});d.pasteAsPlainText=b(d,"paste_text_sticky_default");function h(l,j){var k=d.dom,i;f.onPreProcess.dispatch(f,l);l.node=k.create("div",0,l.content);if(tinymce.isGecko){i=d.selection.getRng(true);if(i.startContainer==i.endContainer&&i.startContainer.nodeType==3){if(l.node.childNodes.length===1&&/^(p|h[1-6]|pre)$/i.test(l.node.firstChild.nodeName)&&l.content.indexOf("__MCE_ITEM__")===-1){k.remove(l.node.firstChild,true)}}}f.onPostProcess.dispatch(f,l);l.content=d.serializer.serialize(l.node,{getInner:1,forced_root_block:""});if((!j)&&(d.pasteAsPlainText)){f._insertPlainText(l.content);if(!b(d,"paste_text_sticky")){d.pasteAsPlainText=false;d.controlManager.setActive("pastetext",false)}}else{f._insert(l.content)}}d.addCommand("mceInsertClipboardContent",function(i,j){h(j,true)});if(!b(d,"paste_text_use_dialog")){d.addCommand("mcePasteText",function(j,i){var k=tinymce.util.Cookie;d.pasteAsPlainText=!d.pasteAsPlainText;d.controlManager.setActive("pastetext",d.pasteAsPlainText);if((d.pasteAsPlainText)&&(!k.get("tinymcePasteText"))){if(b(d,"paste_text_sticky")){d.windowManager.alert(d.translate("paste.plaintext_mode_sticky"))}else{d.windowManager.alert(d.translate("paste.plaintext_mode"))}if(!b(d,"paste_text_notifyalways")){k.set("tinymcePasteText","1",new Date(new Date().getFullYear()+1,12,31))}}})}d.addButton("pastetext",{title:"paste.paste_text_desc",cmd:"mcePasteText"});d.addButton("selectall",{title:"paste.selectall_desc",cmd:"selectall"});function g(s){var l,p,j,t,k=d.selection,o=d.dom,q=d.getBody(),i,r;if(s.clipboardData||o.doc.dataTransfer){r=(s.clipboardData||o.doc.dataTransfer).getData("Text");if(d.pasteAsPlainText){s.preventDefault();h({content:o.encode(r).replace(/\r?\n/g,"<br />")});return}}if(o.get("_mcePaste")){return}l=o.add(q,"div",{id:"_mcePaste","class":"mcePaste","data-mce-bogus":"1"},"\uFEFF\uFEFF");if(q!=d.getDoc().body){i=o.getPos(d.selection.getStart(),q).y}else{i=q.scrollTop+o.getViewPort(d.getWin()).y}o.setStyles(l,{position:"absolute",left:tinymce.isGecko?-40:0,top:i-25,width:1,height:1,overflow:"hidden"});if(tinymce.isIE){t=k.getRng();j=o.doc.body.createTextRange();j.moveToElementText(l);j.execCommand("Paste");o.remove(l);if(l.innerHTML==="\uFEFF\uFEFF"){d.execCommand("mcePasteWord");s.preventDefault();return}k.setRng(t);k.setContent("");setTimeout(function(){h({content:l.innerHTML})},0);return tinymce.dom.Event.cancel(s)}else{function m(n){n.preventDefault()}o.bind(d.getDoc(),"mousedown",m);o.bind(d.getDoc(),"keydown",m);p=d.selection.getRng();l=l.firstChild;j=d.getDoc().createRange();j.setStart(l,0);j.setEnd(l,2);k.setRng(j);window.setTimeout(function(){var u="",n;if(!o.select("div.mcePaste > div.mcePaste").length){n=o.select("div.mcePaste");c(n,function(w){var v=w.firstChild;if(v&&v.nodeName=="DIV"&&v.style.marginTop&&v.style.backgroundColor){o.remove(v,1)}c(o.select("span.Apple-style-span",w),function(x){o.remove(x,1)});c(o.select("br[data-mce-bogus]",w),function(x){o.remove(x)});if(w.parentNode.className!="mcePaste"){u+=w.innerHTML}})}else{u="<p>"+o.encode(r).replace(/\r?\n\r?\n/g,"</p><p>").replace(/\r?\n/g,"<br />")+"</p>"}c(o.select("div.mcePaste"),function(v){o.remove(v)});if(p){k.setRng(p)}h({content:u});o.unbind(d.getDoc(),"mousedown",m);o.unbind(d.getDoc(),"keydown",m)},0)}}if(b(d,"paste_auto_cleanup_on_paste")){if(tinymce.isOpera||/Firefox\/2/.test(navigator.userAgent)){d.onKeyDown.addToTop(function(i,j){if(((tinymce.isMac?j.metaKey:j.ctrlKey)&&j.keyCode==86)||(j.shiftKey&&j.keyCode==45)){g(j)}})}else{d.onPaste.addToTop(function(i,j){return g(j)})}}d.onInit.add(function(){d.controlManager.setActive("pastetext",d.pasteAsPlainText);if(b(d,"paste_block_drop")){d.dom.bind(d.getBody(),["dragend","dragover","draggesture","dragdrop","drop","drag"],function(i){i.preventDefault();i.stopPropagation();return false})}});f._legacySupport()},getInfo:function(){return{longname:"Paste text/word",author:"Moxiecode Systems AB",authorurl:"http://tinymce.moxiecode.com",infourl:"http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/paste",version:tinymce.majorVersion+"."+tinymce.minorVersion}},_preProcess:function(g,e){var k=this.editor,j=e.content,p=tinymce.grep,n=tinymce.explode,f=tinymce.trim,l,i;function d(h){c(h,function(o){if(o.constructor==RegExp){j=j.replace(o,"")}else{j=j.replace(o[0],o[1])}})}if(k.settings.paste_enable_default_filters==false){return}if(tinymce.isIE&&document.documentMode>=9){d([[/(?:<br> [\s\r\n]+|<br>)*(<\/?(h[1-6r]|p|div|address|pre|form|table|tbody|thead|tfoot|th|tr|td|li|ol|ul|caption|blockquote|center|dl|dt|dd|dir|fieldset)[^>]*>)(?:<br> [\s\r\n]+|<br>)*/g,"$1"]]);d([[/<br><br>/g,"<BR><BR>"],[/<br>/g," "],[/<BR><BR>/g,"<br>"]])}if(/class="?Mso|style="[^"]*\bmso-|w:WordDocument/i.test(j)||e.wordContent){e.wordContent=true;d([/^\s*( )+/gi,/( |<br[^>]*>)+\s*$/gi]);if(b(k,"paste_convert_headers_to_strong")){j=j.replace(/<p [^>]*class="?MsoHeading"?[^>]*>(.*?)<\/p>/gi,"<p><strong>$1</strong></p>")}if(b(k,"paste_convert_middot_lists")){d([[/<!--\[if !supportLists\]-->/gi,"$&__MCE_ITEM__"],[/(<span[^>]+(?:mso-list:|:\s*symbol)[^>]+>)/gi,"$1__MCE_ITEM__"],[/(<p[^>]+(?:MsoListParagraph)[^>]+>)/gi,"$1__MCE_ITEM__"]])}d([/<!--[\s\S]+?-->/gi,/<(!|script[^>]*>.*?<\/script(?=[>\s])|\/?(\?xml(:\w+)?|img|meta|link|style|\w:\w+)(?=[\s\/>]))[^>]*>/gi,[/<(\/?)s>/gi,"<$1strike>"],[/ /gi,"\u00a0"]]);do{l=j.length;j=j.replace(/(<[a-z][^>]*\s)(?:id|name|language|type|on\w+|\w+:\w+)=(?:"[^"]*"|\w+)\s?/gi,"$1")}while(l!=j.length);if(b(k,"paste_retain_style_properties").replace(/^none$/i,"").length==0){j=j.replace(/<\/?span[^>]*>/gi,"")}else{d([[/<span\s+style\s*=\s*"\s*mso-spacerun\s*:\s*yes\s*;?\s*"\s*>([\s\u00a0]*)<\/span>/gi,function(o,h){return(h.length>0)?h.replace(/./," ").slice(Math.floor(h.length/2)).split("").join("\u00a0"):""}],[/(<[a-z][^>]*)\sstyle="([^"]*)"/gi,function(t,h,r){var u=[],o=0,q=n(f(r).replace(/"/gi,"'"),";");c(q,function(s){var w,y,z=n(s,":");function x(A){return A+((A!=="0")&&(/\d$/.test(A)))?"px":""}if(z.length==2){w=z[0].toLowerCase();y=z[1].toLowerCase();switch(w){case"mso-padding-alt":case"mso-padding-top-alt":case"mso-padding-right-alt":case"mso-padding-bottom-alt":case"mso-padding-left-alt":case"mso-margin-alt":case"mso-margin-top-alt":case"mso-margin-right-alt":case"mso-margin-bottom-alt":case"mso-margin-left-alt":case"mso-table-layout-alt":case"mso-height":case"mso-width":case"mso-vertical-align-alt":u[o++]=w.replace(/^mso-|-alt$/g,"")+":"+x(y);return;case"horiz-align":u[o++]="text-align:"+y;return;case"vert-align":u[o++]="vertical-align:"+y;return;case"font-color":case"mso-foreground":u[o++]="color:"+y;return;case"mso-background":case"mso-highlight":u[o++]="background:"+y;return;case"mso-default-height":u[o++]="min-height:"+x(y);return;case"mso-default-width":u[o++]="min-width:"+x(y);return;case"mso-padding-between-alt":u[o++]="border-collapse:separate;border-spacing:"+x(y);return;case"text-line-through":if((y=="single")||(y=="double")){u[o++]="text-decoration:line-through"}return;case"mso-zero-height":if(y=="yes"){u[o++]="display:none"}return}if(/^(mso|column|font-emph|lang|layout|line-break|list-image|nav|panose|punct|row|ruby|sep|size|src|tab-|table-border|text-(?!align|decor|indent|trans)|top-bar|version|vnd|word-break)/.test(w)){return}u[o++]=w+":"+z[1]}});if(o>0){return h+' style="'+u.join(";")+'"'}else{return h}}]])}}if(b(k,"paste_convert_headers_to_strong")){d([[/<h[1-6][^>]*>/gi,"<p><strong>"],[/<\/h[1-6][^>]*>/gi,"</strong></p>"]])}d([[/Version:[\d.]+\nStartHTML:\d+\nEndHTML:\d+\nStartFragment:\d+\nEndFragment:\d+/gi,""]]);i=b(k,"paste_strip_class_attributes");if(i!=="none"){function m(q,o){if(i==="all"){return""}var h=p(n(o.replace(/^(["'])(.*)\1$/,"$2")," "),function(r){return(/^(?!mso)/i.test(r))});return h.length?' class="'+h.join(" ")+'"':""}j=j.replace(/ class="([^"]+)"/gi,m);j=j.replace(/ class=([\-\w]+)/gi,m)}if(b(k,"paste_remove_spans")){j=j.replace(/<\/?span[^>]*>/gi,"")}e.content=j},_postProcess:function(g,i){var f=this,e=f.editor,h=e.dom,d;if(e.settings.paste_enable_default_filters==false){return}if(i.wordContent){c(h.select("a",i.node),function(j){if(!j.href||j.href.indexOf("#_Toc")!=-1){h.remove(j,1)}});if(b(e,"paste_convert_middot_lists")){f._convertLists(g,i)}d=b(e,"paste_retain_style_properties");if((tinymce.is(d,"string"))&&(d!=="all")&&(d!=="*")){d=tinymce.explode(d.replace(/^none$/i,""));c(h.select("*",i.node),function(m){var n={},k=0,l,o,j;if(d){for(l=0;l<d.length;l++){o=d[l];j=h.getStyle(m,o);if(j){n[o]=j;k++}}}h.setAttrib(m,"style","");if(d&&k>0){h.setStyles(m,n)}else{if(m.nodeName=="SPAN"&&!m.className){h.remove(m,true)}}})}}if(b(e,"paste_remove_styles")||(b(e,"paste_remove_styles_if_webkit")&&tinymce.isWebKit)){c(h.select("*[style]",i.node),function(j){j.removeAttribute("style");j.removeAttribute("data-mce-style")})}else{if(tinymce.isWebKit){c(h.select("*",i.node),function(j){j.removeAttribute("data-mce-style")})}}},_convertLists:function(g,e){var i=g.editor.dom,h,l,d=-1,f,m=[],k,j;c(i.select("p",e.node),function(t){var q,u="",s,r,n,o;for(q=t.firstChild;q&&q.nodeType==3;q=q.nextSibling){u+=q.nodeValue}u=t.innerHTML.replace(/<\/?\w+[^>]*>/gi,"").replace(/ /g,"\u00a0");if(/^(__MCE_ITEM__)+[\u2022\u00b7\u00a7\u00d8o\u25CF]\s*\u00a0*/.test(u)){s="ul"}if(/^__MCE_ITEM__\s*\w+\.\s*\u00a0+/.test(u)){s="ol"}if(s){f=parseFloat(t.style.marginLeft||0);if(f>d){m.push(f)}if(!h||s!=k){h=i.create(s);i.insertAfter(h,t)}else{if(f>d){h=l.appendChild(i.create(s))}else{if(f<d){n=tinymce.inArray(m,f);o=i.getParents(h.parentNode,s);h=o[o.length-1-n]||h}}}c(i.select("span",t),function(v){var p=v.innerHTML.replace(/<\/?\w+[^>]*>/gi,"");if(s=="ul"&&/^__MCE_ITEM__[\u2022\u00b7\u00a7\u00d8o\u25CF]/.test(p)){i.remove(v)}else{if(/^__MCE_ITEM__[\s\S]*\w+\.( |\u00a0)*\s*/.test(p)){i.remove(v)}}});r=t.innerHTML;if(s=="ul"){r=t.innerHTML.replace(/__MCE_ITEM__/g,"").replace(/^[\u2022\u00b7\u00a7\u00d8o\u25CF]\s*( |\u00a0)+\s*/,"")}else{r=t.innerHTML.replace(/__MCE_ITEM__/g,"").replace(/^\s*\w+\.( |\u00a0)+\s*/,"")}l=h.appendChild(i.create("li",0,r));i.remove(t);d=f;k=s}else{h=d=0}});j=e.node.innerHTML;if(j.indexOf("__MCE_ITEM__")!=-1){e.node.innerHTML=j.replace(/__MCE_ITEM__/g,"")}},_insert:function(f,d){var e=this.editor,g=e.selection.getRng();if(!e.selection.isCollapsed()&&g.startContainer!=g.endContainer){e.getDoc().execCommand("Delete",false,null)}e.execCommand("mceInsertContent",false,f,{skip_undo:d})},_insertPlainText:function(g){var d=this.editor,e=b(d,"paste_text_linebreaktype"),i=b(d,"paste_text_replacements"),f=tinymce.is;function h(j){c(j,function(k){if(k.constructor==RegExp){g=g.replace(k,"")}else{g=g.replace(k[0],k[1])}})}if((typeof(g)==="string")&&(g.length>0)){if(/<(?:p|br|h[1-6]|ul|ol|dl|table|t[rdh]|div|blockquote|fieldset|pre|address|center)[^>]*>/i.test(g)){h([/[\n\r]+/g])}else{h([/\r+/g])}h([[/<\/(?:p|h[1-6]|ul|ol|dl|table|div|blockquote|fieldset|pre|address|center)>/gi,"\n\n"],[/<br[^>]*>|<\/tr>/gi,"\n"],[/<\/t[dh]>\s*<t[dh][^>]*>/gi,"\t"],/<[a-z!\/?][^>]*>/gi,[/ /gi," "],[/(?:(?!\n)\s)*(\n+)(?:(?!\n)\s)*/gi,"$1"],[/\n{3,}/g,"\n\n"]]);g=d.dom.decode(tinymce.html.Entities.encodeRaw(g));if(f(i,"array")){h(i)}else{if(f(i,"string")){h(new RegExp(i,"gi"))}}if(e=="none"){h([[/\n+/g," "]])}else{if(e=="br"){h([[/\n/g,"<br />"]])}else{if(e=="p"){h([[/\n+/g,"</p><p>"],[/^(.*<\/p>)(<p>)$/,"<p>$1"]])}else{h([[/\n\n/g,"</p><p>"],[/^(.*<\/p>)(<p>)$/,"<p>$1"],[/\n/g,"<br />"]])}}}d.execCommand("mceInsertContent",false,g)}},_legacySupport:function(){var e=this,d=e.editor;d.addCommand("mcePasteWord",function(){d.windowManager.open({file:e.url+"/pasteword.htm",width:parseInt(b(d,"paste_dialog_width")),height:parseInt(b(d,"paste_dialog_height")),inline:1})});if(b(d,"paste_text_use_dialog")){d.addCommand("mcePasteText",function(){d.windowManager.open({file:e.url+"/pastetext.htm",width:parseInt(b(d,"paste_dialog_width")),height:parseInt(b(d,"paste_dialog_height")),inline:1})})}d.addButton("pasteword",{title:"paste.paste_word_desc",cmd:"mcePasteWord"})}});tinymce.PluginManager.add("paste",tinymce.plugins.PastePlugin)})();
|
1
|
+
(function(){var c=tinymce.each,a={paste_auto_cleanup_on_paste:true,paste_enable_default_filters:true,paste_block_drop:false,paste_retain_style_properties:"none",paste_strip_class_attributes:"mso",paste_remove_spans:false,paste_remove_styles:false,paste_remove_styles_if_webkit:true,paste_convert_middot_lists:true,paste_convert_headers_to_strong:false,paste_dialog_width:"450",paste_dialog_height:"400",paste_max_consecutive_linebreaks:2,paste_text_use_dialog:false,paste_text_sticky:false,paste_text_sticky_default:false,paste_text_notifyalways:false,paste_text_linebreaktype:"combined",paste_text_replacements:[[/\u2026/g,"..."],[/[\x93\x94\u201c\u201d]/g,'"'],[/[\x60\x91\x92\u2018\u2019]/g,"'"]]};function b(d,e){return d.getParam(e,a[e])}tinymce.create("tinymce.plugins.PastePlugin",{init:function(d,e){var f=this;f.editor=d;f.url=e;f.onPreProcess=new tinymce.util.Dispatcher(f);f.onPostProcess=new tinymce.util.Dispatcher(f);f.onPreProcess.add(f._preProcess);f.onPostProcess.add(f._postProcess);f.onPreProcess.add(function(i,j){d.execCallback("paste_preprocess",i,j)});f.onPostProcess.add(function(i,j){d.execCallback("paste_postprocess",i,j)});d.onKeyDown.addToTop(function(i,j){if(((tinymce.isMac?j.metaKey:j.ctrlKey)&&j.keyCode==86)||(j.shiftKey&&j.keyCode==45)){return false}});d.pasteAsPlainText=b(d,"paste_text_sticky_default");function h(l,j){var k=d.dom,i;f.onPreProcess.dispatch(f,l);l.node=k.create("div",0,l.content);if(tinymce.isGecko){i=d.selection.getRng(true);if(i.startContainer==i.endContainer&&i.startContainer.nodeType==3){if(l.node.childNodes.length===1&&/^(p|h[1-6]|pre)$/i.test(l.node.firstChild.nodeName)&&l.content.indexOf("__MCE_ITEM__")===-1){k.remove(l.node.firstChild,true)}}}f.onPostProcess.dispatch(f,l);l.content=d.serializer.serialize(l.node,{getInner:1,forced_root_block:""});if((!j)&&(d.pasteAsPlainText)){f._insertPlainText(l.content);if(!b(d,"paste_text_sticky")){d.pasteAsPlainText=false;d.controlManager.setActive("pastetext",false)}}else{f._insert(l.content)}}d.addCommand("mceInsertClipboardContent",function(i,j){h(j,true)});if(!b(d,"paste_text_use_dialog")){d.addCommand("mcePasteText",function(j,i){var k=tinymce.util.Cookie;d.pasteAsPlainText=!d.pasteAsPlainText;d.controlManager.setActive("pastetext",d.pasteAsPlainText);if((d.pasteAsPlainText)&&(!k.get("tinymcePasteText"))){if(b(d,"paste_text_sticky")){d.windowManager.alert(d.translate("paste.plaintext_mode_sticky"))}else{d.windowManager.alert(d.translate("paste.plaintext_mode"))}if(!b(d,"paste_text_notifyalways")){k.set("tinymcePasteText","1",new Date(new Date().getFullYear()+1,12,31))}}})}d.addButton("pastetext",{title:"paste.paste_text_desc",cmd:"mcePasteText"});d.addButton("selectall",{title:"paste.selectall_desc",cmd:"selectall"});function g(s){var l,p,j,t,k=d.selection,o=d.dom,q=d.getBody(),i,r;if(s.clipboardData||o.doc.dataTransfer){r=(s.clipboardData||o.doc.dataTransfer).getData("Text");if(d.pasteAsPlainText){s.preventDefault();h({content:o.encode(r).replace(/\r?\n/g,"<br />")});return}}if(o.get("_mcePaste")){return}l=o.add(q,"div",{id:"_mcePaste","class":"mcePaste","data-mce-bogus":"1"},"\uFEFF\uFEFF");if(q!=d.getDoc().body){i=o.getPos(d.selection.getStart(),q).y}else{i=q.scrollTop+o.getViewPort(d.getWin()).y}o.setStyles(l,{position:"absolute",left:tinymce.isGecko?-40:0,top:i-25,width:1,height:1,overflow:"hidden"});if(tinymce.isIE){t=k.getRng();j=o.doc.body.createTextRange();j.moveToElementText(l);j.execCommand("Paste");o.remove(l);if(l.innerHTML==="\uFEFF\uFEFF"){d.execCommand("mcePasteWord");s.preventDefault();return}k.setRng(t);k.setContent("");setTimeout(function(){h({content:l.innerHTML})},0);return tinymce.dom.Event.cancel(s)}else{function m(n){n.preventDefault()}o.bind(d.getDoc(),"mousedown",m);o.bind(d.getDoc(),"keydown",m);p=d.selection.getRng();l=l.firstChild;j=d.getDoc().createRange();j.setStart(l,0);j.setEnd(l,2);k.setRng(j);window.setTimeout(function(){var u="",n;if(!o.select("div.mcePaste > div.mcePaste").length){n=o.select("div.mcePaste");c(n,function(w){var v=w.firstChild;if(v&&v.nodeName=="DIV"&&v.style.marginTop&&v.style.backgroundColor){o.remove(v,1)}c(o.select("span.Apple-style-span",w),function(x){o.remove(x,1)});c(o.select("br[data-mce-bogus]",w),function(x){o.remove(x)});if(w.parentNode.className!="mcePaste"){u+=w.innerHTML}})}else{u="<p>"+o.encode(r).replace(/\r?\n\r?\n/g,"</p><p>").replace(/\r?\n/g,"<br />")+"</p>"}c(o.select("div.mcePaste"),function(v){o.remove(v)});if(p){k.setRng(p)}h({content:u});o.unbind(d.getDoc(),"mousedown",m);o.unbind(d.getDoc(),"keydown",m)},0)}}if(b(d,"paste_auto_cleanup_on_paste")){if(tinymce.isOpera||/Firefox\/2/.test(navigator.userAgent)){d.onKeyDown.addToTop(function(i,j){if(((tinymce.isMac?j.metaKey:j.ctrlKey)&&j.keyCode==86)||(j.shiftKey&&j.keyCode==45)){g(j)}})}else{d.onPaste.addToTop(function(i,j){return g(j)})}}d.onInit.add(function(){d.controlManager.setActive("pastetext",d.pasteAsPlainText);if(b(d,"paste_block_drop")){d.dom.bind(d.getBody(),["dragend","dragover","draggesture","dragdrop","drop","drag"],function(i){i.preventDefault();i.stopPropagation();return false})}});f._legacySupport()},getInfo:function(){return{longname:"Paste text/word",author:"Moxiecode Systems AB",authorurl:"http://tinymce.moxiecode.com",infourl:"http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/paste",version:tinymce.majorVersion+"."+tinymce.minorVersion}},_preProcess:function(g,e){var k=this.editor,j=e.content,p=tinymce.grep,n=tinymce.explode,f=tinymce.trim,l,i;function d(h){c(h,function(o){if(o.constructor==RegExp){j=j.replace(o,"")}else{j=j.replace(o[0],o[1])}})}if(k.settings.paste_enable_default_filters==false){return}if(tinymce.isIE&&document.documentMode>=9&&/<(h[1-6r]|p|div|address|pre|form|table|tbody|thead|tfoot|th|tr|td|li|ol|ul|caption|blockquote|center|dl|dt|dd|dir|fieldset)/.test(e.content)){d([[/(?:<br> [\s\r\n]+|<br>)*(<\/?(h[1-6r]|p|div|address|pre|form|table|tbody|thead|tfoot|th|tr|td|li|ol|ul|caption|blockquote|center|dl|dt|dd|dir|fieldset)[^>]*>)(?:<br> [\s\r\n]+|<br>)*/g,"$1"]]);d([[/<br><br>/g,"<BR><BR>"],[/<br>/g," "],[/<BR><BR>/g,"<br>"]])}if(/class="?Mso|style="[^"]*\bmso-|w:WordDocument/i.test(j)||e.wordContent){e.wordContent=true;d([/^\s*( )+/gi,/( |<br[^>]*>)+\s*$/gi]);if(b(k,"paste_convert_headers_to_strong")){j=j.replace(/<p [^>]*class="?MsoHeading"?[^>]*>(.*?)<\/p>/gi,"<p><strong>$1</strong></p>")}if(b(k,"paste_convert_middot_lists")){d([[/<!--\[if !supportLists\]-->/gi,"$&__MCE_ITEM__"],[/(<span[^>]+(?:mso-list:|:\s*symbol)[^>]+>)/gi,"$1__MCE_ITEM__"],[/(<p[^>]+(?:MsoListParagraph)[^>]+>)/gi,"$1__MCE_ITEM__"]])}d([/<!--[\s\S]+?-->/gi,/<(!|script[^>]*>.*?<\/script(?=[>\s])|\/?(\?xml(:\w+)?|img|meta|link|style|\w:\w+)(?=[\s\/>]))[^>]*>/gi,[/<(\/?)s>/gi,"<$1strike>"],[/ /gi,"\u00a0"]]);do{l=j.length;j=j.replace(/(<[a-z][^>]*\s)(?:id|name|language|type|on\w+|\w+:\w+)=(?:"[^"]*"|\w+)\s?/gi,"$1")}while(l!=j.length);if(b(k,"paste_retain_style_properties").replace(/^none$/i,"").length==0){j=j.replace(/<\/?span[^>]*>/gi,"")}else{d([[/<span\s+style\s*=\s*"\s*mso-spacerun\s*:\s*yes\s*;?\s*"\s*>([\s\u00a0]*)<\/span>/gi,function(o,h){return(h.length>0)?h.replace(/./," ").slice(Math.floor(h.length/2)).split("").join("\u00a0"):""}],[/(<[a-z][^>]*)\sstyle="([^"]*)"/gi,function(t,h,r){var u=[],o=0,q=n(f(r).replace(/"/gi,"'"),";");c(q,function(s){var w,y,z=n(s,":");function x(A){return A+((A!=="0")&&(/\d$/.test(A)))?"px":""}if(z.length==2){w=z[0].toLowerCase();y=z[1].toLowerCase();switch(w){case"mso-padding-alt":case"mso-padding-top-alt":case"mso-padding-right-alt":case"mso-padding-bottom-alt":case"mso-padding-left-alt":case"mso-margin-alt":case"mso-margin-top-alt":case"mso-margin-right-alt":case"mso-margin-bottom-alt":case"mso-margin-left-alt":case"mso-table-layout-alt":case"mso-height":case"mso-width":case"mso-vertical-align-alt":u[o++]=w.replace(/^mso-|-alt$/g,"")+":"+x(y);return;case"horiz-align":u[o++]="text-align:"+y;return;case"vert-align":u[o++]="vertical-align:"+y;return;case"font-color":case"mso-foreground":u[o++]="color:"+y;return;case"mso-background":case"mso-highlight":u[o++]="background:"+y;return;case"mso-default-height":u[o++]="min-height:"+x(y);return;case"mso-default-width":u[o++]="min-width:"+x(y);return;case"mso-padding-between-alt":u[o++]="border-collapse:separate;border-spacing:"+x(y);return;case"text-line-through":if((y=="single")||(y=="double")){u[o++]="text-decoration:line-through"}return;case"mso-zero-height":if(y=="yes"){u[o++]="display:none"}return}if(/^(mso|column|font-emph|lang|layout|line-break|list-image|nav|panose|punct|row|ruby|sep|size|src|tab-|table-border|text-(?!align|decor|indent|trans)|top-bar|version|vnd|word-break)/.test(w)){return}u[o++]=w+":"+z[1]}});if(o>0){return h+' style="'+u.join(";")+'"'}else{return h}}]])}}if(b(k,"paste_convert_headers_to_strong")){d([[/<h[1-6][^>]*>/gi,"<p><strong>"],[/<\/h[1-6][^>]*>/gi,"</strong></p>"]])}d([[/Version:[\d.]+\nStartHTML:\d+\nEndHTML:\d+\nStartFragment:\d+\nEndFragment:\d+/gi,""]]);i=b(k,"paste_strip_class_attributes");if(i!=="none"){function m(q,o){if(i==="all"){return""}var h=p(n(o.replace(/^(["'])(.*)\1$/,"$2")," "),function(r){return(/^(?!mso)/i.test(r))});return h.length?' class="'+h.join(" ")+'"':""}j=j.replace(/ class="([^"]+)"/gi,m);j=j.replace(/ class=([\-\w]+)/gi,m)}if(b(k,"paste_remove_spans")){j=j.replace(/<\/?span[^>]*>/gi,"")}e.content=j},_postProcess:function(g,i){var f=this,e=f.editor,h=e.dom,d;if(e.settings.paste_enable_default_filters==false){return}if(i.wordContent){c(h.select("a",i.node),function(j){if(!j.href||j.href.indexOf("#_Toc")!=-1){h.remove(j,1)}});if(b(e,"paste_convert_middot_lists")){f._convertLists(g,i)}d=b(e,"paste_retain_style_properties");if((tinymce.is(d,"string"))&&(d!=="all")&&(d!=="*")){d=tinymce.explode(d.replace(/^none$/i,""));c(h.select("*",i.node),function(m){var n={},k=0,l,o,j;if(d){for(l=0;l<d.length;l++){o=d[l];j=h.getStyle(m,o);if(j){n[o]=j;k++}}}h.setAttrib(m,"style","");if(d&&k>0){h.setStyles(m,n)}else{if(m.nodeName=="SPAN"&&!m.className){h.remove(m,true)}}})}}if(b(e,"paste_remove_styles")||(b(e,"paste_remove_styles_if_webkit")&&tinymce.isWebKit)){c(h.select("*[style]",i.node),function(j){j.removeAttribute("style");j.removeAttribute("data-mce-style")})}else{if(tinymce.isWebKit){c(h.select("*",i.node),function(j){j.removeAttribute("data-mce-style")})}}},_convertLists:function(g,e){var i=g.editor.dom,h,l,d=-1,f,m=[],k,j;c(i.select("p",e.node),function(t){var q,u="",s,r,n,o;for(q=t.firstChild;q&&q.nodeType==3;q=q.nextSibling){u+=q.nodeValue}u=t.innerHTML.replace(/<\/?\w+[^>]*>/gi,"").replace(/ /g,"\u00a0");if(/^(__MCE_ITEM__)+[\u2022\u00b7\u00a7\u00d8o\u25CF]\s*\u00a0*/.test(u)){s="ul"}if(/^__MCE_ITEM__\s*\w+\.\s*\u00a0+/.test(u)){s="ol"}if(s){f=parseFloat(t.style.marginLeft||0);if(f>d){m.push(f)}if(!h||s!=k){h=i.create(s);i.insertAfter(h,t)}else{if(f>d){h=l.appendChild(i.create(s))}else{if(f<d){n=tinymce.inArray(m,f);o=i.getParents(h.parentNode,s);h=o[o.length-1-n]||h}}}c(i.select("span",t),function(v){var p=v.innerHTML.replace(/<\/?\w+[^>]*>/gi,"");if(s=="ul"&&/^__MCE_ITEM__[\u2022\u00b7\u00a7\u00d8o\u25CF]/.test(p)){i.remove(v)}else{if(/^__MCE_ITEM__[\s\S]*\w+\.( |\u00a0)*\s*/.test(p)){i.remove(v)}}});r=t.innerHTML;if(s=="ul"){r=t.innerHTML.replace(/__MCE_ITEM__/g,"").replace(/^[\u2022\u00b7\u00a7\u00d8o\u25CF]\s*( |\u00a0)+\s*/,"")}else{r=t.innerHTML.replace(/__MCE_ITEM__/g,"").replace(/^\s*\w+\.( |\u00a0)+\s*/,"")}l=h.appendChild(i.create("li",0,r));i.remove(t);d=f;k=s}else{h=d=0}});j=e.node.innerHTML;if(j.indexOf("__MCE_ITEM__")!=-1){e.node.innerHTML=j.replace(/__MCE_ITEM__/g,"")}},_insert:function(f,d){var e=this.editor,g=e.selection.getRng();if(!e.selection.isCollapsed()&&g.startContainer!=g.endContainer){e.getDoc().execCommand("Delete",false,null)}e.execCommand("mceInsertContent",false,f,{skip_undo:d})},_insertPlainText:function(j){var h=this.editor,f=b(h,"paste_text_linebreaktype"),k=b(h,"paste_text_replacements"),g=tinymce.is;function e(m){c(m,function(n){if(n.constructor==RegExp){j=j.replace(n,"")}else{j=j.replace(n[0],n[1])}})}if((typeof(j)==="string")&&(j.length>0)){if(/<(?:p|br|h[1-6]|ul|ol|dl|table|t[rdh]|div|blockquote|fieldset|pre|address|center)[^>]*>/i.test(j)){e([/[\n\r]+/g])}else{e([/\r+/g])}e([[/<\/(?:p|h[1-6]|ul|ol|dl|table|div|blockquote|fieldset|pre|address|center)>/gi,"\n\n"],[/<br[^>]*>|<\/tr>/gi,"\n"],[/<\/t[dh]>\s*<t[dh][^>]*>/gi,"\t"],/<[a-z!\/?][^>]*>/gi,[/ /gi," "],[/(?:(?!\n)\s)*(\n+)(?:(?!\n)\s)*/gi,"$1"]]);var d=Number(b(h,"paste_max_consecutive_linebreaks"));if(d>-1){var l=new RegExp("\n{"+(d+1)+",}","g");var i="";while(i.length<d){i+="\n"}e([[l,i]])}j=h.dom.decode(tinymce.html.Entities.encodeRaw(j));if(g(k,"array")){e(k)}else{if(g(k,"string")){e(new RegExp(k,"gi"))}}if(f=="none"){e([[/\n+/g," "]])}else{if(f=="br"){e([[/\n/g,"<br />"]])}else{if(f=="p"){e([[/\n+/g,"</p><p>"],[/^(.*<\/p>)(<p>)$/,"<p>$1"]])}else{e([[/\n\n/g,"</p><p>"],[/^(.*<\/p>)(<p>)$/,"<p>$1"],[/\n/g,"<br />"]])}}}h.execCommand("mceInsertContent",false,j)}},_legacySupport:function(){var e=this,d=e.editor;d.addCommand("mcePasteWord",function(){d.windowManager.open({file:e.url+"/pasteword.htm",width:parseInt(b(d,"paste_dialog_width")),height:parseInt(b(d,"paste_dialog_height")),inline:1})});if(b(d,"paste_text_use_dialog")){d.addCommand("mcePasteText",function(){d.windowManager.open({file:e.url+"/pastetext.htm",width:parseInt(b(d,"paste_dialog_width")),height:parseInt(b(d,"paste_dialog_height")),inline:1})})}d.addButton("pasteword",{title:"paste.paste_word_desc",cmd:"mcePasteWord"})}});tinymce.PluginManager.add("paste",tinymce.plugins.PastePlugin)})();
|
@@ -23,6 +23,7 @@
|
|
23
23
|
paste_convert_headers_to_strong : false,
|
24
24
|
paste_dialog_width : "450",
|
25
25
|
paste_dialog_height : "400",
|
26
|
+
paste_max_consecutive_linebreaks: 2,
|
26
27
|
paste_text_use_dialog : false,
|
27
28
|
paste_text_sticky : false,
|
28
29
|
paste_text_sticky_default : false,
|
@@ -359,7 +360,7 @@
|
|
359
360
|
}
|
360
361
|
|
361
362
|
// IE9 adds BRs before/after block elements when contents is pasted from word or for example another browser
|
362
|
-
if (tinymce.isIE && document.documentMode >= 9) {
|
363
|
+
if (tinymce.isIE && document.documentMode >= 9 && /<(h[1-6r]|p|div|address|pre|form|table|tbody|thead|tfoot|th|tr|td|li|ol|ul|caption|blockquote|center|dl|dt|dd|dir|fieldset)/.test(o.content)) {
|
363
364
|
// IE9 adds BRs before/after block elements when contents is pasted from word or for example another browser
|
364
365
|
process([[/(?:<br> [\s\r\n]+|<br>)*(<\/?(h[1-6r]|p|div|address|pre|form|table|tbody|thead|tfoot|th|tr|td|li|ol|ul|caption|blockquote|center|dl|dt|dd|dir|fieldset)[^>]*>)(?:<br> [\s\r\n]+|<br>)*/g, '$1']]);
|
365
366
|
|
@@ -790,10 +791,23 @@
|
|
790
791
|
[/<\/t[dh]>\s*<t[dh][^>]*>/gi, "\t"], // Table cells get tabs betweem them
|
791
792
|
/<[a-z!\/?][^>]*>/gi, // Delete all remaining tags
|
792
793
|
[/ /gi, " "], // Convert non-break spaces to regular spaces (remember, *plain text*)
|
793
|
-
[/(?:(?!\n)\s)*(\n+)(?:(?!\n)\s)*/gi, "$1"]
|
794
|
-
[/\n{3,}/g, "\n\n"] // Max. 2 consecutive linebreaks
|
794
|
+
[/(?:(?!\n)\s)*(\n+)(?:(?!\n)\s)*/gi, "$1"] // Cool little RegExp deletes whitespace around linebreak chars.
|
795
795
|
]);
|
796
796
|
|
797
|
+
var maxLinebreaks = Number(getParam(ed, "paste_max_consecutive_linebreaks"));
|
798
|
+
if (maxLinebreaks > -1) {
|
799
|
+
var maxLinebreaksRegex = new RegExp("\n{" + (maxLinebreaks + 1) + ",}", "g");
|
800
|
+
var linebreakReplacement = "";
|
801
|
+
|
802
|
+
while (linebreakReplacement.length < maxLinebreaks) {
|
803
|
+
linebreakReplacement += "\n";
|
804
|
+
}
|
805
|
+
|
806
|
+
process([
|
807
|
+
[maxLinebreaksRegex, linebreakReplacement] // Limit max consecutive linebreaks
|
808
|
+
]);
|
809
|
+
}
|
810
|
+
|
797
811
|
content = ed.dom.decode(tinymce.html.Entities.encodeRaw(content));
|
798
812
|
|
799
813
|
// Perform default or custom replacements
|
@@ -1 +1 @@
|
|
1
|
-
tinyMCE.addI18n('de.paste_dlg',{"word_title":"
|
1
|
+
tinyMCE.addI18n('de.paste_dlg',{"word_title":"Strg V auf der Tastatur dr\u00fccken, um den Text einzuf\u00fcgen.","text_linebreaks":"Zeilenumbr\u00fcche beibehalten","text_title":"Strg V auf der Tastatur dr\u00fccken, um den Text einzuf\u00fcgen."});
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
@@ -0,0 +1 @@
|
|
1
|
+
tinyMCE.addI18n('nb.paste_dlg',{"word_title":"Bruk CTRL+V p\u00e5 tastaturet for \u00e5 lime inn i dette vinduet.","text_linebreaks":"Behold tekstbryting","text_title":"Bruk CTRL+V p\u00e5 tastaturet for \u00e5 lime inn i dette vinduet."});
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
@@ -0,0 +1 @@
|
|
1
|
+
tinyMCE.addI18n('nb.searchreplace_dlg',{findwhat:"Finn hva",replacewith:"Erstatt med",direction:"Retning",up:"Oppover",down:"Nedover",mcase:"Skill mellom store og sm\u00e5 tegn",findnext:"Finn neste",allreplaced:"Alle forekomster av s\u00f8kestrengen er erstattet.","searchnext_desc":"S\u00f8k igjen",notfound:"S\u00f8ket er avsluttet. Fant ikke s\u00f8kestrengen.","search_title":"S\u00f8k","replace_title":"S\u00f8k/Erstatt",replaceall:"Erstatt alt",replace:"Erstatt"});
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
@@ -93,7 +93,7 @@
|
|
93
93
|
<input type="submit" id="insert" name="insert" value="{#searchreplace_dlg.findnext}" />
|
94
94
|
<input type="button" class="button" id="replaceBtn" name="replaceBtn" value="{#searchreplace_dlg.replace}" onclick="SearchReplaceDialog.searchNext('current');" />
|
95
95
|
<input type="button" class="button" id="replaceAllBtn" name="replaceAllBtn" value="{#searchreplace_dlg.replaceall}" onclick="SearchReplaceDialog.searchNext('all');" />
|
96
|
-
<input type="button" id="cancel" name="
|
96
|
+
<input type="button" id="cancel" name="close" value="{#close}" onclick="tinyMCEPopup.close();" />
|
97
97
|
</div>
|
98
98
|
</form>
|
99
99
|
</body>
|
@@ -1 +1 @@
|
|
1
|
-
(function(){var a=tinymce.util.JSONRequest,c=tinymce.each,b=tinymce.DOM;tinymce.create("tinymce.plugins.SpellcheckerPlugin",{getInfo:function(){return{longname:"Spellchecker",author:"Moxiecode Systems AB",authorurl:"http://tinymce.moxiecode.com",infourl:"http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/spellchecker",version:tinymce.majorVersion+"."+tinymce.minorVersion}},init:function(e,f){var g=this,d;g.url=f;g.editor=e;g.rpcUrl=e.getParam("spellchecker_rpc_url","{backend}");if(g.rpcUrl=="{backend}"){if(tinymce.isIE){return}g.hasSupport=true;e.onContextMenu.addToTop(function(h,i){if(g.active){return false}})}e.addCommand("mceSpellCheck",function(){if(g.rpcUrl=="{backend}"){g.editor.getBody().spellcheck=g.active=!g.active;return}if(!g.active){e.setProgressState(1);g._sendRPC("checkWords",[g.selectedLang,g._getWords()],function(h){if(h.length>0){g.active=1;g._markWords(h);e.setProgressState(0);e.nodeChanged()}else{e.setProgressState(0);if(e.getParam("spellchecker_report_no_misspellings",true)){e.windowManager.alert("spellchecker.no_mpell")}}})}else{g._done()}});if(e.settings.content_css!==false){e.contentCSS.push(f+"/css/content.css")}e.onClick.add(g._showMenu,g);e.onContextMenu.add(g._showMenu,g);e.onBeforeGetContent.add(function(){if(g.active){g._removeWords()}});e.onNodeChange.add(function(i,h){h.setActive("spellchecker",g.active)});e.onSetContent.add(function(){g._done()});e.onBeforeGetContent.add(function(){g._done()});e.onBeforeExecCommand.add(function(h,i){if(i=="mceFullScreen"){g._done()}});g.languages={};c(e.getParam("spellchecker_languages","+English=en,Danish=da,Dutch=nl,Finnish=fi,French=fr,German=de,Italian=it,Polish=pl,Portuguese=pt,Spanish=es,Swedish=sv","hash"),function(i,h){if(h.indexOf("+")===0){h=h.substring(1);g.selectedLang=i}g.languages[h]=i})},createControl:function(h,d){var f=this,g,e=f.editor;if(h=="spellchecker"){if(f.rpcUrl=="{backend}"){if(f.hasSupport){g=d.createButton(h,{title:"spellchecker.desc",cmd:"mceSpellCheck",scope:f})}return g}g=d.createSplitButton(h,{title:"spellchecker.desc",cmd:"mceSpellCheck",scope:f});g.onRenderMenu.add(function(j,i){i.add({title:"spellchecker.langs","class":"mceMenuItemTitle"}).setDisabled(1);c(f.languages,function(n,m){var p={icon:1},l;p.onclick=function(){if(n==f.selectedLang){return}l.setSelected(1);f.selectedItem.setSelected(0);f.selectedItem=l;f.selectedLang=n};p.title=m;l=i.add(p);l.setSelected(n==f.selectedLang);if(n==f.selectedLang){f.selectedItem=l}})});return g}},_walk:function(i,g){var h=this.editor.getDoc(),e;if(h.createTreeWalker){e=h.createTreeWalker(i,NodeFilter.SHOW_TEXT,null,false);while((i=e.nextNode())!=null){g.call(this,i)}}else{tinymce.walk(i,g,"childNodes")}},_getSeparators:function(){var e="",d,f=this.editor.getParam("spellchecker_word_separator_chars",'\\s!"#$%&()*+,-./:;<=>?@[]^_{|}§©«®±¶·¸»¼½¾¿×÷¤\u201d\u201c');for(d=0;d<f.length;d++){e+="\\"+f.charAt(d)}return e},_getWords:function(){var e=this.editor,g=[],d="",f={},h=[];this._walk(e.getBody(),function(i){if(i.nodeType==3){d+=i.nodeValue+" "}});if(e.getParam("spellchecker_word_pattern")){h=d.match("("+e.getParam("spellchecker_word_pattern")+")","gi")}else{d=d.replace(new RegExp("([0-9]|["+this._getSeparators()+"])","g")," ");d=tinymce.trim(d.replace(/(\s+)/g," "));h=d.split(" ")}c(h,function(i){if(!f[i]){g.push(i);f[i]=1}});return g},_removeWords:function(
|
1
|
+
(function(){var a=tinymce.util.JSONRequest,c=tinymce.each,b=tinymce.DOM;tinymce.create("tinymce.plugins.SpellcheckerPlugin",{getInfo:function(){return{longname:"Spellchecker",author:"Moxiecode Systems AB",authorurl:"http://tinymce.moxiecode.com",infourl:"http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/spellchecker",version:tinymce.majorVersion+"."+tinymce.minorVersion}},init:function(e,f){var g=this,d;g.url=f;g.editor=e;g.rpcUrl=e.getParam("spellchecker_rpc_url","{backend}");if(g.rpcUrl=="{backend}"){if(tinymce.isIE){return}g.hasSupport=true;e.onContextMenu.addToTop(function(h,i){if(g.active){return false}})}e.addCommand("mceSpellCheck",function(){if(g.rpcUrl=="{backend}"){g.editor.getBody().spellcheck=g.active=!g.active;return}if(!g.active){e.setProgressState(1);g._sendRPC("checkWords",[g.selectedLang,g._getWords()],function(h){if(h.length>0){g.active=1;g._markWords(h);e.setProgressState(0);e.nodeChanged()}else{e.setProgressState(0);if(e.getParam("spellchecker_report_no_misspellings",true)){e.windowManager.alert("spellchecker.no_mpell")}}})}else{g._done()}});if(e.settings.content_css!==false){e.contentCSS.push(f+"/css/content.css")}e.onClick.add(g._showMenu,g);e.onContextMenu.add(g._showMenu,g);e.onBeforeGetContent.add(function(){if(g.active){g._removeWords()}});e.onNodeChange.add(function(i,h){h.setActive("spellchecker",g.active)});e.onSetContent.add(function(){g._done()});e.onBeforeGetContent.add(function(){g._done()});e.onBeforeExecCommand.add(function(h,i){if(i=="mceFullScreen"){g._done()}});g.languages={};c(e.getParam("spellchecker_languages","+English=en,Danish=da,Dutch=nl,Finnish=fi,French=fr,German=de,Italian=it,Polish=pl,Portuguese=pt,Spanish=es,Swedish=sv","hash"),function(i,h){if(h.indexOf("+")===0){h=h.substring(1);g.selectedLang=i}g.languages[h]=i})},createControl:function(h,d){var f=this,g,e=f.editor;if(h=="spellchecker"){if(f.rpcUrl=="{backend}"){if(f.hasSupport){g=d.createButton(h,{title:"spellchecker.desc",cmd:"mceSpellCheck",scope:f})}return g}g=d.createSplitButton(h,{title:"spellchecker.desc",cmd:"mceSpellCheck",scope:f});g.onRenderMenu.add(function(j,i){i.add({title:"spellchecker.langs","class":"mceMenuItemTitle"}).setDisabled(1);c(f.languages,function(n,m){var p={icon:1},l;p.onclick=function(){if(n==f.selectedLang){return}l.setSelected(1);f.selectedItem.setSelected(0);f.selectedItem=l;f.selectedLang=n};p.title=m;l=i.add(p);l.setSelected(n==f.selectedLang);if(n==f.selectedLang){f.selectedItem=l}})});return g}},_walk:function(i,g){var h=this.editor.getDoc(),e;if(h.createTreeWalker){e=h.createTreeWalker(i,NodeFilter.SHOW_TEXT,null,false);while((i=e.nextNode())!=null){g.call(this,i)}}else{tinymce.walk(i,g,"childNodes")}},_getSeparators:function(){var e="",d,f=this.editor.getParam("spellchecker_word_separator_chars",'\\s!"#$%&()*+,-./:;<=>?@[]^_{|}§©«®±¶·¸»¼½¾¿×÷¤\u201d\u201c');for(d=0;d<f.length;d++){e+="\\"+f.charAt(d)}return e},_getWords:function(){var e=this.editor,g=[],d="",f={},h=[];this._walk(e.getBody(),function(i){if(i.nodeType==3){d+=i.nodeValue+" "}});if(e.getParam("spellchecker_word_pattern")){h=d.match("("+e.getParam("spellchecker_word_pattern")+")","gi")}else{d=d.replace(new RegExp("([0-9]|["+this._getSeparators()+"])","g")," ");d=tinymce.trim(d.replace(/(\s+)/g," "));h=d.split(" ")}c(h,function(i){if(!f[i]){g.push(i);f[i]=1}});return g},_removeWords:function(d){var e=this.editor,h=e.dom,g=e.selection,f=g.getRng(true);c(h.select("span").reverse(),function(i){if(i&&(h.hasClass(i,"mceItemHiddenSpellWord")||h.hasClass(i,"mceItemHidden"))){if(!d||h.decode(i.innerHTML)==d){h.remove(i,1)}}});g.setRng(f)},_markWords:function(l){var h=this.editor,g=h.dom,j=h.getDoc(),i=h.selection,d=i.getRng(true),e=[],k=l.join("|"),m=this._getSeparators(),f=new RegExp("(^|["+m+"])("+k+")(?=["+m+"]|$)","g");this._walk(h.getBody(),function(o){if(o.nodeType==3){e.push(o)}});c(e,function(t){var r,q,o,s,p=t.nodeValue;if(f.test(p)){p=g.encode(p);q=g.create("span",{"class":"mceItemHidden"});if(tinymce.isIE){p=p.replace(f,"$1<mcespell>$2</mcespell>");while((s=p.indexOf("<mcespell>"))!=-1){o=p.substring(0,s);if(o.length){r=j.createTextNode(g.decode(o));q.appendChild(r)}p=p.substring(s+10);s=p.indexOf("</mcespell>");o=p.substring(0,s);p=p.substring(s+11);q.appendChild(g.create("span",{"class":"mceItemHiddenSpellWord"},o))}if(p.length){r=j.createTextNode(g.decode(p));q.appendChild(r)}}else{q.innerHTML=p.replace(f,'$1<span class="mceItemHiddenSpellWord">$2</span>')}g.replace(q,t)}});i.setRng(d)},_showMenu:function(h,j){var i=this,h=i.editor,d=i._menu,l,k=h.dom,g=k.getViewPort(h.getWin()),f=j.target;j=0;if(!d){d=h.controlManager.createDropMenu("spellcheckermenu",{"class":"mceNoIcons"});i._menu=d}if(k.hasClass(f,"mceItemHiddenSpellWord")){d.removeAll();d.add({title:"spellchecker.wait","class":"mceMenuItemTitle"}).setDisabled(1);i._sendRPC("getSuggestions",[i.selectedLang,k.decode(f.innerHTML)],function(m){var e;d.removeAll();if(m.length>0){d.add({title:"spellchecker.sug","class":"mceMenuItemTitle"}).setDisabled(1);c(m,function(n){d.add({title:n,onclick:function(){k.replace(h.getDoc().createTextNode(n),f);i._checkDone()}})});d.addSeparator()}else{d.add({title:"spellchecker.no_sug","class":"mceMenuItemTitle"}).setDisabled(1)}if(h.getParam("show_ignore_words",true)){e=i.editor.getParam("spellchecker_enable_ignore_rpc","");d.add({title:"spellchecker.ignore_word",onclick:function(){var n=f.innerHTML;k.remove(f,1);i._checkDone();if(e){h.setProgressState(1);i._sendRPC("ignoreWord",[i.selectedLang,n],function(o){h.setProgressState(0)})}}});d.add({title:"spellchecker.ignore_words",onclick:function(){var n=f.innerHTML;i._removeWords(k.decode(n));i._checkDone();if(e){h.setProgressState(1);i._sendRPC("ignoreWords",[i.selectedLang,n],function(o){h.setProgressState(0)})}}})}if(i.editor.getParam("spellchecker_enable_learn_rpc")){d.add({title:"spellchecker.learn_word",onclick:function(){var n=f.innerHTML;k.remove(f,1);i._checkDone();h.setProgressState(1);i._sendRPC("learnWord",[i.selectedLang,n],function(o){h.setProgressState(0)})}})}d.update()});l=b.getPos(h.getContentAreaContainer());d.settings.offset_x=l.x;d.settings.offset_y=l.y;h.selection.select(f);l=k.getPos(f);d.showMenu(l.x,l.y+f.offsetHeight-g.y);return tinymce.dom.Event.cancel(j)}else{d.hideMenu()}},_checkDone:function(){var e=this,d=e.editor,g=d.dom,f;c(g.select("span"),function(h){if(h&&g.hasClass(h,"mceItemHiddenSpellWord")){f=true;return false}});if(!f){e._done()}},_done:function(){var d=this,e=d.active;if(d.active){d.active=0;d._removeWords();if(d._menu){d._menu.hideMenu()}if(e){d.editor.nodeChanged()}}},_sendRPC:function(e,g,d){var f=this;a.sendRPC({url:f.rpcUrl,method:e,params:g,success:d,error:function(i,h){f.editor.setProgressState(0);f.editor.windowManager.alert(i.errstr||("Error response: "+h.responseText))}})}});tinymce.PluginManager.add("spellchecker",tinymce.plugins.SpellcheckerPlugin)})();
|
@@ -208,7 +208,7 @@
|
|
208
208
|
},
|
209
209
|
|
210
210
|
_removeWords : function(w) {
|
211
|
-
var ed = this.editor, dom = ed.dom, se = ed.selection,
|
211
|
+
var ed = this.editor, dom = ed.dom, se = ed.selection, r = se.getRng(true);
|
212
212
|
|
213
213
|
each(dom.select('span').reverse(), function(n) {
|
214
214
|
if (n && (dom.hasClass(n, 'mceItemHiddenSpellWord') || dom.hasClass(n, 'mceItemHidden'))) {
|
@@ -217,11 +217,11 @@
|
|
217
217
|
}
|
218
218
|
});
|
219
219
|
|
220
|
-
se.
|
220
|
+
se.setRng(r);
|
221
221
|
},
|
222
222
|
|
223
223
|
_markWords : function(wl) {
|
224
|
-
var ed = this.editor, dom = ed.dom, doc = ed.getDoc(), se = ed.selection,
|
224
|
+
var ed = this.editor, dom = ed.dom, doc = ed.getDoc(), se = ed.selection, r = se.getRng(true), nl = [],
|
225
225
|
w = wl.join('|'), re = this._getSeparators(), rx = new RegExp('(^|[' + re + '])(' + w + ')(?=[' + re + ']|$)', 'g');
|
226
226
|
|
227
227
|
// Collect all text nodes
|
@@ -279,7 +279,7 @@
|
|
279
279
|
}
|
280
280
|
});
|
281
281
|
|
282
|
-
se.
|
282
|
+
se.setRng(r);
|
283
283
|
},
|
284
284
|
|
285
285
|
_showMenu : function(ed, e) {
|
@@ -5,6 +5,7 @@ select, #block_text_indent, #box_width, #box_height, #box_padding_top, #box_padd
|
|
5
5
|
#box_margin_top, #box_margin_right, #box_margin_bottom, #box_margin_left, #positioning_width, #positioning_height, #positioning_zindex {width:70px;}
|
6
6
|
#positioning_placement_top, #positioning_placement_right, #positioning_placement_bottom, #positioning_placement_left {width:70px;}
|
7
7
|
#positioning_clip_top, #positioning_clip_right, #positioning_clip_bottom, #positioning_clip_left {width:70px;}
|
8
|
+
.panel_toggle_insert_span {padding-top:10px;}
|
8
9
|
.panel_wrapper div.current {padding-top:10px;height:230px;}
|
9
10
|
.delim {border-left:1px solid gray;}
|
10
11
|
.tdelim {border-bottom:1px solid gray;}
|
@@ -1 +1 @@
|
|
1
|
-
(function(){tinymce.create("tinymce.plugins.StylePlugin",{init:function(a,b){a.addCommand("mceStyleProps",function(){a.windowManager.open({file:b+"/props.htm",width:480+parseInt(a.getLang("style.delta_width",0)),height:
|
1
|
+
(function(){tinymce.create("tinymce.plugins.StylePlugin",{init:function(a,b){a.addCommand("mceStyleProps",function(){var c=false;var f=a.selection.getSelectedBlocks();var d=[];if(f.length===1){d.push(a.selection.getNode().style.cssText)}else{tinymce.each(f,function(g){d.push(a.dom.getAttrib(g,"style"))});c=true}a.windowManager.open({file:b+"/props.htm",width:480+parseInt(a.getLang("style.delta_width",0)),height:340+parseInt(a.getLang("style.delta_height",0)),inline:1},{applyStyleToBlocks:c,plugin_url:b,styles:d})});a.addCommand("mceSetElementStyle",function(d,c){if(e=a.selection.getNode()){a.dom.setAttrib(e,"style",c);a.execCommand("mceRepaint")}});a.onNodeChange.add(function(d,c,f){c.setDisabled("styleprops",f.nodeName==="BODY")});a.addButton("styleprops",{title:"style.desc",cmd:"mceStyleProps"})},getInfo:function(){return{longname:"Style",author:"Moxiecode Systems AB",authorurl:"http://tinymce.moxiecode.com",infourl:"http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/style",version:tinymce.majorVersion+"."+tinymce.minorVersion}}});tinymce.PluginManager.add("style",tinymce.plugins.StylePlugin)})();
|
@@ -13,14 +13,30 @@
|
|
13
13
|
init : function(ed, url) {
|
14
14
|
// Register commands
|
15
15
|
ed.addCommand('mceStyleProps', function() {
|
16
|
+
|
17
|
+
var applyStyleToBlocks = false;
|
18
|
+
var blocks = ed.selection.getSelectedBlocks();
|
19
|
+
var styles = [];
|
20
|
+
|
21
|
+
if (blocks.length === 1) {
|
22
|
+
styles.push(ed.selection.getNode().style.cssText);
|
23
|
+
}
|
24
|
+
else {
|
25
|
+
tinymce.each(blocks, function(block) {
|
26
|
+
styles.push(ed.dom.getAttrib(block, 'style'));
|
27
|
+
});
|
28
|
+
applyStyleToBlocks = true;
|
29
|
+
}
|
30
|
+
|
16
31
|
ed.windowManager.open({
|
17
32
|
file : url + '/props.htm',
|
18
33
|
width : 480 + parseInt(ed.getLang('style.delta_width', 0)),
|
19
|
-
height :
|
34
|
+
height : 340 + parseInt(ed.getLang('style.delta_height', 0)),
|
20
35
|
inline : 1
|
21
36
|
}, {
|
37
|
+
applyStyleToBlocks : applyStyleToBlocks,
|
22
38
|
plugin_url : url,
|
23
|
-
|
39
|
+
styles : styles
|
24
40
|
});
|
25
41
|
});
|
26
42
|
|
@@ -52,4 +68,4 @@
|
|
52
68
|
|
53
69
|
// Register plugin
|
54
70
|
tinymce.PluginManager.add('style', tinymce.plugins.StylePlugin);
|
55
|
-
})();
|
71
|
+
})();
|
@@ -27,10 +27,41 @@ var defaultBorderStyle = "none;solid;dashed;dotted;double;groove;ridge;inset;out
|
|
27
27
|
var defaultBorderWidth = "thin;medium;thick";
|
28
28
|
var defaultListType = "disc;circle;square;decimal;lower-roman;upper-roman;lower-alpha;upper-alpha;none";
|
29
29
|
|
30
|
-
function
|
30
|
+
function aggregateStyles(allStyles) {
|
31
|
+
var mergedStyles = {};
|
32
|
+
|
33
|
+
tinymce.each(allStyles, function(style) {
|
34
|
+
if (style !== '') {
|
35
|
+
var parsedStyles = tinyMCEPopup.editor.dom.parseStyle(style);
|
36
|
+
for (var name in parsedStyles) {
|
37
|
+
if (parsedStyles.hasOwnProperty(name)) {
|
38
|
+
if (mergedStyles[name] === undefined) {
|
39
|
+
mergedStyles[name] = parsedStyles[name];
|
40
|
+
}
|
41
|
+
else if (name === 'text-decoration') {
|
42
|
+
if (mergedStyles[name].indexOf(parsedStyles[name]) === -1) {
|
43
|
+
mergedStyles[name] = mergedStyles[name] +' '+ parsedStyles[name];
|
44
|
+
}
|
45
|
+
}
|
46
|
+
}
|
47
|
+
}
|
48
|
+
}
|
49
|
+
});
|
50
|
+
|
51
|
+
return mergedStyles;
|
52
|
+
}
|
53
|
+
|
54
|
+
var applyActionIsInsert;
|
55
|
+
var existingStyles;
|
56
|
+
|
57
|
+
function init(ed) {
|
31
58
|
var ce = document.getElementById('container'), h;
|
32
59
|
|
33
|
-
|
60
|
+
existingStyles = aggregateStyles(tinyMCEPopup.getWindowArg('styles'));
|
61
|
+
ce.style.cssText = tinyMCEPopup.editor.dom.serializeStyle(existingStyles);
|
62
|
+
|
63
|
+
applyActionIsInsert = ed.getParam("edit_css_style_insert_span", false);
|
64
|
+
document.getElementById('toggle_insert_span').checked = applyActionIsInsert;
|
34
65
|
|
35
66
|
h = getBrowserHTML('background_image_browser','background_image','image','advimage');
|
36
67
|
document.getElementById("background_image_browser").innerHTML = h;
|
@@ -144,6 +175,8 @@ function setupFormData() {
|
|
144
175
|
f.text_overline.checked = inStr(ce.style.textDecoration, 'overline');
|
145
176
|
f.text_linethrough.checked = inStr(ce.style.textDecoration, 'line-through');
|
146
177
|
f.text_blink.checked = inStr(ce.style.textDecoration, 'blink');
|
178
|
+
f.text_none.checked = inStr(ce.style.textDecoration, 'none');
|
179
|
+
updateTextDecorations();
|
147
180
|
|
148
181
|
// Setup background fields
|
149
182
|
|
@@ -366,13 +399,41 @@ function hasEqualValues(a) {
|
|
366
399
|
return true;
|
367
400
|
}
|
368
401
|
|
402
|
+
function toggleApplyAction() {
|
403
|
+
applyActionIsInsert = ! applyActionIsInsert;
|
404
|
+
}
|
405
|
+
|
369
406
|
function applyAction() {
|
370
407
|
var ce = document.getElementById('container'), ed = tinyMCEPopup.editor;
|
371
408
|
|
372
409
|
generateCSS();
|
373
410
|
|
374
411
|
tinyMCEPopup.restoreSelection();
|
375
|
-
|
412
|
+
|
413
|
+
var newStyles = tinyMCEPopup.editor.dom.parseStyle(ce.style.cssText);
|
414
|
+
|
415
|
+
if (applyActionIsInsert) {
|
416
|
+
ed.formatter.register('plugin_style', {
|
417
|
+
inline: 'span', styles: existingStyles
|
418
|
+
});
|
419
|
+
ed.formatter.remove('plugin_style');
|
420
|
+
|
421
|
+
ed.formatter.register('plugin_style', {
|
422
|
+
inline: 'span', styles: newStyles
|
423
|
+
});
|
424
|
+
ed.formatter.apply('plugin_style');
|
425
|
+
} else {
|
426
|
+
var nodes;
|
427
|
+
|
428
|
+
if (tinyMCEPopup.getWindowArg('applyStyleToBlocks')) {
|
429
|
+
nodes = ed.selection.getSelectedBlocks();
|
430
|
+
}
|
431
|
+
else {
|
432
|
+
nodes = ed.selection.getNode();
|
433
|
+
}
|
434
|
+
|
435
|
+
ed.dom.setAttrib(nodes, 'style', tinyMCEPopup.editor.dom.serializeStyle(newStyles));
|
436
|
+
}
|
376
437
|
}
|
377
438
|
|
378
439
|
function updateAction() {
|
@@ -632,4 +693,17 @@ function synch(fr, to) {
|
|
632
693
|
selectByValue(f, to + "_measurement", f.elements[fr + "_measurement"].value);
|
633
694
|
}
|
634
695
|
|
696
|
+
function updateTextDecorations(){
|
697
|
+
var el = document.forms[0].elements;
|
698
|
+
|
699
|
+
var textDecorations = ["text_underline", "text_overline", "text_linethrough", "text_blink"];
|
700
|
+
var noneChecked = el["text_none"].checked;
|
701
|
+
tinymce.each(textDecorations, function(id) {
|
702
|
+
el[id].disabled = noneChecked;
|
703
|
+
if (noneChecked) {
|
704
|
+
el[id].checked = false;
|
705
|
+
}
|
706
|
+
});
|
707
|
+
}
|
708
|
+
|
635
709
|
tinyMCEPopup.onInit.add(init);
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
@@ -0,0 +1 @@
|
|
1
|
+
tinyMCE.addI18n('nb.style_dlg',{"text_lineheight":"Linjeh\u00f8yde","text_variant":"Variant","text_style":"Skriftstil","text_weight":"Skriftvekt","text_size":"Skriftst\u00f8rrelse","text_font":"Skrifttype","text_props":"Skriftegenskaper","positioning_tab":"Posisjon","list_tab":"Liste","border_tab":"Ramme","box_tab":"Boks","block_tab":"Blokk","background_tab":"Bakgrunn","text_tab":"Tekst",apply:"Legg til",title:"Rediger CSS-stil",clip:"Klipp",placement:"Plassering",overflow:"Overfyll",zindex:"Z-indeks",visibility:"Synlighet","positioning_type":"Type",position:"Posisjon","bullet_image":"Punktbilde","list_type":"Type",color:"Farge",height:"H\u00f8yde",width:"Bredde",style:"Stil",margin:"Marg",left:"Venstre",bottom:"Bunn",right:"H\u00f8yre",top:"Topp",same:"Lik i alle",padding:"Utfylling","box_clear":"Slett","box_float":"Flyt","box_height":"H\u00f8yde","box_width":"Bredde","block_display":"Framvising","block_whitespace":"Mellomrom","block_text_indent":"Innrykk","block_text_align":"Justering","block_vertical_alignment":"Vertikal justering","block_letterspacing":"Bokstavmellomrom","block_wordspacing":"Ordmellomrom","background_vpos":"Vertikal posisjon","background_hpos":"Horisontal posisjon","background_attachment":"Vedlegg","background_repeat":"Gjenta","background_image":"Bakgrunnsbilde","background_color":"Bakgrunnsfarge","text_none":"Ingen","text_blink":"Blink","text_case":"Store / sm\u00e5 bokstaver","text_striketrough":"Gjennomstreking","text_underline":"Senke skrift","text_overline":"Heve skrift","text_decoration":"Dekorasjon","text_color":"Farge",text:"Tekst",background:"Bakgrunn",block:"Blokk",box:"Boks",border:"Ramme",list:"Liste"});
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
@@ -118,7 +118,7 @@
|
|
118
118
|
<td><label for="text_blink">{#style_dlg.text_blink}</label></td>
|
119
119
|
</tr>
|
120
120
|
<tr>
|
121
|
-
<td><input id="text_none" name="text_none" class="checkbox" type="checkbox" /></td>
|
121
|
+
<td><input id="text_none" name="text_none" class="checkbox" type="checkbox" onclick="updateTextDecorations();"/></td>
|
122
122
|
<td><label for="text_none">{#style_dlg.text_none}</label></td>
|
123
123
|
</tr>
|
124
124
|
</table>
|
@@ -825,6 +825,11 @@
|
|
825
825
|
</div>
|
826
826
|
</div>
|
827
827
|
|
828
|
+
<div class="panel_toggle_insert_span">
|
829
|
+
<input type="checkbox" class="checkbox" id="toggle_insert_span" name="toggle_insert_span" onClick="toggleApplyAction();" />
|
830
|
+
<label for="toggle_insert_span">{#style_dlg.toggle_insert_span}</label>
|
831
|
+
</div>
|
832
|
+
|
828
833
|
<div class="mceActionPanel">
|
829
834
|
<input type="submit" id="insert" name="insert" value="{#update}" />
|
830
835
|
<input type="button" class="button" id="apply" name="apply" value="{#style_dlg.apply}" onClick="applyAction();" />
|
@@ -0,0 +1,19 @@
|
|
1
|
+
Edit CSS Style plug-in notes
|
2
|
+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
3
|
+
Unlike WYSIWYG editor functionality that operates only on the selected text,
|
4
|
+
typically by inserting new HTML elements with the specified styles.
|
5
|
+
This plug-in operates on the HTML blocks surrounding the selected text.
|
6
|
+
No new HTML elements are created.
|
7
|
+
|
8
|
+
This plug-in only operates on the surrounding blocks and not the nearest
|
9
|
+
parent node. This means that if a block encapsulates a node,
|
10
|
+
e.g <p><span>text</span></p>, then only the styles in the block are
|
11
|
+
recognized, not those in the span.
|
12
|
+
|
13
|
+
When selecting text that includes multiple blocks at the same level (peers),
|
14
|
+
this plug-in accumulates the specified styles in all of the surrounding blocks
|
15
|
+
and populates the dialogue checkboxes accordingly. There is no differentiation
|
16
|
+
between styles set in all the blocks versus styles set in some of the blocks.
|
17
|
+
|
18
|
+
When the [Update] or [Apply] buttons are pressed, the styles selected in the
|
19
|
+
checkboxes are applied to all blocks that surround the selected text.
|
@@ -1 +1 @@
|
|
1
|
-
(function(){var c=tinymce.DOM,a=tinymce.dom.Event,d=tinymce.each,b=tinymce.explode;tinymce.create("tinymce.plugins.TabFocusPlugin",{init:function(f,g){function e(i,j){if(j.keyCode===9){return a.cancel(j)}}function h(l,p){var j,m,o,n,k;function q(t){n=c.select(":input:enabled,*[tabindex]");function s(v){return v.nodeName==="BODY"||(v.type!="hidden"&&!(v.style.display=="none")&&!(v.style.visibility=="hidden")&&s(v.parentNode))}function i(v){return v.attributes.tabIndex.specified||v.nodeName=="INPUT"||v.nodeName=="TEXTAREA"}function u(){return tinymce.isIE6||tinymce.isIE7}function r(v){return((!u()||i(v)))&&v.getAttribute("tabindex")!="-1"&&s(v)}d(n,function(w,v){if(w.id==l.id){j=v;return false}});if(t>0){for(m=j+1;m<n.length;m++){if(r(n[m])){return n[m]}}}else{for(m=j-1;m>=0;m--){if(r(n[m])){return n[m]}}}return null}if(p.keyCode===9){k=b(l.getParam("tab_focus",l.getParam("tabfocus_elements",":prev,:next")));if(k.length==1){k[1]=k[0];k[0]=":prev"}if(p.shiftKey){if(k[0]==":prev"){n=q(-1)}else{n=c.get(k[0])}}else{if(k[1]==":next"){n=q(1)}else{n=c.get(k[1])}}if(n){if(n.id&&(l=tinymce.get(n.id||n.name))){l.focus()}else{window.setTimeout(function(){if(!tinymce.isWebKit){window.focus()}n.focus()},10)}return a.cancel(p)}}}f.onKeyUp.add(e);if(tinymce.isGecko){f.onKeyPress.add(h);f.onKeyDown.add(e)}else{f.onKeyDown.add(h)}},getInfo:function(){return{longname:"Tabfocus",author:"Moxiecode Systems AB",authorurl:"http://tinymce.moxiecode.com",infourl:"http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/tabfocus",version:tinymce.majorVersion+"."+tinymce.minorVersion}}});tinymce.PluginManager.add("tabfocus",tinymce.plugins.TabFocusPlugin)})();
|
1
|
+
(function(){var c=tinymce.DOM,a=tinymce.dom.Event,d=tinymce.each,b=tinymce.explode;tinymce.create("tinymce.plugins.TabFocusPlugin",{init:function(f,g){function e(i,j){if(j.keyCode===9){return a.cancel(j)}}function h(l,p){var j,m,o,n,k;function q(t){n=c.select(":input:enabled,*[tabindex]:not(iframe)");function s(v){return v.nodeName==="BODY"||(v.type!="hidden"&&!(v.style.display=="none")&&!(v.style.visibility=="hidden")&&s(v.parentNode))}function i(v){return v.attributes.tabIndex.specified||v.nodeName=="INPUT"||v.nodeName=="TEXTAREA"}function u(){return tinymce.isIE6||tinymce.isIE7}function r(v){return((!u()||i(v)))&&v.getAttribute("tabindex")!="-1"&&s(v)}d(n,function(w,v){if(w.id==l.id){j=v;return false}});if(t>0){for(m=j+1;m<n.length;m++){if(r(n[m])){return n[m]}}}else{for(m=j-1;m>=0;m--){if(r(n[m])){return n[m]}}}return null}if(p.keyCode===9){k=b(l.getParam("tab_focus",l.getParam("tabfocus_elements",":prev,:next")));if(k.length==1){k[1]=k[0];k[0]=":prev"}if(p.shiftKey){if(k[0]==":prev"){n=q(-1)}else{n=c.get(k[0])}}else{if(k[1]==":next"){n=q(1)}else{n=c.get(k[1])}}if(n){if(n.id&&(l=tinymce.get(n.id||n.name))){l.focus()}else{window.setTimeout(function(){if(!tinymce.isWebKit){window.focus()}n.focus()},10)}return a.cancel(p)}}}f.onKeyUp.add(e);if(tinymce.isGecko){f.onKeyPress.add(h);f.onKeyDown.add(e)}else{f.onKeyDown.add(h)}},getInfo:function(){return{longname:"Tabfocus",author:"Moxiecode Systems AB",authorurl:"http://tinymce.moxiecode.com",infourl:"http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/tabfocus",version:tinymce.majorVersion+"."+tinymce.minorVersion}}});tinymce.PluginManager.add("tabfocus",tinymce.plugins.TabFocusPlugin)})();
|
@@ -1 +1 @@
|
|
1
|
-
(function(d){var e=d.each;function c(g,h){var j=h.ownerDocument,f=j.createRange(),k;f.setStartBefore(h);f.setEnd(g.endContainer,g.endOffset);k=j.createElement("body");k.appendChild(f.cloneContents());return k.innerHTML.replace(/<(br|img|object|embed|input|textarea)[^>]*>/gi,"-").replace(/<[^>]+>/g,"").length==0}function a(g,f){return parseInt(g.getAttribute(f)||1)}function b(H,G,K){var g,L,D,o;t();o=G.getParent(K.getStart(),"th,td");if(o){L=F(o);D=I();o=z(L.x,L.y)}function A(N,M){N=N.cloneNode(M);N.removeAttribute("id");return N}function t(){var M=0;g=[];e(["thead","tbody","tfoot"],function(N){var O=G.select("> "+N+" tr",H);e(O,function(P,Q){Q+=M;e(G.select("> td, > th",P),function(W,R){var S,T,U,V;if(g[Q]){while(g[Q][R]){R++}}U=a(W,"rowspan");V=a(W,"colspan");for(T=Q;T<Q+U;T++){if(!g[T]){g[T]=[]}for(S=R;S<R+V;S++){g[T][S]={part:N,real:T==Q&&S==R,elm:W,rowspan:U,colspan:V}}}})});M+=O.length})}function z(M,O){var N;N=g[O];if(N){return N[M]}}function s(O,M,N){if(O){N=parseInt(N);if(N===1){O.removeAttribute(M,1)}else{O.setAttribute(M,N,1)}}}function j(M){return M&&(G.hasClass(M.elm,"mceSelected")||M==o)}function k(){var M=[];e(H.rows,function(N){e(N.cells,function(O){if(G.hasClass(O,"mceSelected")||O==o.elm){M.push(N);return false}})});return M}function r(){var M=G.createRng();M.setStartAfter(H);M.setEndAfter(H);K.setRng(M);G.remove(H)}function f(M){var N;d.walk(M,function(P){var O;if(P.nodeType==3){e(G.getParents(P.parentNode,null,M).reverse(),function(Q){Q=A(Q,false);if(!N){N=O=Q}else{if(O){O.appendChild(Q)}}O=Q});if(O){O.innerHTML=d.isIE?" ":'<br data-mce-bogus="1" />'}return false}},"childNodes");M=A(M,false);s(M,"rowSpan",1);s(M,"colSpan",1);if(N){M.appendChild(N)}else{if(!d.isIE){M.innerHTML='<br data-mce-bogus="1" />'}}return M}function q(){var M=G.createRng();e(G.select("tr",H),function(N){if(N.cells.length==0){G.remove(N)}});if(G.select("tr",H).length==0){M.setStartAfter(H);M.setEndAfter(H);K.setRng(M);G.remove(H);return}e(G.select("thead,tbody,tfoot",H),function(N){if(N.rows.length==0){G.remove(N)}});t();row=g[Math.min(g.length-1,L.y)];if(row){K.select(row[Math.min(row.length-1,L.x)].elm,true);K.collapse(true)}}function u(S,Q,U,R){var P,N,M,O,T;P=g[Q][S].elm.parentNode;for(M=1;M<=U;M++){P=G.getNext(P,"tr");if(P){for(N=S;N>=0;N--){T=g[Q+M][N].elm;if(T.parentNode==P){for(O=1;O<=R;O++){G.insertAfter(f(T),T)}break}}if(N==-1){for(O=1;O<=R;O++){P.insertBefore(f(P.cells[0]),P.cells[0])}}}}}function C(){e(g,function(M,N){e(M,function(P,O){var S,R,T,Q;if(j(P)){P=P.elm;S=a(P,"colspan");R=a(P,"rowspan");if(S>1||R>1){s(P,"rowSpan",1);s(P,"colSpan",1);for(Q=0;Q<S-1;Q++){G.insertAfter(f(P),P)}u(O,N,R-1,S)}}})})}function p(V,S,Y){var P,O,X,W,U,R,T,M,V,N,Q;if(V){pos=F(V);P=pos.x;O=pos.y;X=P+(S-1);W=O+(Y-1)}else{P=L.x;O=L.y;X=D.x;W=D.y}T=z(P,O);M=z(X,W);if(T&&M&&T.part==M.part){C();t();T=z(P,O).elm;s(T,"colSpan",(X-P)+1);s(T,"rowSpan",(W-O)+1);for(R=O;R<=W;R++){for(U=P;U<=X;U++){if(!g[R]||!g[R][U]){continue}V=g[R][U].elm;if(V!=T){N=d.grep(V.childNodes);e(N,function(Z){T.appendChild(Z)});if(N.length){N=d.grep(T.childNodes);Q=0;e(N,function(Z){if(Z.nodeName=="BR"&&G.getAttrib(Z,"data-mce-bogus")&&Q++<N.length-1){T.removeChild(Z)}})}G.remove(V)}}}q()}}function l(Q){var M,S,P,R,T,U,N,V,O;e(g,function(W,X){e(W,function(Z,Y){if(j(Z)){Z=Z.elm;T=Z.parentNode;U=A(T,false);M=X;if(Q){return false}}});if(Q){return !M}});for(R=0;R<g[0].length;R++){if(!g[M][R]){continue}S=g[M][R].elm;if(S!=P){if(!Q){O=a(S,"rowspan");if(O>1){s(S,"rowSpan",O+1);continue}}else{if(M>0&&g[M-1][R]){V=g[M-1][R].elm;O=a(V,"rowSpan");if(O>1){s(V,"rowSpan",O+1);continue}}}N=f(S);s(N,"colSpan",S.colSpan);U.appendChild(N);P=S}}if(U.hasChildNodes()){if(!Q){G.insertAfter(U,T)}else{T.parentNode.insertBefore(U,T)}}}function h(N){var O,M;e(g,function(P,Q){e(P,function(S,R){if(j(S)){O=R;if(N){return false}}});if(N){return !O}});e(g,function(S,T){var P,Q,R;if(!S[O]){return}P=S[O].elm;if(P!=M){R=a(P,"colspan");Q=a(P,"rowspan");if(R==1){if(!N){G.insertAfter(f(P),P);u(O,T,Q-1,R)}else{P.parentNode.insertBefore(f(P),P);u(O,T,Q-1,R)}}else{s(P,"colSpan",P.colSpan+1)}M=P}})}function n(){var M=[];e(g,function(N,O){e(N,function(Q,P){if(j(Q)&&d.inArray(M,P)===-1){e(g,function(T){var R=T[P].elm,S;S=a(R,"colSpan");if(S>1){s(R,"colSpan",S-1)}else{G.remove(R)}});M.push(P)}})});q()}function m(){var N;function M(Q){var P,R,O;P=G.getNext(Q,"tr");e(Q.cells,function(S){var T=a(S,"rowSpan");if(T>1){s(S,"rowSpan",T-1);R=F(S);u(R.x,R.y,1,1)}});R=F(Q.cells[0]);e(g[R.y],function(S){var T;S=S.elm;if(S!=O){T=a(S,"rowSpan");if(T<=1){G.remove(S)}else{s(S,"rowSpan",T-1)}O=S}})}N=k();e(N.reverse(),function(O){M(O)});q()}function E(){var M=k();G.remove(M);q();return M}function J(){var M=k();e(M,function(O,N){M[N]=A(O,true)});return M}function B(O,N){var P=k(),M=P[N?0:P.length-1],Q=M.cells.length;e(g,function(S){var R;Q=0;e(S,function(U,T){if(U.real){Q+=U.colspan}if(U.elm.parentNode==M){R=1}});if(R){return false}});if(!N){O.reverse()}e(O,function(T){var S=T.cells.length,R;for(i=0;i<S;i++){R=T.cells[i];s(R,"colSpan",1);s(R,"rowSpan",1)}for(i=S;i<Q;i++){T.appendChild(f(T.cells[S-1]))}for(i=Q;i<S;i++){G.remove(T.cells[i])}if(N){M.parentNode.insertBefore(T,M)}else{G.insertAfter(T,M)}})}function F(M){var N;e(g,function(O,P){e(O,function(R,Q){if(R.elm==M){N={x:Q,y:P};return false}});return !N});return N}function w(M){L=F(M)}function I(){var O,N,M;N=M=0;e(g,function(P,Q){e(P,function(S,R){var U,T;if(j(S)){S=g[Q][R];if(R>N){N=R}if(Q>M){M=Q}if(S.real){U=S.colspan-1;T=S.rowspan-1;if(U){if(R+U>N){N=R+U}}if(T){if(Q+T>M){M=Q+T}}}}})});return{x:N,y:M}}function v(S){var P,O,U,T,N,M,Q,R;D=F(S);if(L&&D){P=Math.min(L.x,D.x);O=Math.min(L.y,D.y);U=Math.max(L.x,D.x);T=Math.max(L.y,D.y);N=U;M=T;for(y=O;y<=M;y++){S=g[y][P];if(!S.real){if(P-(S.colspan-1)<P){P-=S.colspan-1}}}for(x=P;x<=N;x++){S=g[O][x];if(!S.real){if(O-(S.rowspan-1)<O){O-=S.rowspan-1}}}for(y=O;y<=T;y++){for(x=P;x<=U;x++){S=g[y][x];if(S.real){Q=S.colspan-1;R=S.rowspan-1;if(Q){if(x+Q>N){N=x+Q}}if(R){if(y+R>M){M=y+R}}}}}G.removeClass(G.select("td.mceSelected,th.mceSelected"),"mceSelected");for(y=O;y<=M;y++){for(x=P;x<=N;x++){if(g[y][x]){G.addClass(g[y][x].elm,"mceSelected")}}}}}d.extend(this,{deleteTable:r,split:C,merge:p,insertRow:l,insertCol:h,deleteCols:n,deleteRows:m,cutRows:E,copyRows:J,pasteRows:B,getPos:F,setStartCell:w,setEndCell:v})}d.create("tinymce.plugins.TablePlugin",{init:function(g,h){var f,m,j=true;function l(p){var o=g.selection,n=g.dom.getParent(p||o.getNode(),"table");if(n){return new b(n,g.dom,o)}}function k(){g.getBody().style.webkitUserSelect="";if(j){g.dom.removeClass(g.dom.select("td.mceSelected,th.mceSelected"),"mceSelected");j=false}}e([["table","table.desc","mceInsertTable",true],["delete_table","table.del","mceTableDelete"],["delete_col","table.delete_col_desc","mceTableDeleteCol"],["delete_row","table.delete_row_desc","mceTableDeleteRow"],["col_after","table.col_after_desc","mceTableInsertColAfter"],["col_before","table.col_before_desc","mceTableInsertColBefore"],["row_after","table.row_after_desc","mceTableInsertRowAfter"],["row_before","table.row_before_desc","mceTableInsertRowBefore"],["row_props","table.row_desc","mceTableRowProps",true],["cell_props","table.cell_desc","mceTableCellProps",true],["split_cells","table.split_cells_desc","mceTableSplitCells",true],["merge_cells","table.merge_cells_desc","mceTableMergeCells",true]],function(n){g.addButton(n[0],{title:n[1],cmd:n[2],ui:n[3]})});if(!d.isIE){g.onClick.add(function(n,o){o=o.target;if(o.nodeName==="TABLE"){n.selection.select(o);n.nodeChanged()}})}g.onPreProcess.add(function(o,p){var n,q,r,t=o.dom,s;n=t.select("table",p.node);q=n.length;while(q--){r=n[q];t.setAttrib(r,"data-mce-style","");if((s=t.getAttrib(r,"width"))){t.setStyle(r,"width",s);t.setAttrib(r,"width","")}if((s=t.getAttrib(r,"height"))){t.setStyle(r,"height",s);t.setAttrib(r,"height","")}}});g.onNodeChange.add(function(q,o,s){var r;s=q.selection.getStart();r=q.dom.getParent(s,"td,th,caption");o.setActive("table",s.nodeName==="TABLE"||!!r);if(r&&r.nodeName==="CAPTION"){r=0}o.setDisabled("delete_table",!r);o.setDisabled("delete_col",!r);o.setDisabled("delete_table",!r);o.setDisabled("delete_row",!r);o.setDisabled("col_after",!r);o.setDisabled("col_before",!r);o.setDisabled("row_after",!r);o.setDisabled("row_before",!r);o.setDisabled("row_props",!r);o.setDisabled("cell_props",!r);o.setDisabled("split_cells",!r);o.setDisabled("merge_cells",!r)});g.onInit.add(function(r){var p,t,q=r.dom,u;f=r.windowManager;r.onMouseDown.add(function(w,z){if(z.button!=2){k();t=q.getParent(z.target,"td,th");p=q.getParent(t,"table")}});q.bind(r.getDoc(),"mouseover",function(C){var A,z,B=C.target;if(t&&(u||B!=t)&&(B.nodeName=="TD"||B.nodeName=="TH")){z=q.getParent(B,"table");if(z==p){if(!u){u=l(z);u.setStartCell(t);r.getBody().style.webkitUserSelect="none"}u.setEndCell(B);j=true}A=r.selection.getSel();try{if(A.removeAllRanges){A.removeAllRanges()}else{A.empty()}}catch(w){}C.preventDefault()}});r.onMouseUp.add(function(F,G){var z,B=F.selection,H,I=B.getSel(),w,C,A,E;if(t){if(u){F.getBody().style.webkitUserSelect=""}function D(J,L){var K=new d.dom.TreeWalker(J,J);do{if(J.nodeType==3&&d.trim(J.nodeValue).length!=0){if(L){z.setStart(J,0)}else{z.setEnd(J,J.nodeValue.length)}return}if(J.nodeName=="BR"){if(L){z.setStartBefore(J)}else{z.setEndBefore(J)}return}}while(J=(L?K.next():K.prev()))}H=q.select("td.mceSelected,th.mceSelected");if(H.length>0){z=q.createRng();C=H[0];E=H[H.length-1];z.setStartBefore(C);z.setEndAfter(C);D(C,1);w=new d.dom.TreeWalker(C,q.getParent(H[0],"table"));do{if(C.nodeName=="TD"||C.nodeName=="TH"){if(!q.hasClass(C,"mceSelected")){break}A=C}}while(C=w.next());D(A);B.setRng(z)}F.nodeChanged();t=u=p=null}});r.onKeyUp.add(function(w,z){k()});r.onKeyDown.add(function(w,z){n(w)});r.onMouseDown.add(function(w,z){if(z.button!=2){n(w)}});function o(D,z,A,F){var B=3,G=D.dom.getParent(z.startContainer,"TABLE"),C,w,E;if(G){C=G.parentNode}w=z.startContainer.nodeType==B&&z.startOffset==0&&z.endOffset==0&&F&&(A.nodeName=="TR"||A==C);E=(A.nodeName=="TD"||A.nodeName=="TH")&&!F;return w||E}function n(A){if(!d.isWebKit){return}var z=A.selection.getRng();var C=A.selection.getNode();var B=A.dom.getParent(z.startContainer,"TD,TH");if(!o(A,z,C,B)){return}if(!B){B=C}var w=B.lastChild;while(w.lastChild){w=w.lastChild}z.setEnd(w,w.nodeValue.length);A.selection.setRng(z)}r.plugins.table.fixTableCellSelection=n;if(r&&r.plugins.contextmenu){r.plugins.contextmenu.onContextMenu.add(function(A,w,C){var D,B=r.selection,z=B.getNode()||r.getBody();if(r.dom.getParent(C,"td")||r.dom.getParent(C,"th")||r.dom.select("td.mceSelected,th.mceSelected").length){w.removeAll();if(z.nodeName=="A"&&!r.dom.getAttrib(z,"name")){w.add({title:"advanced.link_desc",icon:"link",cmd:r.plugins.advlink?"mceAdvLink":"mceLink",ui:true});w.add({title:"advanced.unlink_desc",icon:"unlink",cmd:"UnLink"});w.addSeparator()}if(z.nodeName=="IMG"&&z.className.indexOf("mceItem")==-1){w.add({title:"advanced.image_desc",icon:"image",cmd:r.plugins.advimage?"mceAdvImage":"mceImage",ui:true});w.addSeparator()}w.add({title:"table.desc",icon:"table",cmd:"mceInsertTable",value:{action:"insert"}});w.add({title:"table.props_desc",icon:"table_props",cmd:"mceInsertTable"});w.add({title:"table.del",icon:"delete_table",cmd:"mceTableDelete"});w.addSeparator();D=w.addMenu({title:"table.cell"});D.add({title:"table.cell_desc",icon:"cell_props",cmd:"mceTableCellProps"});D.add({title:"table.split_cells_desc",icon:"split_cells",cmd:"mceTableSplitCells"});D.add({title:"table.merge_cells_desc",icon:"merge_cells",cmd:"mceTableMergeCells"});D=w.addMenu({title:"table.row"});D.add({title:"table.row_desc",icon:"row_props",cmd:"mceTableRowProps"});D.add({title:"table.row_before_desc",icon:"row_before",cmd:"mceTableInsertRowBefore"});D.add({title:"table.row_after_desc",icon:"row_after",cmd:"mceTableInsertRowAfter"});D.add({title:"table.delete_row_desc",icon:"delete_row",cmd:"mceTableDeleteRow"});D.addSeparator();D.add({title:"table.cut_row_desc",icon:"cut",cmd:"mceTableCutRow"});D.add({title:"table.copy_row_desc",icon:"copy",cmd:"mceTableCopyRow"});D.add({title:"table.paste_row_before_desc",icon:"paste",cmd:"mceTablePasteRowBefore"}).setDisabled(!m);D.add({title:"table.paste_row_after_desc",icon:"paste",cmd:"mceTablePasteRowAfter"}).setDisabled(!m);D=w.addMenu({title:"table.col"});D.add({title:"table.col_before_desc",icon:"col_before",cmd:"mceTableInsertColBefore"});D.add({title:"table.col_after_desc",icon:"col_after",cmd:"mceTableInsertColAfter"});D.add({title:"table.delete_col_desc",icon:"delete_col",cmd:"mceTableDeleteCol"})}else{w.add({title:"table.desc",icon:"table",cmd:"mceInsertTable"})}})}if(d.isWebKit){function v(C,N){var L=d.VK;var Q=N.keyCode;function O(Y,U,S){var T=Y?"previousSibling":"nextSibling";var Z=C.dom.getParent(U,"tr");var X=Z[T];if(X){z(C,U,X,Y);d.dom.Event.cancel(S);return true}else{var aa=C.dom.getParent(Z,"table");var W=Z.parentNode;var R=W.nodeName.toLowerCase();if(R==="tbody"||R===(Y?"tfoot":"thead")){var V=w(Y,aa,W,"tbody");if(V!==null){return K(Y,V,U,S)}}return M(Y,Z,T,aa,S)}}function w(V,T,U,X){var S=C.dom.select(">"+X,T);var R=S.indexOf(U);if(V&&R===0||!V&&R===S.length-1){return B(V,T)}else{if(R===-1){var W=U.tagName.toLowerCase()==="thead"?0:S.length-1;return S[W]}else{return S[R+(V?-1:1)]}}}function B(U,T){var S=U?"thead":"tfoot";var R=C.dom.select(">"+S,T);return R.length!==0?R[0]:null}function K(V,T,S,U){var R=J(T,V);R&&z(C,S,R,V);d.dom.Event.cancel(U);return true}function M(Y,U,R,X,W){var S=X[R];if(S){F(S);return true}else{var V=C.dom.getParent(X,"td,th");if(V){return O(Y,V,W)}else{var T=J(U,!Y);F(T);return d.dom.Event.cancel(W)}}}function J(S,R){return S&&S[R?"lastChild":"firstChild"]}function F(R){C.selection.setCursorLocation(R,0)}function A(){return Q==L.UP||Q==L.DOWN}function D(R){var T=R.selection.getNode();var S=R.dom.getParent(T,"tr");return S!==null}function P(S){var R=0;var T=S;while(T.previousSibling){T=T.previousSibling;R=R+a(T,"colspan")}return R}function E(T,R){var U=0;var S=0;e(T.children,function(V,W){U=U+a(V,"colspan");S=W;if(U>R){return false}});return S}function z(T,W,Y,V){var X=P(T.dom.getParent(W,"td,th"));var S=E(Y,X);var R=Y.childNodes[S];var U=J(R,V);F(U||R)}function H(R){var T=C.selection.getNode();var U=C.dom.getParent(T,"td,th");var S=C.dom.getParent(R,"td,th");return U&&U!==S&&I(U,S)}function I(S,R){return C.dom.getParent(S,"TABLE")===C.dom.getParent(R,"TABLE")}if(A()&&D(C)){var G=C.selection.getNode();setTimeout(function(){if(H(G)){O(!N.shiftKey&&Q===L.UP,G,N)}},0)}}r.onKeyDown.add(v)}if(!d.isIE){function s(){var w;for(w=r.getBody().lastChild;w&&w.nodeType==3&&!w.nodeValue.length;w=w.previousSibling){}if(w&&w.nodeName=="TABLE"){r.dom.add(r.getBody(),"p",null,'<br mce_bogus="1" />')}}if(d.isGecko){r.onKeyDown.add(function(z,B){var w,A,C=z.dom;if(B.keyCode==37||B.keyCode==38){w=z.selection.getRng();A=C.getParent(w.startContainer,"table");if(A&&z.getBody().firstChild==A){if(c(w,A)){w=C.createRng();w.setStartBefore(A);w.setEndBefore(A);z.selection.setRng(w);B.preventDefault()}}}})}r.onKeyUp.add(s);r.onSetContent.add(s);r.onVisualAid.add(s);r.onPreProcess.add(function(w,A){var z=A.node.lastChild;if(z&&z.childNodes.length==1&&z.firstChild.nodeName=="BR"){w.dom.remove(z)}});s();r.startContent=r.getContent({format:"raw"})}});e({mceTableSplitCells:function(n){n.split()},mceTableMergeCells:function(o){var p,q,n;n=g.dom.getParent(g.selection.getNode(),"th,td");if(n){p=n.rowSpan;q=n.colSpan}if(!g.dom.select("td.mceSelected,th.mceSelected").length){f.open({url:h+"/merge_cells.htm",width:240+parseInt(g.getLang("table.merge_cells_delta_width",0)),height:110+parseInt(g.getLang("table.merge_cells_delta_height",0)),inline:1},{rows:p,cols:q,onaction:function(r){o.merge(n,r.cols,r.rows)},plugin_url:h})}else{o.merge()}},mceTableInsertRowBefore:function(n){n.insertRow(true)},mceTableInsertRowAfter:function(n){n.insertRow()},mceTableInsertColBefore:function(n){n.insertCol(true)},mceTableInsertColAfter:function(n){n.insertCol()},mceTableDeleteCol:function(n){n.deleteCols()},mceTableDeleteRow:function(n){n.deleteRows()},mceTableCutRow:function(n){m=n.cutRows()},mceTableCopyRow:function(n){m=n.copyRows()},mceTablePasteRowBefore:function(n){n.pasteRows(m,true)},mceTablePasteRowAfter:function(n){n.pasteRows(m)},mceTableDelete:function(n){n.deleteTable()}},function(o,n){g.addCommand(n,function(){var p=l();if(p){o(p);g.execCommand("mceRepaint");k()}})});e({mceInsertTable:function(n){f.open({url:h+"/table.htm",width:400+parseInt(g.getLang("table.table_delta_width",0)),height:320+parseInt(g.getLang("table.table_delta_height",0)),inline:1},{plugin_url:h,action:n?n.action:0})},mceTableRowProps:function(){f.open({url:h+"/row.htm",width:400+parseInt(g.getLang("table.rowprops_delta_width",0)),height:295+parseInt(g.getLang("table.rowprops_delta_height",0)),inline:1},{plugin_url:h})},mceTableCellProps:function(){f.open({url:h+"/cell.htm",width:400+parseInt(g.getLang("table.cellprops_delta_width",0)),height:295+parseInt(g.getLang("table.cellprops_delta_height",0)),inline:1},{plugin_url:h})}},function(o,n){g.addCommand(n,function(p,q){o(q)})})}});d.PluginManager.add("table",d.plugins.TablePlugin)})(tinymce);
|
1
|
+
(function(d){var e=d.each;function c(g,h){var j=h.ownerDocument,f=j.createRange(),k;f.setStartBefore(h);f.setEnd(g.endContainer,g.endOffset);k=j.createElement("body");k.appendChild(f.cloneContents());return k.innerHTML.replace(/<(br|img|object|embed|input|textarea)[^>]*>/gi,"-").replace(/<[^>]+>/g,"").length==0}function a(g,f){return parseInt(g.getAttribute(f)||1)}function b(H,G,K){var g,L,D,o;t();o=G.getParent(K.getStart(),"th,td");if(o){L=F(o);D=I();o=z(L.x,L.y)}function A(N,M){N=N.cloneNode(M);N.removeAttribute("id");return N}function t(){var M=0;g=[];e(["thead","tbody","tfoot"],function(N){var O=G.select("> "+N+" tr",H);e(O,function(P,Q){Q+=M;e(G.select("> td, > th",P),function(W,R){var S,T,U,V;if(g[Q]){while(g[Q][R]){R++}}U=a(W,"rowspan");V=a(W,"colspan");for(T=Q;T<Q+U;T++){if(!g[T]){g[T]=[]}for(S=R;S<R+V;S++){g[T][S]={part:N,real:T==Q&&S==R,elm:W,rowspan:U,colspan:V}}}})});M+=O.length})}function z(M,O){var N;N=g[O];if(N){return N[M]}}function s(O,M,N){if(O){N=parseInt(N);if(N===1){O.removeAttribute(M,1)}else{O.setAttribute(M,N,1)}}}function j(M){return M&&(G.hasClass(M.elm,"mceSelected")||M==o)}function k(){var M=[];e(H.rows,function(N){e(N.cells,function(O){if(G.hasClass(O,"mceSelected")||O==o.elm){M.push(N);return false}})});return M}function r(){var M=G.createRng();M.setStartAfter(H);M.setEndAfter(H);K.setRng(M);G.remove(H)}function f(M){var N;d.walk(M,function(P){var O;if(P.nodeType==3){e(G.getParents(P.parentNode,null,M).reverse(),function(Q){Q=A(Q,false);if(!N){N=O=Q}else{if(O){O.appendChild(Q)}}O=Q});if(O){O.innerHTML=d.isIE?" ":'<br data-mce-bogus="1" />'}return false}},"childNodes");M=A(M,false);s(M,"rowSpan",1);s(M,"colSpan",1);if(N){M.appendChild(N)}else{if(!d.isIE){M.innerHTML='<br data-mce-bogus="1" />'}}return M}function q(){var M=G.createRng();e(G.select("tr",H),function(N){if(N.cells.length==0){G.remove(N)}});if(G.select("tr",H).length==0){M.setStartAfter(H);M.setEndAfter(H);K.setRng(M);G.remove(H);return}e(G.select("thead,tbody,tfoot",H),function(N){if(N.rows.length==0){G.remove(N)}});t();row=g[Math.min(g.length-1,L.y)];if(row){K.select(row[Math.min(row.length-1,L.x)].elm,true);K.collapse(true)}}function u(S,Q,U,R){var P,N,M,O,T;P=g[Q][S].elm.parentNode;for(M=1;M<=U;M++){P=G.getNext(P,"tr");if(P){for(N=S;N>=0;N--){T=g[Q+M][N].elm;if(T.parentNode==P){for(O=1;O<=R;O++){G.insertAfter(f(T),T)}break}}if(N==-1){for(O=1;O<=R;O++){P.insertBefore(f(P.cells[0]),P.cells[0])}}}}}function C(){e(g,function(M,N){e(M,function(P,O){var S,R,T,Q;if(j(P)){P=P.elm;S=a(P,"colspan");R=a(P,"rowspan");if(S>1||R>1){s(P,"rowSpan",1);s(P,"colSpan",1);for(Q=0;Q<S-1;Q++){G.insertAfter(f(P),P)}u(O,N,R-1,S)}}})})}function p(V,S,Y){var P,O,X,W,U,R,T,M,V,N,Q;if(V){pos=F(V);P=pos.x;O=pos.y;X=P+(S-1);W=O+(Y-1)}else{L=D=null;e(g,function(Z,aa){e(Z,function(ac,ab){if(j(ac)){if(!L){L={x:ab,y:aa}}D={x:ab,y:aa}}})});P=L.x;O=L.y;X=D.x;W=D.y}T=z(P,O);M=z(X,W);if(T&&M&&T.part==M.part){C();t();T=z(P,O).elm;s(T,"colSpan",(X-P)+1);s(T,"rowSpan",(W-O)+1);for(R=O;R<=W;R++){for(U=P;U<=X;U++){if(!g[R]||!g[R][U]){continue}V=g[R][U].elm;if(V!=T){N=d.grep(V.childNodes);e(N,function(Z){T.appendChild(Z)});if(N.length){N=d.grep(T.childNodes);Q=0;e(N,function(Z){if(Z.nodeName=="BR"&&G.getAttrib(Z,"data-mce-bogus")&&Q++<N.length-1){T.removeChild(Z)}})}G.remove(V)}}}q()}}function l(Q){var M,S,P,R,T,U,N,V,O;e(g,function(W,X){e(W,function(Z,Y){if(j(Z)){Z=Z.elm;T=Z.parentNode;U=A(T,false);M=X;if(Q){return false}}});if(Q){return !M}});for(R=0;R<g[0].length;R++){if(!g[M][R]){continue}S=g[M][R].elm;if(S!=P){if(!Q){O=a(S,"rowspan");if(O>1){s(S,"rowSpan",O+1);continue}}else{if(M>0&&g[M-1][R]){V=g[M-1][R].elm;O=a(V,"rowSpan");if(O>1){s(V,"rowSpan",O+1);continue}}}N=f(S);s(N,"colSpan",S.colSpan);U.appendChild(N);P=S}}if(U.hasChildNodes()){if(!Q){G.insertAfter(U,T)}else{T.parentNode.insertBefore(U,T)}}}function h(N){var O,M;e(g,function(P,Q){e(P,function(S,R){if(j(S)){O=R;if(N){return false}}});if(N){return !O}});e(g,function(S,T){var P,Q,R;if(!S[O]){return}P=S[O].elm;if(P!=M){R=a(P,"colspan");Q=a(P,"rowspan");if(R==1){if(!N){G.insertAfter(f(P),P);u(O,T,Q-1,R)}else{P.parentNode.insertBefore(f(P),P);u(O,T,Q-1,R)}}else{s(P,"colSpan",P.colSpan+1)}M=P}})}function n(){var M=[];e(g,function(N,O){e(N,function(Q,P){if(j(Q)&&d.inArray(M,P)===-1){e(g,function(T){var R=T[P].elm,S;S=a(R,"colSpan");if(S>1){s(R,"colSpan",S-1)}else{G.remove(R)}});M.push(P)}})});q()}function m(){var N;function M(Q){var P,R,O;P=G.getNext(Q,"tr");e(Q.cells,function(S){var T=a(S,"rowSpan");if(T>1){s(S,"rowSpan",T-1);R=F(S);u(R.x,R.y,1,1)}});R=F(Q.cells[0]);e(g[R.y],function(S){var T;S=S.elm;if(S!=O){T=a(S,"rowSpan");if(T<=1){G.remove(S)}else{s(S,"rowSpan",T-1)}O=S}})}N=k();e(N.reverse(),function(O){M(O)});q()}function E(){var M=k();G.remove(M);q();return M}function J(){var M=k();e(M,function(O,N){M[N]=A(O,true)});return M}function B(O,N){if(!O){return}var P=k(),M=P[N?0:P.length-1],Q=M.cells.length;e(g,function(S){var R;Q=0;e(S,function(U,T){if(U.real){Q+=U.colspan}if(U.elm.parentNode==M){R=1}});if(R){return false}});if(!N){O.reverse()}e(O,function(T){var S=T.cells.length,R;for(i=0;i<S;i++){R=T.cells[i];s(R,"colSpan",1);s(R,"rowSpan",1)}for(i=S;i<Q;i++){T.appendChild(f(T.cells[S-1]))}for(i=Q;i<S;i++){G.remove(T.cells[i])}if(N){M.parentNode.insertBefore(T,M)}else{G.insertAfter(T,M)}});G.removeClass(G.select("td.mceSelected,th.mceSelected"),"mceSelected")}function F(M){var N;e(g,function(O,P){e(O,function(R,Q){if(R.elm==M){N={x:Q,y:P};return false}});return !N});return N}function w(M){L=F(M)}function I(){var O,N,M;N=M=0;e(g,function(P,Q){e(P,function(S,R){var U,T;if(j(S)){S=g[Q][R];if(R>N){N=R}if(Q>M){M=Q}if(S.real){U=S.colspan-1;T=S.rowspan-1;if(U){if(R+U>N){N=R+U}}if(T){if(Q+T>M){M=Q+T}}}}})});return{x:N,y:M}}function v(S){var P,O,U,T,N,M,Q,R;D=F(S);if(L&&D){P=Math.min(L.x,D.x);O=Math.min(L.y,D.y);U=Math.max(L.x,D.x);T=Math.max(L.y,D.y);N=U;M=T;for(y=O;y<=M;y++){S=g[y][P];if(!S.real){if(P-(S.colspan-1)<P){P-=S.colspan-1}}}for(x=P;x<=N;x++){S=g[O][x];if(!S.real){if(O-(S.rowspan-1)<O){O-=S.rowspan-1}}}for(y=O;y<=T;y++){for(x=P;x<=U;x++){S=g[y][x];if(S.real){Q=S.colspan-1;R=S.rowspan-1;if(Q){if(x+Q>N){N=x+Q}}if(R){if(y+R>M){M=y+R}}}}}G.removeClass(G.select("td.mceSelected,th.mceSelected"),"mceSelected");for(y=O;y<=M;y++){for(x=P;x<=N;x++){if(g[y][x]){G.addClass(g[y][x].elm,"mceSelected")}}}}}d.extend(this,{deleteTable:r,split:C,merge:p,insertRow:l,insertCol:h,deleteCols:n,deleteRows:m,cutRows:E,copyRows:J,pasteRows:B,getPos:F,setStartCell:w,setEndCell:v})}d.create("tinymce.plugins.TablePlugin",{init:function(g,h){var f,m,j=true;function l(p){var o=g.selection,n=g.dom.getParent(p||o.getNode(),"table");if(n){return new b(n,g.dom,o)}}function k(){g.getBody().style.webkitUserSelect="";if(j){g.dom.removeClass(g.dom.select("td.mceSelected,th.mceSelected"),"mceSelected");j=false}}e([["table","table.desc","mceInsertTable",true],["delete_table","table.del","mceTableDelete"],["delete_col","table.delete_col_desc","mceTableDeleteCol"],["delete_row","table.delete_row_desc","mceTableDeleteRow"],["col_after","table.col_after_desc","mceTableInsertColAfter"],["col_before","table.col_before_desc","mceTableInsertColBefore"],["row_after","table.row_after_desc","mceTableInsertRowAfter"],["row_before","table.row_before_desc","mceTableInsertRowBefore"],["row_props","table.row_desc","mceTableRowProps",true],["cell_props","table.cell_desc","mceTableCellProps",true],["split_cells","table.split_cells_desc","mceTableSplitCells",true],["merge_cells","table.merge_cells_desc","mceTableMergeCells",true]],function(n){g.addButton(n[0],{title:n[1],cmd:n[2],ui:n[3]})});if(!d.isIE){g.onClick.add(function(n,o){o=o.target;if(o.nodeName==="TABLE"){n.selection.select(o);n.nodeChanged()}})}g.onPreProcess.add(function(o,p){var n,q,r,t=o.dom,s;n=t.select("table",p.node);q=n.length;while(q--){r=n[q];t.setAttrib(r,"data-mce-style","");if((s=t.getAttrib(r,"width"))){t.setStyle(r,"width",s);t.setAttrib(r,"width","")}if((s=t.getAttrib(r,"height"))){t.setStyle(r,"height",s);t.setAttrib(r,"height","")}}});g.onNodeChange.add(function(q,o,s){var r;s=q.selection.getStart();r=q.dom.getParent(s,"td,th,caption");o.setActive("table",s.nodeName==="TABLE"||!!r);if(r&&r.nodeName==="CAPTION"){r=0}o.setDisabled("delete_table",!r);o.setDisabled("delete_col",!r);o.setDisabled("delete_table",!r);o.setDisabled("delete_row",!r);o.setDisabled("col_after",!r);o.setDisabled("col_before",!r);o.setDisabled("row_after",!r);o.setDisabled("row_before",!r);o.setDisabled("row_props",!r);o.setDisabled("cell_props",!r);o.setDisabled("split_cells",!r);o.setDisabled("merge_cells",!r)});g.onInit.add(function(r){var p,t,q=r.dom,u;f=r.windowManager;r.onMouseDown.add(function(w,z){if(z.button!=2){k();t=q.getParent(z.target,"td,th");p=q.getParent(t,"table")}});q.bind(r.getDoc(),"mouseover",function(C){var A,z,B=C.target;if(t&&(u||B!=t)&&(B.nodeName=="TD"||B.nodeName=="TH")){z=q.getParent(B,"table");if(z==p){if(!u){u=l(z);u.setStartCell(t);r.getBody().style.webkitUserSelect="none"}u.setEndCell(B);j=true}A=r.selection.getSel();try{if(A.removeAllRanges){A.removeAllRanges()}else{A.empty()}}catch(w){}C.preventDefault()}});r.onMouseUp.add(function(F,G){var z,B=F.selection,H,I=B.getSel(),w,C,A,E;if(t){if(u){F.getBody().style.webkitUserSelect=""}function D(J,L){var K=new d.dom.TreeWalker(J,J);do{if(J.nodeType==3&&d.trim(J.nodeValue).length!=0){if(L){z.setStart(J,0)}else{z.setEnd(J,J.nodeValue.length)}return}if(J.nodeName=="BR"){if(L){z.setStartBefore(J)}else{z.setEndBefore(J)}return}}while(J=(L?K.next():K.prev()))}H=q.select("td.mceSelected,th.mceSelected");if(H.length>0){z=q.createRng();C=H[0];E=H[H.length-1];z.setStartBefore(C);z.setEndAfter(C);D(C,1);w=new d.dom.TreeWalker(C,q.getParent(H[0],"table"));do{if(C.nodeName=="TD"||C.nodeName=="TH"){if(!q.hasClass(C,"mceSelected")){break}A=C}}while(C=w.next());D(A);B.setRng(z)}F.nodeChanged();t=u=p=null}});r.onKeyUp.add(function(w,z){k()});r.onKeyDown.add(function(w,z){n(w)});r.onMouseDown.add(function(w,z){if(z.button!=2){n(w)}});function o(D,z,A,F){var B=3,G=D.dom.getParent(z.startContainer,"TABLE"),C,w,E;if(G){C=G.parentNode}w=z.startContainer.nodeType==B&&z.startOffset==0&&z.endOffset==0&&F&&(A.nodeName=="TR"||A==C);E=(A.nodeName=="TD"||A.nodeName=="TH")&&!F;return w||E}function n(A){if(!d.isWebKit){return}var z=A.selection.getRng();var C=A.selection.getNode();var B=A.dom.getParent(z.startContainer,"TD,TH");if(!o(A,z,C,B)){return}if(!B){B=C}var w=B.lastChild;while(w.lastChild){w=w.lastChild}z.setEnd(w,w.nodeValue.length);A.selection.setRng(z)}r.plugins.table.fixTableCellSelection=n;if(r&&r.plugins.contextmenu){r.plugins.contextmenu.onContextMenu.add(function(A,w,C){var D,B=r.selection,z=B.getNode()||r.getBody();if(r.dom.getParent(C,"td")||r.dom.getParent(C,"th")||r.dom.select("td.mceSelected,th.mceSelected").length){w.removeAll();if(z.nodeName=="A"&&!r.dom.getAttrib(z,"name")){w.add({title:"advanced.link_desc",icon:"link",cmd:r.plugins.advlink?"mceAdvLink":"mceLink",ui:true});w.add({title:"advanced.unlink_desc",icon:"unlink",cmd:"UnLink"});w.addSeparator()}if(z.nodeName=="IMG"&&z.className.indexOf("mceItem")==-1){w.add({title:"advanced.image_desc",icon:"image",cmd:r.plugins.advimage?"mceAdvImage":"mceImage",ui:true});w.addSeparator()}w.add({title:"table.desc",icon:"table",cmd:"mceInsertTable",value:{action:"insert"}});w.add({title:"table.props_desc",icon:"table_props",cmd:"mceInsertTable"});w.add({title:"table.del",icon:"delete_table",cmd:"mceTableDelete"});w.addSeparator();D=w.addMenu({title:"table.cell"});D.add({title:"table.cell_desc",icon:"cell_props",cmd:"mceTableCellProps"});D.add({title:"table.split_cells_desc",icon:"split_cells",cmd:"mceTableSplitCells"});D.add({title:"table.merge_cells_desc",icon:"merge_cells",cmd:"mceTableMergeCells"});D=w.addMenu({title:"table.row"});D.add({title:"table.row_desc",icon:"row_props",cmd:"mceTableRowProps"});D.add({title:"table.row_before_desc",icon:"row_before",cmd:"mceTableInsertRowBefore"});D.add({title:"table.row_after_desc",icon:"row_after",cmd:"mceTableInsertRowAfter"});D.add({title:"table.delete_row_desc",icon:"delete_row",cmd:"mceTableDeleteRow"});D.addSeparator();D.add({title:"table.cut_row_desc",icon:"cut",cmd:"mceTableCutRow"});D.add({title:"table.copy_row_desc",icon:"copy",cmd:"mceTableCopyRow"});D.add({title:"table.paste_row_before_desc",icon:"paste",cmd:"mceTablePasteRowBefore"}).setDisabled(!m);D.add({title:"table.paste_row_after_desc",icon:"paste",cmd:"mceTablePasteRowAfter"}).setDisabled(!m);D=w.addMenu({title:"table.col"});D.add({title:"table.col_before_desc",icon:"col_before",cmd:"mceTableInsertColBefore"});D.add({title:"table.col_after_desc",icon:"col_after",cmd:"mceTableInsertColAfter"});D.add({title:"table.delete_col_desc",icon:"delete_col",cmd:"mceTableDeleteCol"})}else{w.add({title:"table.desc",icon:"table",cmd:"mceInsertTable"})}})}if(d.isWebKit){function v(C,N){var L=d.VK;var Q=N.keyCode;function O(Y,U,S){var T=Y?"previousSibling":"nextSibling";var Z=C.dom.getParent(U,"tr");var X=Z[T];if(X){z(C,U,X,Y);d.dom.Event.cancel(S);return true}else{var aa=C.dom.getParent(Z,"table");var W=Z.parentNode;var R=W.nodeName.toLowerCase();if(R==="tbody"||R===(Y?"tfoot":"thead")){var V=w(Y,aa,W,"tbody");if(V!==null){return K(Y,V,U,S)}}return M(Y,Z,T,aa,S)}}function w(V,T,U,X){var S=C.dom.select(">"+X,T);var R=S.indexOf(U);if(V&&R===0||!V&&R===S.length-1){return B(V,T)}else{if(R===-1){var W=U.tagName.toLowerCase()==="thead"?0:S.length-1;return S[W]}else{return S[R+(V?-1:1)]}}}function B(U,T){var S=U?"thead":"tfoot";var R=C.dom.select(">"+S,T);return R.length!==0?R[0]:null}function K(V,T,S,U){var R=J(T,V);R&&z(C,S,R,V);d.dom.Event.cancel(U);return true}function M(Y,U,R,X,W){var S=X[R];if(S){F(S);return true}else{var V=C.dom.getParent(X,"td,th");if(V){return O(Y,V,W)}else{var T=J(U,!Y);F(T);return d.dom.Event.cancel(W)}}}function J(S,R){var T=S&&S[R?"lastChild":"firstChild"];return T&&T.nodeName==="BR"?C.dom.getParent(T,"td,th"):T}function F(R){C.selection.setCursorLocation(R,0)}function A(){return Q==L.UP||Q==L.DOWN}function D(R){var T=R.selection.getNode();var S=R.dom.getParent(T,"tr");return S!==null}function P(S){var R=0;var T=S;while(T.previousSibling){T=T.previousSibling;R=R+a(T,"colspan")}return R}function E(T,R){var U=0;var S=0;e(T.children,function(V,W){U=U+a(V,"colspan");S=W;if(U>R){return false}});return S}function z(T,W,Y,V){var X=P(T.dom.getParent(W,"td,th"));var S=E(Y,X);var R=Y.childNodes[S];var U=J(R,V);F(U||R)}function H(R){var T=C.selection.getNode();var U=C.dom.getParent(T,"td,th");var S=C.dom.getParent(R,"td,th");return U&&U!==S&&I(U,S)}function I(S,R){return C.dom.getParent(S,"TABLE")===C.dom.getParent(R,"TABLE")}if(A()&&D(C)){var G=C.selection.getNode();setTimeout(function(){if(H(G)){O(!N.shiftKey&&Q===L.UP,G,N)}},0)}}r.onKeyDown.add(v)}function s(){var w;for(w=r.getBody().lastChild;w&&w.nodeType==3&&!w.nodeValue.length;w=w.previousSibling){}if(w&&w.nodeName=="TABLE"){if(r.settings.forced_root_block){r.dom.add(r.getBody(),r.settings.forced_root_block,null,d.isIE?" ":'<br data-mce-bogus="1" />')}else{r.dom.add(r.getBody(),"br",{"data-mce-bogus":"1"})}}}if(d.isGecko){r.onKeyDown.add(function(z,B){var w,A,C=z.dom;if(B.keyCode==37||B.keyCode==38){w=z.selection.getRng();A=C.getParent(w.startContainer,"table");if(A&&z.getBody().firstChild==A){if(c(w,A)){w=C.createRng();w.setStartBefore(A);w.setEndBefore(A);z.selection.setRng(w);B.preventDefault()}}}})}r.onKeyUp.add(s);r.onSetContent.add(s);r.onVisualAid.add(s);r.onPreProcess.add(function(w,A){var z=A.node.lastChild;if(z&&(z.nodeName=="BR"||(z.childNodes.length==1&&(z.firstChild.nodeName=="BR"||z.firstChild.nodeValue=="\u00a0")))&&z.previousSibling&&z.previousSibling.nodeName=="TABLE"){w.dom.remove(z)}});s();r.startContent=r.getContent({format:"raw"})});e({mceTableSplitCells:function(n){n.split()},mceTableMergeCells:function(o){var p,q,n;n=g.dom.getParent(g.selection.getNode(),"th,td");if(n){p=n.rowSpan;q=n.colSpan}if(!g.dom.select("td.mceSelected,th.mceSelected").length){f.open({url:h+"/merge_cells.htm",width:240+parseInt(g.getLang("table.merge_cells_delta_width",0)),height:110+parseInt(g.getLang("table.merge_cells_delta_height",0)),inline:1},{rows:p,cols:q,onaction:function(r){o.merge(n,r.cols,r.rows)},plugin_url:h})}else{o.merge()}},mceTableInsertRowBefore:function(n){n.insertRow(true)},mceTableInsertRowAfter:function(n){n.insertRow()},mceTableInsertColBefore:function(n){n.insertCol(true)},mceTableInsertColAfter:function(n){n.insertCol()},mceTableDeleteCol:function(n){n.deleteCols()},mceTableDeleteRow:function(n){n.deleteRows()},mceTableCutRow:function(n){m=n.cutRows()},mceTableCopyRow:function(n){m=n.copyRows()},mceTablePasteRowBefore:function(n){n.pasteRows(m,true)},mceTablePasteRowAfter:function(n){n.pasteRows(m)},mceTableDelete:function(n){n.deleteTable()}},function(o,n){g.addCommand(n,function(){var p=l();if(p){o(p);g.execCommand("mceRepaint");k()}})});e({mceInsertTable:function(n){f.open({url:h+"/table.htm",width:400+parseInt(g.getLang("table.table_delta_width",0)),height:320+parseInt(g.getLang("table.table_delta_height",0)),inline:1},{plugin_url:h,action:n?n.action:0})},mceTableRowProps:function(){f.open({url:h+"/row.htm",width:400+parseInt(g.getLang("table.rowprops_delta_width",0)),height:295+parseInt(g.getLang("table.rowprops_delta_height",0)),inline:1},{plugin_url:h})},mceTableCellProps:function(){f.open({url:h+"/cell.htm",width:400+parseInt(g.getLang("table.cellprops_delta_width",0)),height:295+parseInt(g.getLang("table.cellprops_delta_height",0)),inline:1},{plugin_url:h})}},function(o,n){g.addCommand(n,function(p,q){o(q)})})}});d.PluginManager.add("table",d.plugins.TablePlugin)})(tinymce);
|
@@ -287,6 +287,21 @@
|
|
287
287
|
endX = startX + (cols - 1);
|
288
288
|
endY = startY + (rows - 1);
|
289
289
|
} else {
|
290
|
+
startPos = endPos = null;
|
291
|
+
|
292
|
+
// Calculate start/end pos by checking for selected cells in grid works better with context menu
|
293
|
+
each(grid, function(row, y) {
|
294
|
+
each(row, function(cell, x) {
|
295
|
+
if (isCellSelected(cell)) {
|
296
|
+
if (!startPos) {
|
297
|
+
startPos = {x: x, y: y};
|
298
|
+
}
|
299
|
+
|
300
|
+
endPos = {x: x, y: y};
|
301
|
+
}
|
302
|
+
});
|
303
|
+
});
|
304
|
+
|
290
305
|
// Use selection
|
291
306
|
startX = startPos.x;
|
292
307
|
startY = startPos.y;
|
@@ -551,6 +566,10 @@
|
|
551
566
|
};
|
552
567
|
|
553
568
|
function pasteRows(rows, before) {
|
569
|
+
// If we don't have any rows in the clipboard, return immediately
|
570
|
+
if(!rows)
|
571
|
+
return;
|
572
|
+
|
554
573
|
var selectedRows = getSelectedRows(),
|
555
574
|
targetRow = selectedRows[before ? 0 : selectedRows.length - 1],
|
556
575
|
targetCellCount = targetRow.cells.length;
|
@@ -599,6 +618,9 @@
|
|
599
618
|
else
|
600
619
|
dom.insertAfter(row, targetRow);
|
601
620
|
});
|
621
|
+
|
622
|
+
// Remove current selection
|
623
|
+
dom.removeClass(dom.select('td.mceSelected,th.mceSelected'), 'mceSelected');
|
602
624
|
};
|
603
625
|
|
604
626
|
function getPos(target) {
|
@@ -1144,7 +1166,9 @@
|
|
1144
1166
|
}
|
1145
1167
|
|
1146
1168
|
function getChildForDirection(parent, up) {
|
1147
|
-
|
1169
|
+
var child = parent && parent[up ? 'lastChild' : 'firstChild'];
|
1170
|
+
// BR is not a valid table child to return in this case we return the table cell
|
1171
|
+
return child && child.nodeName === 'BR' ? ed.dom.getParent(child, 'td,th') : child;
|
1148
1172
|
}
|
1149
1173
|
|
1150
1174
|
function moveCursorToStartOfElement(n) {
|
@@ -1214,62 +1238,86 @@
|
|
1214
1238
|
|
1215
1239
|
ed.onKeyDown.add(moveSelection);
|
1216
1240
|
}
|
1217
|
-
|
1241
|
+
|
1218
1242
|
// Fixes an issue on Gecko where it's impossible to place the caret behind a table
|
1219
1243
|
// This fix will force a paragraph element after the table but only when the forced_root_block setting is enabled
|
1220
|
-
|
1221
|
-
|
1222
|
-
var last;
|
1244
|
+
function fixTableCaretPos() {
|
1245
|
+
var last;
|
1223
1246
|
|
1224
|
-
|
1225
|
-
|
1247
|
+
// Skip empty text nodes form the end
|
1248
|
+
for (last = ed.getBody().lastChild; last && last.nodeType == 3 && !last.nodeValue.length; last = last.previousSibling) ;
|
1226
1249
|
|
1227
|
-
|
1228
|
-
|
1229
|
-
|
1250
|
+
if (last && last.nodeName == 'TABLE') {
|
1251
|
+
if (ed.settings.forced_root_block)
|
1252
|
+
ed.dom.add(ed.getBody(), ed.settings.forced_root_block, null, tinymce.isIE ? ' ' : '<br data-mce-bogus="1" />');
|
1253
|
+
else
|
1254
|
+
ed.dom.add(ed.getBody(), 'br', {'data-mce-bogus': '1'});
|
1255
|
+
}
|
1256
|
+
};
|
1230
1257
|
|
1231
|
-
|
1232
|
-
|
1233
|
-
|
1234
|
-
|
1235
|
-
|
1236
|
-
|
1258
|
+
// Fixes an bug where it's impossible to place the caret before a table in Gecko
|
1259
|
+
// this fix solves it by detecting when the caret is at the beginning of such a table
|
1260
|
+
// and then manually moves the caret infront of the table
|
1261
|
+
if (tinymce.isGecko) {
|
1262
|
+
ed.onKeyDown.add(function(ed, e) {
|
1263
|
+
var rng, table, dom = ed.dom;
|
1237
1264
|
|
1238
|
-
|
1239
|
-
|
1240
|
-
|
1241
|
-
|
1265
|
+
// On gecko it's not possible to place the caret before a table
|
1266
|
+
if (e.keyCode == 37 || e.keyCode == 38) {
|
1267
|
+
rng = ed.selection.getRng();
|
1268
|
+
table = dom.getParent(rng.startContainer, 'table');
|
1242
1269
|
|
1243
|
-
|
1244
|
-
|
1245
|
-
|
1270
|
+
if (table && ed.getBody().firstChild == table) {
|
1271
|
+
if (isAtStart(rng, table)) {
|
1272
|
+
rng = dom.createRng();
|
1246
1273
|
|
1247
|
-
|
1248
|
-
|
1274
|
+
rng.setStartBefore(table);
|
1275
|
+
rng.setEndBefore(table);
|
1249
1276
|
|
1250
|
-
|
1277
|
+
ed.selection.setRng(rng);
|
1251
1278
|
|
1252
|
-
|
1253
|
-
}
|
1279
|
+
e.preventDefault();
|
1254
1280
|
}
|
1255
1281
|
}
|
1256
|
-
}
|
1257
|
-
}
|
1282
|
+
}
|
1283
|
+
});
|
1284
|
+
}
|
1258
1285
|
|
1259
|
-
|
1260
|
-
|
1261
|
-
|
1286
|
+
ed.onKeyUp.add(fixTableCaretPos);
|
1287
|
+
ed.onSetContent.add(fixTableCaretPos);
|
1288
|
+
ed.onVisualAid.add(fixTableCaretPos);
|
1262
1289
|
|
1263
|
-
|
1264
|
-
|
1290
|
+
ed.onPreProcess.add(function(ed, o) {
|
1291
|
+
var last = o.node.lastChild;
|
1292
|
+
|
1293
|
+
if (last && (last.nodeName == "BR" || (last.childNodes.length == 1 && (last.firstChild.nodeName == 'BR' || last.firstChild.nodeValue == '\u00a0'))) && last.previousSibling && last.previousSibling.nodeName == "TABLE") {
|
1294
|
+
ed.dom.remove(last);
|
1295
|
+
}
|
1296
|
+
});
|
1265
1297
|
|
1266
|
-
if (last && last.childNodes.length == 1 && last.firstChild.nodeName == 'BR')
|
1267
|
-
ed.dom.remove(last);
|
1268
|
-
});
|
1269
1298
|
|
1270
|
-
|
1271
|
-
|
1299
|
+
/**
|
1300
|
+
* Fixes bug in Gecko where shift-enter in table cell does not place caret on new line
|
1301
|
+
*
|
1302
|
+
* Removed: Since the new enter logic seems to fix this one.
|
1303
|
+
*/
|
1304
|
+
/*
|
1305
|
+
if (tinymce.isGecko) {
|
1306
|
+
ed.onKeyDown.add(function(ed, e) {
|
1307
|
+
if (e.keyCode === tinymce.VK.ENTER && e.shiftKey) {
|
1308
|
+
var node = ed.selection.getRng().startContainer;
|
1309
|
+
var tableCell = dom.getParent(node, 'td,th');
|
1310
|
+
if (tableCell) {
|
1311
|
+
var zeroSizedNbsp = ed.getDoc().createTextNode("\uFEFF");
|
1312
|
+
dom.insertAfter(zeroSizedNbsp, node);
|
1313
|
+
}
|
1314
|
+
}
|
1315
|
+
});
|
1272
1316
|
}
|
1317
|
+
*/
|
1318
|
+
|
1319
|
+
fixTableCaretPos();
|
1320
|
+
ed.startContent = ed.getContent({format : 'raw'});
|
1273
1321
|
});
|
1274
1322
|
|
1275
1323
|
// Register action commands
|