public/javascripts/yui/datatable/datatable.js
function() {
    // Get new value
    var inputValue = this.getInputValue();
    var validValue = inputValue;
    
    // Validate new value
    if(this.validator) {
        validValue = this.validator.call(this.getDataTable(), inputValue, this.value, this);
        if(validValue === undefined ) {
            if(this.resetInvalidData) {
                this.resetForm();
            }
            this.fireEvent("invalidDataEvent",
                    {editor:this, oldData:this.value, newData:inputValue});
            return;
        }
    }
        
    var oSelf = this;
    var finishSave = function(bSuccess, oNewValue) {
        var oOrigValue = oSelf.value;
        if(bSuccess) {
            // Update new value
            oSelf.value = oNewValue;
            oSelf.getDataTable().updateCell(oSelf.getRecord(), oSelf.getColumn(), oNewValue);
            
            // Hide CellEditor
            oSelf.getContainerEl().style.display = "none";
            oSelf.isActive = false;
            oSelf.getDataTable()._oCellEditor =  null;
            
            oSelf.fireEvent("saveEvent",
                    {editor:oSelf, oldData:oOrigValue, newData:oSelf.value});
        }
        else {
            oSelf.resetForm();
            oSelf.fireEvent("revertEvent",
                    {editor:oSelf, oldData:oOrigValue, newData:oNewValue});
        }
        oSelf.unblock();
    };
    
    this.block();
    if(lang.isFunction(this.asyncSubmitter)) {
        this.asyncSubmitter.call(this, finishSave, validValue);
    } 
    else {   
        finishSave(true, validValue);
    }
}
function() {
    // Get new value
    var inputValue = this.getInputValue();
    var validValue = inputValue;
    
    // Validate new value
    if(this.validator) {
        validValue = this.validator.call(this.getDataTable(), inputValue, this.value, this);
        if(validValue === undefined ) {
            if(this.resetInvalidData) {
                this.resetForm();
            }
            this.fireEvent("invalidDataEvent",
                    {editor:this, oldData:this.value, newData:inputValue});
            return;
        }
    }
        
    var oSelf = this;
    var finishSave = function(bSuccess, oNewValue) {
        var oOrigValue = oSelf.value;
        if(bSuccess) {
            // Update new value
            oSelf.value = oNewValue;
            oSelf.getDataTable().updateCell(oSelf.getRecord(), oSelf.getColumn(), oNewValue);
            
            // Hide CellEditor
            oSelf.getContainerEl().style.display = "none";
            oSelf.isActive = false;
            oSelf.getDataTable()._oCellEditor =  null;
            
            oSelf.fireEvent("saveEvent",
                    {editor:oSelf, oldData:oOrigValue, newData:oSelf.value});
        }
        else {
            oSelf.resetForm();
            oSelf.fireEvent("revertEvent",
                    {editor:oSelf, oldData:oOrigValue, newData:oNewValue});
        }
        oSelf.unblock();
    };
    
    this.block();
    if(lang.isFunction(this.asyncSubmitter)) {
        this.asyncSubmitter.call(this, finishSave, validValue);
    } 
    else {   
        finishSave(true, validValue);
    }
}
function ( ) { // Get new value var inputValue = this . getInputValue ( ) ; var validValue = inputValue ; // Validate new value if ( this . validator ) { validValue = this . validator . call ( this . getDataTable ( ) , inputValue , this . value , this ) ; if ( validValue === undefined ) { if ( this . resetInvalidData ) { this . resetForm ( ) ; } this . fireEvent ( "invalidDataEvent" , { editor : this , oldData : this . value , newData : inputValue } ) ; return ; } } var oSelf = this ; var finishSave = function ( bSuccess , oNewValue ) { var oOrigValue = oSelf . value ; if ( bSuccess ) { // Update new value oSelf . value = oNewValue ; oSelf . getDataTable ( ) . updateCell ( oSelf . getRecord ( ) , oSelf . getColumn ( ) , oNewValue ) ; // Hide CellEditor oSelf . getContainerEl ( ) . style . display = "none" ; oSelf . isActive = false ; oSelf . getDataTable ( ) . _oCellEditor = null ; oSelf . fireEvent ( "saveEvent" , { editor : oSelf , oldData : oOrigValue , newData : oSelf . value } ) ; } else { oSelf . resetForm ( ) ; oSelf . fireEvent ( "revertEvent" , { editor : oSelf , oldData : oOrigValue , newData : oNewValue } ) ; } oSelf . unblock ( ) ; } ; this . block ( ) ; if ( lang . isFunction ( this . asyncSubmitter ) ) { this . asyncSubmitter . call ( this , finishSave , validValue ) ; } else { finishSave ( true , validValue ) ; } }
Saves value of CellEditor and hides UI.

@method save
Saves value of CellEditor and hides UI .