1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* vim:set ts=2 sw=2 sts=2 et cindent: */
3 /* This Source Code Form is subject to the terms of the Mozilla Public
4 * License, v. 2.0. If a copy of the MPL was not distributed with this
5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
7 #ifndef mozilla_dom_MIDIManagerParent_h
8 #define mozilla_dom_MIDIManagerParent_h
10 #include "mozilla/dom/PMIDIManagerParent.h"
12 namespace mozilla::dom
{
15 * Actor implementation for the Parent (PBackground thread) side of MIDIManager
16 * (represented in DOM by MIDIAccess). Manages actor lifetime so that we know
17 * to shut down services when all MIDIManagers are gone.
20 class MIDIManagerParent final
: public PMIDIManagerParent
{
22 NS_INLINE_DECL_REFCOUNTING(MIDIManagerParent
);
23 MIDIManagerParent() = default;
24 mozilla::ipc::IPCResult
RecvShutdown();
26 void ActorDestroy(ActorDestroyReason aWhy
) override
;
29 ~MIDIManagerParent() = default;
32 } // namespace mozilla::dom
34 #endif // mozilla_dom_MIDIManagerParent_h