deleteCostume (costumeIndex) {
        this.emit('deleteCostume*', {name: this.editingTarget.getCostumes()[costumeIndex].name});
        const deletedCostume = this.editingTarget.deleteCostume(costumeIndex);
        if (deletedCostume) {
            const target = this.editingTarget;
            this.runtime.emitProjectChanged();
            return () => {
                target.addCostume(deletedCostume);
                this.emitTargetsUpdate();
            };
        }
        return null;
    }
/**
     * Delete a costume from the current editing target.
     * @param {int} costumeIndex - the index of the costume to be removed.
     * @return {?function} A function to restore the deleted costume, or null,
     * if no costume was deleted.
     */
Delete a costume from the current editing target.
@param {int} costumeIndex - the index of the costume to be removed.
@return {?function} A function to restore the deleted costume, or null,
if no costume was deleted.
Delete a costume from the current editing target . @param { int } costumeIndex - the index of the costume to be removed . @return { ?function } A function to restore the deleted costume or null if no costume was deleted .
deleteCostume (costumeIndex) {
        this.emit('deleteCostume*', {name: this.editingTarget.getCostumes()[costumeIndex].name});
        const deletedCostume = this.editingTarget.deleteCostume(costumeIndex);
        if (deletedCostume) {
            const target = this.editingTarget;
            this.runtime.emitProjectChanged();
            return () => {
                target.addCostume(deletedCostume);
                this.emitTargetsUpdate();
            };
        }
        return null;
    }
deleteCostume ( costumeIndex ) { this . emit ( 'deleteCostume*' , { name : this . editingTarget . getCostumes ( ) [ costumeIndex ] . name } ) ; const deletedCostume = this . editingTarget . deleteCostume ( costumeIndex ) ; if ( deletedCostume ) { const target = this . editingTarget ; this . runtime . emitProjectChanged ( ) ; return ( ) => { target . addCostume ( deletedCostume ) ; this . emitTargetsUpdate ( ) ; } ; } return null ; }
Delete a costume from the current editing target.
Delete a costume from the current editing target .