From de9c37513506b506ada782e85ff996d880744ce4 Mon Sep 17 00:00:00 2001 From: David Zbarsky Date: Wed, 10 Jul 2013 13:07:51 -0400 Subject: [PATCH] Bug 879475 - Move some blob constructor params to ipdlh headers r=jlebar --- dom/ipc/DOMTypes.ipdlh | 34 ++++++++++++++++++++++++++++++++++ dom/ipc/PContent.ipdl | 34 +--------------------------------- 2 files changed, 35 insertions(+), 33 deletions(-) diff --git a/dom/ipc/DOMTypes.ipdlh b/dom/ipc/DOMTypes.ipdlh index bdefa09e12f3..7087997b9aa8 100644 --- a/dom/ipc/DOMTypes.ipdlh +++ b/dom/ipc/DOMTypes.ipdlh @@ -5,6 +5,7 @@ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ include protocol PBlob; +include InputStreamParams; using mozilla::SerializedStructuredCloneBuffer; @@ -31,5 +32,38 @@ struct FileBlobConstructorParams uint64_t modDate; }; +struct SlicedBlobConstructorParams +{ + PBlob source; + uint64_t begin; + uint64_t end; + nsString contentType; +}; + +struct MysteryBlobConstructorParams +{ + // Nothing is known about this type of blob. +}; + +union ChildBlobConstructorParams +{ + NormalBlobConstructorParams; + FileBlobConstructorParams; + SlicedBlobConstructorParams; + MysteryBlobConstructorParams; +}; + +struct ParentBlobConstructorParams +{ + ChildBlobConstructorParams blobParams; + OptionalInputStreamParams optionalInputStreamParams; +}; + +union BlobConstructorParams +{ + ChildBlobConstructorParams; + ParentBlobConstructorParams; +}; + } // namespace dom } // namespace mozilla diff --git a/dom/ipc/PContent.ipdl b/dom/ipc/PContent.ipdl index 38985891f71c..faac1357685c 100644 --- a/dom/ipc/PContent.ipdl +++ b/dom/ipc/PContent.ipdl @@ -46,6 +46,7 @@ using IPC::Principal; using mozilla::null_t; using mozilla::void_t; using mozilla::dom::AudioChannelType; +using mozilla::dom::BlobConstructorParams; using mozilla::dom::NativeThreadId; using mozilla::hal::ProcessPriority; using gfxIntSize; @@ -123,39 +124,6 @@ union DeviceStorageParams DeviceStorageAvailableParams; }; -struct SlicedBlobConstructorParams -{ - PBlob source; - uint64_t begin; - uint64_t end; - nsString contentType; -}; - -struct MysteryBlobConstructorParams -{ - // Nothing is known about this type of blob. -}; - -union ChildBlobConstructorParams -{ - NormalBlobConstructorParams; - FileBlobConstructorParams; - SlicedBlobConstructorParams; - MysteryBlobConstructorParams; -}; - -struct ParentBlobConstructorParams -{ - ChildBlobConstructorParams blobParams; - OptionalInputStreamParams optionalInputStreamParams; -}; - -union BlobConstructorParams -{ - ChildBlobConstructorParams; - ParentBlobConstructorParams; -}; - union PrefValue { nsCString; int32_t;