去掉 auto_height_node_before_update,页面会自适应
This commit is contained in:
+10
-8
@@ -1382,7 +1382,8 @@
|
|||||||
this.view.show(false);
|
this.view.show(false);
|
||||||
this.view.reset_node_custom_style(node);
|
this.view.reset_node_custom_style(node);
|
||||||
this.expand_node(parent_node);
|
this.expand_node(parent_node);
|
||||||
if (!stop_invoke_event) { /** by cy*/
|
if (!stop_invoke_event) {
|
||||||
|
/** by cy*/
|
||||||
this.invoke_event_handle(jm.event_type.edit, {
|
this.invoke_event_handle(jm.event_type.edit, {
|
||||||
evt: 'add_node',
|
evt: 'add_node',
|
||||||
data: [node.parent.id, nodeid, topic, data],
|
data: [node.parent.id, nodeid, topic, data],
|
||||||
@@ -1405,7 +1406,8 @@
|
|||||||
this.view.add_node(node);
|
this.view.add_node(node);
|
||||||
this.layout.layout();
|
this.layout.layout();
|
||||||
this.view.show(false);
|
this.view.show(false);
|
||||||
if (!stop_invoke_event) { /** by cy*/
|
if (!stop_invoke_event) {
|
||||||
|
/** by cy*/
|
||||||
this.invoke_event_handle(jm.event_type.edit, {
|
this.invoke_event_handle(jm.event_type.edit, {
|
||||||
evt: 'insert_node_before',
|
evt: 'insert_node_before',
|
||||||
data: [beforeid, nodeid, topic, data],
|
data: [beforeid, nodeid, topic, data],
|
||||||
@@ -1428,7 +1430,8 @@
|
|||||||
this.view.add_node(node);
|
this.view.add_node(node);
|
||||||
this.layout.layout();
|
this.layout.layout();
|
||||||
this.view.show(false);
|
this.view.show(false);
|
||||||
if (!stop_invoke_event) { /** by cy*/
|
if (!stop_invoke_event) {
|
||||||
|
/** by cy*/
|
||||||
this.invoke_event_handle(jm.event_type.edit, {
|
this.invoke_event_handle(jm.event_type.edit, {
|
||||||
evt: 'insert_node_after',
|
evt: 'insert_node_after',
|
||||||
data: [afterid, nodeid, topic, data],
|
data: [afterid, nodeid, topic, data],
|
||||||
@@ -1467,7 +1470,8 @@
|
|||||||
this.layout.layout();
|
this.layout.layout();
|
||||||
this.view.show(false);
|
this.view.show(false);
|
||||||
this.view.restore_location(parent_node);
|
this.view.restore_location(parent_node);
|
||||||
if (!stop_invoke_event) { /** by cy*/
|
if (!stop_invoke_event) {
|
||||||
|
/** by cy*/
|
||||||
this.invoke_event_handle(jm.event_type.edit, {evt: 'remove_node', data: [nodeid], node: parentid});
|
this.invoke_event_handle(jm.event_type.edit, {evt: 'remove_node', data: [nodeid], node: parentid});
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
@@ -1492,16 +1496,14 @@
|
|||||||
}
|
}
|
||||||
node.topic = topic;
|
node.topic = topic;
|
||||||
|
|
||||||
// by cy
|
|
||||||
this.auto_height_node_before_update(node)
|
|
||||||
|
|
||||||
this.view.update_node(node);
|
this.view.update_node(node);
|
||||||
|
|
||||||
this.layout.layout();
|
this.layout.layout();
|
||||||
|
|
||||||
this.view.show(false);
|
this.view.show(false);
|
||||||
|
|
||||||
if (!stop_invoke_event) { /** by cy*/
|
if (!stop_invoke_event) {
|
||||||
|
/** by cy*/
|
||||||
this.invoke_event_handle(jm.event_type.edit, {
|
this.invoke_event_handle(jm.event_type.edit, {
|
||||||
evt: 'update_node',
|
evt: 'update_node',
|
||||||
data: [nodeid, topic],
|
data: [nodeid, topic],
|
||||||
|
|||||||
Reference in New Issue
Block a user