TinyMCE: update the charmap plugin to the latest dev. version. Fixes problems with inserting white space characters.

Fixes #37936.
Built from https://develop.svn.wordpress.org/trunk@38780


git-svn-id: http://core.svn.wordpress.org/trunk@38723 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Andrew Ozz 2016-10-11 23:56:31 +00:00
parent 220c0589da
commit 61c95f84f6
4 changed files with 10 additions and 6 deletions

View File

@ -354,9 +354,13 @@ tinymce.PluginManager.add('charmap', function(editor) {
var index = y * width + x;
if (index < charmap.length) {
var chr = charmap[index];
var chrText = chr ? String.fromCharCode(parseInt(chr[0], 10)) : '&nbsp;';
gridHtml += '<td title="' + chr[1] + '"><div tabindex="-1" title="' + chr[1] + '" role="button">' +
(chr ? String.fromCharCode(parseInt(chr[0], 10)) : '&nbsp;') + '</div></td>';
gridHtml += (
'<td title="' + chr[1] + '"><div tabindex="-1" title="' + chr[1] + '" role="button" data-chr="' + chrText + '">' +
chrText +
'</div></td>'
);
} else {
gridHtml += '<td />';
}
@ -375,7 +379,7 @@ tinymce.PluginManager.add('charmap', function(editor) {
if (/^(TD|DIV)$/.test(target.nodeName)) {
if (getParentTd(target).firstChild) {
insertChar(tinymce.trim(target.innerText || target.textContent));
insertChar(target.getAttribute('data-chr'));
if (!e.ctrlKey) {
win.close();
@ -459,4 +463,4 @@ tinymce.PluginManager.add('charmap', function(editor) {
getCharMap: getCharMap,
insertChar: insertChar
};
});
});

File diff suppressed because one or more lines are too long

View File

@ -4,7 +4,7 @@
*
* @global string $wp_version
*/
$wp_version = '4.7-alpha-38779';
$wp_version = '4.7-alpha-38780';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.