this._container().append(el.dom);
}
}.bind(this));
+
+ this.commentTip = $('<div class="comment-tip"><i class="icon-comment"></i></div>');
+ this.addWidget(this.commentTip);
+
+ if(!this.wlxmlNode.hasChild({klass: 'comment'})) {
+ this.commentTip.hide();
+ }
+
this.refresh();
},
}
referenceElement[referenceAction](actionArg);
+
+ if(event.meta.node.is('comment')) {
+ this.commentTip.show();
+ }
},
onNodeDetached: function(event) {
+ var isComment = event.meta.node.is('comment');
if(event.meta.node.sameNode(this)) {
this.detach();
} else {
return true;
}
});
+ if(isComment && !this.wlxmlNode.hasChild({klass: 'comment'})) {
+ this.commentTip.hide();
+ }
}
},
onNodeTextChange: function(event) {