()
| 837 | } |
| 838 | |
| 839 | _processThumbnailQueue() { |
| 840 | if (this._processingThumbnail || this._thumbnailQueue.length === 0) { |
| 841 | return; |
| 842 | } |
| 843 | |
| 844 | this._processingThumbnail = true; |
| 845 | let file = this._thumbnailQueue.shift(); |
| 846 | return this.createThumbnail( |
| 847 | file, |
| 848 | this.options.thumbnailWidth, |
| 849 | this.options.thumbnailHeight, |
| 850 | this.options.thumbnailMethod, |
| 851 | true, |
| 852 | (dataUrl) => { |
| 853 | this.emit("thumbnail", file, dataUrl); |
| 854 | this._processingThumbnail = false; |
| 855 | return this._processThumbnailQueue(); |
| 856 | } |
| 857 | ); |
| 858 | } |
| 859 | |
| 860 | // Can be called by the user to remove a file |
| 861 | removeFile(file) { |
no test coverage detected