fnp
/
fnpeditor.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Integrating new canvas api into rest of the modules
[fnpeditor.git]
/
modules
/
nodeFamilyTree
/
nodeFamilyTree.js
diff --git
a/modules/nodeFamilyTree/nodeFamilyTree.js
b/modules/nodeFamilyTree/nodeFamilyTree.js
index
7415b2d
..
b5cb56e
100644
(file)
--- a/
modules/nodeFamilyTree/nodeFamilyTree.js
+++ b/
modules/nodeFamilyTree/nodeFamilyTree.js
@@
-37,26
+37,26
@@
return function(sandbox) {
\r
if(parentNode) {
\r
parent = {
\r
\r
if(parentNode) {
\r
parent = {
\r
- repr: parentNode.
tag + (parentNode.klass ? ' / ' + parentNode.klass
: ''),
\r
- id: parentNode.
id
\r
+ repr: parentNode.
getTag() + (parentNode.getClass() ? ' / ' + parentNode.getClass()
: ''),
\r
+ id: parentNode.
getId()
\r
};
\r
};
\r
- this.nodes[parentNode.
id
] = parentNode;
\r
+ this.nodes[parentNode.
getId()
] = parentNode;
\r
}
\r
\r
var children = [];
\r
node.children().each(function() {
\r
var child = this;
\r
}
\r
\r
var children = [];
\r
node.children().each(function() {
\r
var child = this;
\r
- children.push({repr: child.
tag + (child.klass ? ' / ' + child.klass : ''), id: child.id
});
\r
- nodes[child.
id
] = child;
\r
+ children.push({repr: child.
getTag() + (child.getClass() ? ' / ' + child.getClass() : ''), id: child.getId()
});
\r
+ nodes[child.
getId()
] = child;
\r
});
\r
this.dom.empty();
\r
this.dom.append($(template({parent: parent, children: children})));
\r
},
\r
});
\r
this.dom.empty();
\r
this.dom.append($(template({parent: parent, children: children})));
\r
},
\r
- highlightNode: function(
wlxml
Node) {
\r
- this.dom.find('a[data-id="'+
wlxmlNode.id
+'"]').addClass('rng-common-hoveredNode');
\r
+ highlightNode: function(
canvas
Node) {
\r
+ this.dom.find('a[data-id="'+
canvasNode.getId()
+'"]').addClass('rng-common-hoveredNode');
\r
},
\r
},
\r
- dimNode: function(
wlxml
Node) {
\r
- this.dom.find('a[data-id="'+
wlxmlNode.id
+'"]').removeClass('rng-common-hoveredNode');
\r
+ dimNode: function(
canvas
Node) {
\r
+ this.dom.find('a[data-id="'+
canvasNode.getId()
+'"]').removeClass('rng-common-hoveredNode');
\r
}
\r
}
\r
\r
}
\r
}
\r
\r
@@
-66,18
+66,18
@@
return function(sandbox) {
start: function() {
\r
sandbox.publish('ready');
\r
},
\r
start: function() {
\r
sandbox.publish('ready');
\r
},
\r
- setNode: function(
wlxml
Node) {
\r
- if(!
wlxmlNode.is
(view.currentNode))
\r
- view.setNode(
wlxml
Node);
\r
+ setNode: function(
canvas
Node) {
\r
+ if(!
canvasNode.isSame
(view.currentNode))
\r
+ view.setNode(
canvas
Node);
\r
},
\r
getView: function() {
\r
return view.dom;
\r
},
\r
},
\r
getView: function() {
\r
return view.dom;
\r
},
\r
- highlightNode: function(
wlxml
Node) {
\r
- view.highlightNode(
wlxml
Node);
\r
+ highlightNode: function(
canvas
Node) {
\r
+ view.highlightNode(
canvas
Node);
\r
},
\r
},
\r
- dimNode: function(
wlxml
Node) {
\r
- view.dimNode(
wlxml
Node);
\r
+ dimNode: function(
canvas
Node) {
\r
+ view.dimNode(
canvas
Node);
\r
}
\r
};
\r
};
\r
}
\r
};
\r
};
\r