fnp
/
fnpeditor.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Refactoring: Moving commands out of canvasManager
[fnpeditor.git]
/
modules
/
documentCanvas
/
canvas
/
documentElement.js
diff --git
a/modules/documentCanvas/canvas/documentElement.js
b/modules/documentCanvas/canvas/documentElement.js
index
669e06a
..
230e987
100644
(file)
--- a/
modules/documentCanvas/canvas/documentElement.js
+++ b/
modules/documentCanvas/canvas/documentElement.js
@@
-315,8
+315,10
@@
$.extend(DocumentTextElement.prototype, {
}
},
unwrap: function() {
}
},
unwrap: function() {
- var parent = this.parent();
+ var parent = this.parent(),
+ toret;
if(parent.children().length === 1) {
if(parent.children().length === 1) {
+ toret = parent.parent();
var grandParent = parent.parent();
if(grandParent) {
var grandParentChildren = grandParent.children(),
var grandParent = parent.parent();
if(grandParent) {
var grandParentChildren = grandParent.children(),
@@
-336,6
+338,7
@@
$.extend(DocumentTextElement.prototype, {
parent.after(this);
}
parent.detach();
parent.after(this);
}
parent.detach();
+ return toret;
}
},
split: function(params) {
}
},
split: function(params) {