Commit 0cd57fa1 authored by campaign's avatar campaign

修改渲染方式

parent b06b0874
...@@ -41,7 +41,7 @@ function importNode( node, json, km ) { ...@@ -41,7 +41,7 @@ function importNode( node, json, km ) {
for ( var field in data ) { for ( var field in data ) {
node.setData( field, data[ field ] ); node.setData( field, data[ field ] );
} }
node.setText( data.text || km.getLang( DEFAULT_TEXT[ node.getType() ] ) ); node.setData( 'text',data.text || km.getLang( DEFAULT_TEXT[ node.getType() ] ) );
var childrenTreeData = json.children; var childrenTreeData = json.children;
if ( !childrenTreeData ) return; if ( !childrenTreeData ) return;
......
...@@ -311,6 +311,8 @@ var MinderNode = KityMinder.MinderNode = kity.createClass( "MinderNode", { ...@@ -311,6 +311,8 @@ var MinderNode = KityMinder.MinderNode = kity.createClass( "MinderNode", {
return false; return false;
} }
} ); } );
if(textShape === undefined)
debugger
return textShape; return textShape;
}, },
isSelected: function () { isSelected: function () {
......
...@@ -440,6 +440,7 @@ KityMinder.registerModule( "LayoutDefault", function () { ...@@ -440,6 +440,7 @@ KityMinder.registerModule( "LayoutDefault", function () {
} }
}, },
updateLayout: function ( node ) { updateLayout: function ( node ) {
node.getRenderContainer().clear();
this._firePharse( new MinderEvent( "RenderNodeLeft", { this._firePharse( new MinderEvent( "RenderNodeLeft", {
node: node node: node
}, false ) ); }, false ) );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment