bundles/org.eclipse.orion.client.editor/web/orion/editor/undoStack.js
function (change) {
			if (this.compoundChange) {
				this.compoundChange.add(change);
			} else {
				var length = this.stack.length;
				this.stack.splice(this.index, length-this.index, change);
				this.index++;
				if (this.stack.length > this.size) {
					this.stack.shift();
					this.index--;
				}
			}
		}
function (change) {
			if (this.compoundChange) {
				this.compoundChange.add(change);
			} else {
				var length = this.stack.length;
				this.stack.splice(this.index, length-this.index, change);
				this.index++;
				if (this.stack.length > this.size) {
					this.stack.shift();
					this.index--;
				}
			}
		}
function ( change ) { if ( this . compoundChange ) { this . compoundChange . add ( change ) ; } else { var length = this . stack . length ; this . stack . splice ( this . index , length - this . index , change ) ; this . index ++ ; if ( this . stack . length > this . size ) { this . stack . shift ( ) ; this . index -- ; } } }
Adds a change to the stack.

@param change the change to add.
Adds a change to the stack .