Keep cleaning and refactoring styles and samples.

This commit is contained in:
Paulo Veiga
2012-02-02 00:13:29 -03:00
parent b37ecd8c2c
commit b6dd7712f9
23 changed files with 317 additions and 1276 deletions

View File

@@ -28,10 +28,10 @@ mindplot.DesignerUndoManager = new Class({
enqueue:function(command) {
$assert(command, "Command can not be null");
var length = this._undoQueue.length;
if (command.discartDuplicated && length > 0) {
if (command.discardDuplicated && length > 0) {
// Skip duplicated events ...
var lastItem = this._undoQueue[length - 1];
if (lastItem.discartDuplicated != command.discartDuplicated) {
if (lastItem.discardDuplicated != command.discardDuplicated) {
this._undoQueue.push(command);
}
} else {

View File

@@ -17,7 +17,7 @@
*/
mindplot.DwrPersitenceManager = new Class({
Extends:mindplot.PersitenceManager,
Extends:mindplot.PersistenceManager,
initialize: function() {
this.parent();
},

View File

@@ -17,7 +17,7 @@
*/
mindplot.LocalStorageManager = new Class({
Extends:mindplot.PersitenceManager,
Extends:mindplot.PersistenceManager,
initialize: function() {
this.parent();
},
@@ -32,7 +32,7 @@ mindplot.LocalStorageManager = new Class({
if (xml == null) {
// Let's try to open one from the local directory ...
var xmlRequest = new Request({
url: '../maps/' + mapId + '.xml',
url: '../samples/' + mapId + '.xml',
method: 'get',
async: false,
onSuccess: function(responseText) {

View File

@@ -16,7 +16,7 @@
* limitations under the License.
*/
mindplot.PersitenceManager = new Class({
mindplot.PersistenceManager = new Class({
initialize: function() {
},
@@ -68,11 +68,11 @@ mindplot.PersitenceManager = new Class({
}
});
mindplot.PersitenceManager.init = function(instance) {
mindplot.PersitenceManager._instance = instance;
mindplot.PersistenceManager.init = function(instance) {
mindplot.PersistenceManager._instance = instance;
};
mindplot.PersitenceManager.getInstance = function() {
return mindplot.PersitenceManager._instance;
mindplot.PersistenceManager.getInstance = function() {
return mindplot.PersistenceManager._instance;
};

View File

@@ -150,7 +150,7 @@ mindplot.StandaloneActionDispatcher = new Class({
};
var command = new mindplot.commands.GenericFunctionCommand(commandFunc, topicsIds, color);
command.discartDuplicated = "fontColorCommandId";
command.discardDuplicated = "fontColorCommandId";
this.execute(command);
},
@@ -165,7 +165,7 @@ mindplot.StandaloneActionDispatcher = new Class({
};
var command = new mindplot.commands.GenericFunctionCommand(commandFunc, topicsIds, color);
command.discartDuplicated = "backColor";
command.discardDuplicated = "backColor";
this.execute(command);
},
@@ -180,7 +180,7 @@ mindplot.StandaloneActionDispatcher = new Class({
};
var command = new mindplot.commands.GenericFunctionCommand(commandFunc, topicsIds, color);
command.discartDuplicated = "borderColorCommandId";
command.discardDuplicated = "borderColorCommandId";
this.execute(command);
},

View File

@@ -48,7 +48,7 @@ mindplot.widget.IMenu = new Class({
}
// Call persistence manager for saving ...
var persistenceManager = mindplot.PersitenceManager.getInstance();
var persistenceManager = mindplot.PersistenceManager.getInstance();
persistenceManager.save(mindmap, mindmapProp, saveHistory, {
onSuccess: function() {
if (saveHistory) {