зеркало из https://github.com/mozilla/gecko-dev.git
bug 1088758 - Add the ability to mirror tabs from desktop to a second screen, restrict privledged GuM based on calling compartment rather than passed window's document r=rjesup
This commit is contained in:
Родитель
a71f6ccb8c
Коммит
a6571098ba
|
@ -1580,7 +1580,7 @@ MediaManager::GetUserMedia(
|
|||
NS_ENSURE_TRUE(aOnFailure, NS_ERROR_NULL_POINTER);
|
||||
NS_ENSURE_TRUE(aOnSuccess, NS_ERROR_NULL_POINTER);
|
||||
|
||||
bool privileged = nsContentUtils::IsChromeDoc(aWindow->GetExtantDoc());
|
||||
bool privileged = nsContentUtils::IsCallerChrome();
|
||||
|
||||
nsCOMPtr<nsIDOMGetUserMediaSuccessCallback> onSuccess(aOnSuccess);
|
||||
nsCOMPtr<nsIDOMGetUserMediaErrorCallback> onFailure(aOnFailure);
|
||||
|
|
|
@ -713,6 +713,7 @@ SpeechRecognition::Start(const Optional<NonNull<DOMMediaStream>>& aStream, Error
|
|||
if (aStream.WasPassed()) {
|
||||
StartRecording(&aStream.Value());
|
||||
} else {
|
||||
AutoNoJSAPI();
|
||||
MediaManager* manager = MediaManager::Get();
|
||||
manager->GetUserMedia(GetOwner(),
|
||||
constraints,
|
||||
|
|
Загрузка…
Ссылка в новой задаче