diff options
Diffstat (limited to 'ipc/glue/UtilityAudioDecoderChild.h')
-rw-r--r-- | ipc/glue/UtilityAudioDecoderChild.h | 32 |
1 files changed, 3 insertions, 29 deletions
diff --git a/ipc/glue/UtilityAudioDecoderChild.h b/ipc/glue/UtilityAudioDecoderChild.h index 4e6a7792b0..0a27cb4ea3 100644 --- a/ipc/glue/UtilityAudioDecoderChild.h +++ b/ipc/glue/UtilityAudioDecoderChild.h @@ -58,32 +58,7 @@ class UtilityAudioDecoderChild final : public PUtilityAudioDecoderChild UtilityActorName GetActorName() { return GetAudioActorName(mSandbox); } - nsresult BindToUtilityProcess(RefPtr<UtilityProcessParent> aUtilityParent) { - Endpoint<PUtilityAudioDecoderChild> utilityAudioDecoderChildEnd; - Endpoint<PUtilityAudioDecoderParent> utilityAudioDecoderParentEnd; - nsresult rv = PUtilityAudioDecoder::CreateEndpoints( - aUtilityParent->OtherPid(), base::GetCurrentProcId(), - &utilityAudioDecoderParentEnd, &utilityAudioDecoderChildEnd); - - if (NS_FAILED(rv)) { - MOZ_ASSERT(false, "Protocol endpoints failure"); - return NS_ERROR_FAILURE; - } - - if (!aUtilityParent->SendStartUtilityAudioDecoderService( - std::move(utilityAudioDecoderParentEnd))) { - MOZ_ASSERT(false, "StartUtilityAudioDecoder service failure"); - return NS_ERROR_FAILURE; - } - - Bind(std::move(utilityAudioDecoderChildEnd)); - - PROFILER_MARKER_UNTYPED( - "UtilityAudioDecoderChild::BindToUtilityProcess", IPC, - MarkerOptions( - MarkerTiming::IntervalUntilNowFrom(mAudioDecoderChildStart))); - return NS_OK; - } + nsresult BindToUtilityProcess(RefPtr<UtilityProcessParent> aUtilityParent); void ActorDestroy(ActorDestroyReason aReason) override; @@ -96,8 +71,6 @@ class UtilityAudioDecoderChild final : public PUtilityAudioDecoderChild #ifdef MOZ_WMF_MEDIA_ENGINE mozilla::ipc::IPCResult RecvCompleteCreatedVideoBridge(); - bool HasCreatedVideoBridge() const; - void OnVarChanged(const gfx::GfxVarUpdate& aVar) override; void OnCompositorUnexpectedShutdown() override; @@ -120,7 +93,8 @@ class UtilityAudioDecoderChild final : public PUtilityAudioDecoderChild #ifdef MOZ_WMF_MEDIA_ENGINE // True if the utility process has created a video bridge with the GPU prcess. // Currently only used for media egine cdm. Main thread only. - bool mHasCreatedVideoBridge = false; + enum class State { None, Creating, Created }; + State mHasCreatedVideoBridge = State::None; #endif TimeStamp mAudioDecoderChildStart; |