| Index: third_party/WebKit/LayoutTests/http/tests/local/blob/resources/hybrid-blob-util.js
|
| diff --git a/third_party/WebKit/LayoutTests/http/tests/local/blob/resources/hybrid-blob-util.js b/third_party/WebKit/LayoutTests/http/tests/local/blob/resources/hybrid-blob-util.js
|
| index 6d3e986ce82f48ffa29714ab3bae52185c9562ce..ae3b0ebb54380cff2969b1f314b961e11e62b013 100644
|
| --- a/third_party/WebKit/LayoutTests/http/tests/local/blob/resources/hybrid-blob-util.js
|
| +++ b/third_party/WebKit/LayoutTests/http/tests/local/blob/resources/hybrid-blob-util.js
|
| @@ -100,48 +100,41 @@ var HybridBlobTestUtil = function(testFunc, opt_filePaths) {
|
| return item;
|
| }
|
|
|
| - this.createItemParamArray = function(items, itemParams, opt_ending)
|
| + this.createItemParamArray = function(items, itemParams)
|
| {
|
| for (var i = 0; i < items.length; i++) {
|
| if (items[i] instanceof Array)
|
| - this.createItemParamArray(items[i], itemParams, opt_ending);
|
| + this.createItemParamArray(items[i], itemParams);
|
| else if (items[i].type == "data") {
|
| - var data = items[i].value;
|
| - if (opt_ending)
|
| - data = data.replace(/\r\n/g, "[NL]").replace(/[\n\r]/g, "[NL]");
|
| - itemParams.push("data:" + escape(data));
|
| + itemParams.push("data:" + escape(items[i].value));
|
| } else if (items[i].type == "file")
|
| itemParams.push("file:" + this.urlPathBaseDir + items[i].path);
|
| }
|
| };
|
|
|
| - this.createUrlParameter = function(items, opt_range, opt_ending)
|
| + this.createUrlParameter = function(items, opt_range)
|
| {
|
| var itemParams = [];
|
| - this.createItemParamArray(items, itemParams, opt_ending);
|
| + this.createItemParamArray(items, itemParams);
|
| var urlParameter = "items=" + itemParams.join(",");
|
| if (opt_range) {
|
| urlParameter += "&start=" + opt_range.start;
|
| urlParameter += "&length=" + opt_range.length;
|
| }
|
| - if (opt_ending)
|
| - urlParameter += "&convert_newlines=1";
|
| return urlParameter;
|
| };
|
|
|
| - this.appendAndCreateBlob = function(items, opt_ending, opt_type)
|
| + this.appendAndCreateBlob = function(items, opt_type)
|
| {
|
| var builder = [];
|
| for (var i = 0; i < items.length; i++) {
|
| if (items[i] instanceof Array) {
|
| // If it's an array, combine its elements and append as a blob.
|
| - builder.push(this.appendAndCreateBlob(items[i], opt_ending, opt_type));
|
| + builder.push(this.appendAndCreateBlob(items[i], opt_type));
|
| } else
|
| builder.push(items[i].value);
|
| }
|
| var options = {};
|
| - if (opt_ending)
|
| - options.endings = opt_ending;
|
| if (opt_type)
|
| options.type = opt_type;
|
| return new Blob(builder, options);
|
|
|