Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 27 additions & 1 deletion dist/ng-flow-standalone.js
Original file line number Diff line number Diff line change
Expand Up @@ -638,6 +638,16 @@
return ret;
},

/**
* Returns the count of files in the queue
* @function
* @returns {number}
*/
getFilesCount: function () {
var count = this.files.length;
return count;
},

/**
* Returns the total size of all files in bytes.
* @function
Expand Down Expand Up @@ -968,6 +978,22 @@
return this._prevProgress;
},

/**
* Get current number of complete chunks
* @function
* @returns {number} from 0 to chunks.length
*/
completeChunks: function () {
var completeChunks = 0;

each(this.chunks, function (c) {
if(c.progress() === 1){
completeChunks++;
}
});
return completeChunks;
},

/**
* Indicates if file is being uploaded at the moment
* @function
Expand Down Expand Up @@ -1922,4 +1948,4 @@ angular.module('flow.transfers', ['flow.init'])
};
}]);
angular.module('flow', ['flow.provider', 'flow.init', 'flow.events', 'flow.btn',
'flow.drop', 'flow.transfers', 'flow.img', 'flow.dragEvents']);
'flow.drop', 'flow.transfers', 'flow.img', 'flow.dragEvents']);