From 0e788318ba01d579bcb3c29036dda66bc17c1569 Mon Sep 17 00:00:00 2001 From: Jose Antonio Marquez Russo Date: Tue, 31 Jul 2012 18:53:59 -0700 Subject: Fix: Replacing deprecated blobBuilder Fixes issues with copying library files from File System. Need to fix ArrayBuffer, but this is just a warning that does not break functionality. --- js/io/system/chromeapi.js | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'js') diff --git a/js/io/system/chromeapi.js b/js/io/system/chromeapi.js index e46894d3..e33406ee 100644 --- a/js/io/system/chromeapi.js +++ b/js/io/system/chromeapi.js @@ -96,7 +96,7 @@ exports.ChromeApi = Montage.create(Object.prototype, { // f.createWriter(function(writer) { // - var mime, blob = new window.WebKitBlobBuilder, type = filePath.split('.'); + var mime, blob, type = filePath.split('.'); type = type[type.length-1]; switch (type) { case 'bmp': @@ -137,8 +137,9 @@ exports.ChromeApi = Montage.create(Object.prototype, { break; } // - blob.append(content); - writer.write(blob.getBlob(mime)); + blob = new Blob([content], {type: type}); + // + writer.write(blob); // if (callback) callback(true); }, function (e) {if (callback) callback(false)}); -- cgit v1.2.3