diff options
author | Moonchild <moonchild@palemoon.org> | 2022-04-05 17:00:28 +0200 |
---|---|---|
committer | Moonchild <moonchild@palemoon.org> | 2022-04-05 17:00:28 +0200 |
commit | 3b575dfced55cf78871937b6bd41942374c95390 (patch) | |
tree | a56f756f47a7ae3e45d66ccf02279ac2d22f0d1f /dom/base/nsDOMWindowUtils.cpp | |
parent | 0bc66e3b04e77af307b62371ae9f4be70b2b19b7 (diff) | |
download | uxp-3b575dfced55cf78871937b6bd41942374c95390.tar.gz |
Revert "Merge pull request 'Update libcubeb to latest version' (#1812) from athenian200/UXP:libcubeb_final into master"
This reverts commit 0bc66e3b04e77af307b62371ae9f4be70b2b19b7, reversing
changes made to 6e6b5d89964ea726b264c711bdf6f02fe0c006f5.
Diffstat (limited to 'dom/base/nsDOMWindowUtils.cpp')
-rw-r--r-- | dom/base/nsDOMWindowUtils.cpp | 41 |
1 files changed, 0 insertions, 41 deletions
diff --git a/dom/base/nsDOMWindowUtils.cpp b/dom/base/nsDOMWindowUtils.cpp index eb09a6f14f..d05f3b71fc 100644 --- a/dom/base/nsDOMWindowUtils.cpp +++ b/dom/base/nsDOMWindowUtils.cpp @@ -74,7 +74,6 @@ #include "Layers.h" #include "gfxPrefs.h" -#include "mozilla/dom/AudioDeviceInfo.h" #include "mozilla/dom/Element.h" #include "mozilla/dom/TabChild.h" #include "mozilla/dom/IDBFactoryBinding.h" @@ -2372,46 +2371,6 @@ nsDOMWindowUtils::GetCurrentAudioBackend(nsAString& aBackend) } NS_IMETHODIMP -nsDOMWindowUtils::GetCurrentMaxAudioChannels(uint32_t* aChannels) -{ - *aChannels = CubebUtils::MaxNumberOfChannels(); - return NS_OK; -} - -NS_IMETHODIMP -nsDOMWindowUtils::GetCurrentPreferredSampleRate(uint32_t* aRate) -{ - *aRate = CubebUtils::PreferredSampleRate(); - return NS_OK; -} - -NS_IMETHODIMP -nsDOMWindowUtils::AudioDevices(uint16_t aSide, nsIArray** aDevices) -{ - NS_ENSURE_ARG_POINTER(aDevices); - NS_ENSURE_ARG((aSide == AUDIO_INPUT) || (aSide == AUDIO_OUTPUT)); - *aDevices = nullptr; - - nsresult rv = NS_OK; - nsCOMPtr<nsIMutableArray> devices = - do_CreateInstance(NS_ARRAY_CONTRACTID, &rv); - NS_ENSURE_SUCCESS(rv, rv); - - nsTArray<RefPtr<AudioDeviceInfo>> collection; - CubebUtils::GetDeviceCollection(collection, - aSide == AUDIO_INPUT - ? CubebUtils::Side::Input - : CubebUtils::Side::Output); - for (auto device: collection) { - devices->AppendElement(device, false); - } - - devices.forget(aDevices); - - return NS_OK; -} - -NS_IMETHODIMP nsDOMWindowUtils::StartFrameTimeRecording(uint32_t *startIndex) { NS_ENSURE_ARG_POINTER(startIndex); |