Index: third_party/WebKit/Source/core/streams/CountQueuingStrategy.js |
diff --git a/third_party/WebKit/Source/core/streams/ByteLengthQueuingStrategy.js b/third_party/WebKit/Source/core/streams/CountQueuingStrategy.js |
similarity index 55% |
copy from third_party/WebKit/Source/core/streams/ByteLengthQueuingStrategy.js |
copy to third_party/WebKit/Source/core/streams/CountQueuingStrategy.js |
index 5fdb7c99cb6be0b9c4a5d971c384ce8b81c6c486..61567c899512697bcc2a8ce65b931282974f0661 100644 |
--- a/third_party/WebKit/Source/core/streams/ByteLengthQueuingStrategy.js |
+++ b/third_party/WebKit/Source/core/streams/CountQueuingStrategy.js |
@@ -1,9 +1,13 @@ |
+// Copyright 2015 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
(function(global, binding, v8) { |
'use strict'; |
const defineProperty = global.Object.defineProperty; |
- class ByteLengthQueuingStrategy { |
+ class CountQueuingStrategy { |
constructor(options) { |
defineProperty(this, 'highWaterMark', { |
value: options.highWaterMark, |
@@ -12,11 +16,11 @@ |
writable: true |
}); |
} |
- size(chunk) { return chunk.byteLength; } |
+ size(chunk) { return 1; } |
} |
- defineProperty(global, 'ByteLengthQueuingStrategy', { |
- value: ByteLengthQueuingStrategy, |
+ defineProperty(global, 'CountQueuingStrategy', { |
+ value: CountQueuingStrategy, |
enumerable: false, |
configurable: true, |
writable: true |