To participate you must create an account on apostrophenow.org. If you have already done so, click Login.

Changeset 4485

Show
Ignore:
Timestamp:
01/20/12 10:42:45 (4 months ago)
Author:
tboutell
Message:

* Migrated qqUploader class to a name that should be easier to autoload, clear your cache
* Added onAllComplete event to qqUploader so we can tell when all of the uploads are completely done

Location:
plugins/apostropheHTML5Plugin/trunk
Files:
1 modified
1 moved

Legend:

Unmodified
Added
Removed
  • plugins/apostropheHTML5Plugin/trunk/web/fileuploader/fileuploader.js

    r4347 r4485  
    267267        onProgress: function(id, fileName, loaded, total){}, 
    268268        onComplete: function(id, fileName, responseJSON){}, 
     269        onAllComplete: function(){}, 
    269270        onCancel: function(id, fileName){}, 
    270271        // messages                 
     
    332333                self._onComplete(id, fileName, result); 
    333334                self._options.onComplete(id, fileName, result); 
     335            }, 
     336            onAllComplete: function(){ 
     337              self._options.onAllComplete(); 
    334338            }, 
    335339            onCancel: function(id, fileName){ 
     
    861865        onProgress: function(id, fileName, loaded, total){}, 
    862866        onComplete: function(id, fileName, response){}, 
     867        onAllComplete: function(){}, 
    863868        onCancel: function(id, fileName){} 
    864869    }; 
     
    944949            var nextId = this._queue[max-1]; 
    945950            this._upload(nextId, this._params[nextId]); 
     951        } 
     952        // tom@punkave.com: it really helps UI designers to be 
     953        // able to show a "Continue" button of some kind when  
     954        // the whole job is done and it's reasonable to dismiss 
     955        // the progress display 
     956        if (!this._queue.length) 
     957        { 
     958          this._options.onAllComplete(); 
    946959        } 
    947960    }