| Index: WebCore/bindings/v8/SerializedScriptValue.h
|
| ===================================================================
|
| --- WebCore/bindings/v8/SerializedScriptValue.h (revision 132804)
|
| +++ WebCore/bindings/v8/SerializedScriptValue.h (working copy)
|
| @@ -38,10 +38,12 @@
|
|
|
| namespace WebCore {
|
|
|
| +class BlobDataHandle;
|
| class MessagePort;
|
|
|
| typedef Vector<RefPtr<MessagePort>, 1> MessagePortArray;
|
| typedef Vector<RefPtr<WTF::ArrayBuffer>, 1> ArrayBufferArray;
|
| +typedef Vector<RefPtr<BlobDataHandle>, 1> BlobDataHandleArray;
|
|
|
| class SerializedScriptValue : public ThreadSafeRefCounted<SerializedScriptValue> {
|
| public:
|
| @@ -77,7 +79,7 @@
|
| ScriptValue deserializeForInspector(ScriptState*, v8::Isolate* = 0);
|
| #endif
|
|
|
| - const Vector<String>& blobURLs() const { return m_blobURLs; }
|
| + bool containsBlobs() const { return !m_blobDataHandles.isEmpty(); }
|
|
|
| // Informs the V8 about external memory allocated and owned by this object. Large values should contribute
|
| // to GC counters to eventually trigger a GC, otherwise flood of postMessage() can cause OOM.
|
| @@ -86,10 +88,6 @@
|
| void registerMemoryAllocatedWithCurrentScriptContext();
|
|
|
| private:
|
| - enum StringDataMode {
|
| - StringValue,
|
| - WireData
|
| - };
|
| typedef Vector<WTF::ArrayBufferContents, 1> ArrayBufferContentsArray;
|
|
|
| SerializedScriptValue();
|
| @@ -100,7 +98,7 @@
|
|
|
| String m_data;
|
| OwnPtr<ArrayBufferContentsArray> m_arrayBufferContentsArray;
|
| - Vector<String> m_blobURLs;
|
| + BlobDataHandleArray m_blobDataHandles; // TODO: Does this generalize better? SerializedScriptValue::ExtraData??
|
| intptr_t m_externallyAllocatedMemory;
|
| };
|
|
|
|
|