projects
/
roojs1
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1a3c34a
)
Roo/form/HtmlEditor.js
author
Alan Knowles
<alan@roojs.com>
Tue, 20 Aug 2013 06:46:49 +0000
(14:46 +0800)
committer
Alan Knowles
<alan@roojs.com>
Tue, 20 Aug 2013 06:46:49 +0000
(14:46 +0800)
Roo/form/HtmlEditor.js
patch
|
blob
|
history
diff --git
a/Roo/form/HtmlEditor.js
b/Roo/form/HtmlEditor.js
index
e27d058
..
379920d
100644
(file)
--- a/
Roo/form/HtmlEditor.js
+++ b/
Roo/form/HtmlEditor.js
@@
-636,7
+636,18
@@
Roo.form.HtmlEditor = Roo.extend(Roo.form.Field, {
insertTag : function(tg)
{
// could be a bit smarter... -> wrap the current selected tRoo..
-
+ if (tg.toLowerCase() == 'span') {
+
+ range = this.createRange(this.getSelection());
+ var wrappingNode = this.doc.createElement("span");
+ wrappingNode.appendChild(range.extractContents());
+ range.insertNode(wrappingNode);
+
+ return;
+
+
+
+ }
this.execCmd("formatblock", tg);
},