aboutsummaryrefslogtreecommitdiff
path: root/mod/tinymce/vendor/tinymce/jscripts/tiny_mce/plugins/advimage
diff options
context:
space:
mode:
authorBrett Profitt <brett.profitt@gmail.com>2011-10-04 20:59:33 -0700
committerBrett Profitt <brett.profitt@gmail.com>2011-10-04 20:59:33 -0700
commit2be122cb5032567e88bb926b8aac250fd488cf68 (patch)
treed8900899a18f29d39c39380bec119823f38f34e5 /mod/tinymce/vendor/tinymce/jscripts/tiny_mce/plugins/advimage
parent34a7e57ef205362d6c093fa7234ca38977560bea (diff)
downloadelgg-2be122cb5032567e88bb926b8aac250fd488cf68.tar.gz
elgg-2be122cb5032567e88bb926b8aac250fd488cf68.tar.bz2
Refs #3853. Upgraded TinyMCE to 3.4.6. Embed still inserts the content in the wrong place for IE 8.
Diffstat (limited to 'mod/tinymce/vendor/tinymce/jscripts/tiny_mce/plugins/advimage')
-rw-r--r--mod/tinymce/vendor/tinymce/jscripts/tiny_mce/plugins/advimage/editor_plugin.js2
-rw-r--r--mod/tinymce/vendor/tinymce/jscripts/tiny_mce/plugins/advimage/editor_plugin_src.js2
-rw-r--r--mod/tinymce/vendor/tinymce/jscripts/tiny_mce/plugins/advimage/js/image.js20
-rw-r--r--mod/tinymce/vendor/tinymce/jscripts/tiny_mce/plugins/advimage/langs/en_dlg.js46
4 files changed, 15 insertions, 55 deletions
diff --git a/mod/tinymce/vendor/tinymce/jscripts/tiny_mce/plugins/advimage/editor_plugin.js b/mod/tinymce/vendor/tinymce/jscripts/tiny_mce/plugins/advimage/editor_plugin.js
index 4c7a9c3a8..d613a6139 100644
--- a/mod/tinymce/vendor/tinymce/jscripts/tiny_mce/plugins/advimage/editor_plugin.js
+++ b/mod/tinymce/vendor/tinymce/jscripts/tiny_mce/plugins/advimage/editor_plugin.js
@@ -1 +1 @@
-(function(){tinymce.create("tinymce.plugins.AdvancedImagePlugin",{init:function(a,b){a.addCommand("mceAdvImage",function(){if(a.dom.getAttrib(a.selection.getNode(),"class").indexOf("mceItem")!=-1){return}a.windowManager.open({file:b+"/image.htm",width:480+parseInt(a.getLang("advimage.delta_width",0)),height:385+parseInt(a.getLang("advimage.delta_height",0)),inline:1},{plugin_url:b})});a.addButton("image",{title:"advimage.image_desc",cmd:"mceAdvImage"})},getInfo:function(){return{longname:"Advanced image",author:"Moxiecode Systems AB",authorurl:"http://tinymce.moxiecode.com",infourl:"http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/advimage",version:tinymce.majorVersion+"."+tinymce.minorVersion}}});tinymce.PluginManager.add("advimage",tinymce.plugins.AdvancedImagePlugin)})(); \ No newline at end of file
+(function(){tinymce.create("tinymce.plugins.AdvancedImagePlugin",{init:function(a,b){a.addCommand("mceAdvImage",function(){if(a.dom.getAttrib(a.selection.getNode(),"class","").indexOf("mceItem")!=-1){return}a.windowManager.open({file:b+"/image.htm",width:480+parseInt(a.getLang("advimage.delta_width",0)),height:385+parseInt(a.getLang("advimage.delta_height",0)),inline:1},{plugin_url:b})});a.addButton("image",{title:"advimage.image_desc",cmd:"mceAdvImage"})},getInfo:function(){return{longname:"Advanced image",author:"Moxiecode Systems AB",authorurl:"http://tinymce.moxiecode.com",infourl:"http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/advimage",version:tinymce.majorVersion+"."+tinymce.minorVersion}}});tinymce.PluginManager.add("advimage",tinymce.plugins.AdvancedImagePlugin)})(); \ No newline at end of file
diff --git a/mod/tinymce/vendor/tinymce/jscripts/tiny_mce/plugins/advimage/editor_plugin_src.js b/mod/tinymce/vendor/tinymce/jscripts/tiny_mce/plugins/advimage/editor_plugin_src.js
index 2625dd213..d2678cbcf 100644
--- a/mod/tinymce/vendor/tinymce/jscripts/tiny_mce/plugins/advimage/editor_plugin_src.js
+++ b/mod/tinymce/vendor/tinymce/jscripts/tiny_mce/plugins/advimage/editor_plugin_src.js
@@ -14,7 +14,7 @@
// Register commands
ed.addCommand('mceAdvImage', function() {
// Internal image object like a flash placeholder
- if (ed.dom.getAttrib(ed.selection.getNode(), 'class').indexOf('mceItem') != -1)
+ if (ed.dom.getAttrib(ed.selection.getNode(), 'class', '').indexOf('mceItem') != -1)
return;
ed.windowManager.open({
diff --git a/mod/tinymce/vendor/tinymce/jscripts/tiny_mce/plugins/advimage/js/image.js b/mod/tinymce/vendor/tinymce/jscripts/tiny_mce/plugins/advimage/js/image.js
index 72c9cbf63..546b69c0d 100644
--- a/mod/tinymce/vendor/tinymce/jscripts/tiny_mce/plugins/advimage/js/image.js
+++ b/mod/tinymce/vendor/tinymce/jscripts/tiny_mce/plugins/advimage/js/image.js
@@ -9,13 +9,13 @@ var ImageDialog = {
},
init : function(ed) {
- var f = document.forms[0], nl = f.elements, ed = tinyMCEPopup.editor, dom = ed.dom, n = ed.selection.getNode();
+ var f = document.forms[0], nl = f.elements, ed = tinyMCEPopup.editor, dom = ed.dom, n = ed.selection.getNode(), fl = tinyMCEPopup.getParam('external_image_list', 'tinyMCEImageList');
tinyMCEPopup.resizeToInnerSize();
this.fillClassList('class_list');
- this.fillFileList('src_list', 'tinyMCEImageList');
- this.fillFileList('over_list', 'tinyMCEImageList');
- this.fillFileList('out_list', 'tinyMCEImageList');
+ this.fillFileList('src_list', fl);
+ this.fillFileList('over_list', fl);
+ this.fillFileList('out_list', fl);
TinyMCE_EditableSelects.init();
if (n.nodeName == 'IMG') {
@@ -171,9 +171,13 @@ var ImageDialog = {
if (el && el.nodeName == 'IMG') {
ed.dom.setAttribs(el, args);
} else {
- ed.execCommand('mceInsertContent', false, '<img id="__mce_tmp" />', {skip_undo : 1});
- ed.dom.setAttribs('__mce_tmp', args);
- ed.dom.setAttrib('__mce_tmp', 'id', '');
+ tinymce.each(args, function(value, name) {
+ if (value === "") {
+ delete args[name];
+ }
+ });
+
+ ed.execCommand('mceInsertContent', false, tinyMCEPopup.editor.dom.createHTML('img', args), {skip_undo : 1});
ed.undoManager.add();
}
@@ -287,7 +291,7 @@ var ImageDialog = {
fillFileList : function(id, l) {
var dom = tinyMCEPopup.dom, lst = dom.get(id), v, cl;
- l = window[l];
+ l = typeof(l) === 'function' ? l() : window[l];
lst.options.length = 0;
if (l && l.length > 0) {
diff --git a/mod/tinymce/vendor/tinymce/jscripts/tiny_mce/plugins/advimage/langs/en_dlg.js b/mod/tinymce/vendor/tinymce/jscripts/tiny_mce/plugins/advimage/langs/en_dlg.js
index d8f11e030..5f122e2cd 100644
--- a/mod/tinymce/vendor/tinymce/jscripts/tiny_mce/plugins/advimage/langs/en_dlg.js
+++ b/mod/tinymce/vendor/tinymce/jscripts/tiny_mce/plugins/advimage/langs/en_dlg.js
@@ -1,45 +1 @@
-tinyMCE.addI18n('en.advimage_dlg',{
-tab_general:"General",
-tab_appearance:"Appearance",
-tab_advanced:"Advanced",
-general:"General",
-title:"Title",
-preview:"Preview",
-constrain_proportions:"Constrain proportions",
-langdir:"Language direction",
-langcode:"Language code",
-long_desc:"Long description link",
-style:"Style",
-classes:"Classes",
-ltr:"Left to right",
-rtl:"Right to left",
-id:"Id",
-map:"Image map",
-swap_image:"Swap image",
-alt_image:"Alternative image",
-mouseover:"for mouse over",
-mouseout:"for mouse out",
-misc:"Miscellaneous",
-example_img:"Appearance preview image",
-missing_alt:"Are you sure you want to continue without including an Image Description? Without it the image may not be accessible to some users with disabilities, or to those using a text browser, or browsing the Web with images turned off.",
-dialog_title:"Insert/edit image",
-src:"Image URL",
-alt:"Image description",
-list:"Image list",
-border:"Border",
-dimensions:"Dimensions",
-width:"Width",
-height:"Height",
-vspace:"Vertical space",
-hspace:"Horizontal space",
-align:"Alignment",
-align_baseline:"Baseline",
-align_top:"Top",
-align_middle:"Middle",
-align_bottom:"Bottom",
-align_texttop:"Text top",
-align_textbottom:"Text bottom",
-align_left:"Left",
-align_right:"Right",
-image_list:"Image list"
-}); \ No newline at end of file
+tinyMCE.addI18n('en.advimage_dlg',{"image_list":"Image List","align_right":"Right","align_left":"Left","align_textbottom":"Text Bottom","align_texttop":"Text Top","align_bottom":"Bottom","align_middle":"Middle","align_top":"Top","align_baseline":"Baseline",align:"Alignment",hspace:"Horizontal Space",vspace:"Vertical Space",dimensions:"Dimensions",border:"Border",list:"Image List",alt:"Image Description",src:"Image URL","dialog_title":"Insert/Edit Image","missing_alt":"Are you sure you want to continue without including an Image Description? Without it the image may not be accessible to some users with disabilities, or to those using a text browser, or browsing the Web with images turned off.","example_img":"Appearance Preview Image",misc:"Miscellaneous",mouseout:"For Mouse Out",mouseover:"For Mouse Over","alt_image":"Alternative Image","swap_image":"Swap Image",map:"Image Map",id:"ID",rtl:"Right to Left",ltr:"Left to Right",classes:"Classes",style:"Style","long_desc":"Long Description Link",langcode:"Language Code",langdir:"Language Direction","constrain_proportions":"Constrain Proportions",preview:"Preview",title:"Title",general:"General","tab_advanced":"Advanced","tab_appearance":"Appearance","tab_general":"General",width:"Width",height:"Height"}); \ No newline at end of file