Fix add links.

This commit is contained in:
Paulo Veiga
2011-10-08 20:36:47 -03:00
parent 52587c0eaa
commit 5d1ab3cb6e
19 changed files with 333 additions and 306 deletions

View File

@@ -25,7 +25,8 @@ mindplot.commands.ChangeNoteToTopicCommand = new Class({
this._oldtext = null;
this._id = mindplot.Command._nextUUID();
},
execute: function(commandContext) {
execute: function(commandContext) {
var topic = commandContext.findTopics(this._objectsIds)[0];
if (topic.hasNote()) {
var model = topic.getModel();
@@ -35,6 +36,7 @@ mindplot.commands.ChangeNoteToTopicCommand = new Class({
}
topic.addNote(this._text);
},
undoExecute: function(commandContext) {
var topic = commandContext.findTopics(this._objectsIds)[0];
if (this._oldtext) {