зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1213517 - Fix static analysis for bug 1213517 landing: make constructor explicit. r=jesup
MozReview-Commit-ID: 6k38HgsFmL2 --HG-- extra : rebase_source : 47f1caa8cc7a39b1f4f49ae2c8744556122da45d
This commit is contained in:
Родитель
7949ae2a64
Коммит
aa375cbaab
|
@ -1347,11 +1347,11 @@ MediaManager::SelectSettings(
|
|||
|
||||
if (needVideo && videos.Length()) {
|
||||
badConstraint = MediaConstraintsHelper::SelectSettings(
|
||||
GetInvariant(aConstraints.mVideo), videos);
|
||||
NormalizedConstraints(GetInvariant(aConstraints.mVideo)), videos);
|
||||
}
|
||||
if (!badConstraint && needAudio && audios.Length()) {
|
||||
badConstraint = MediaConstraintsHelper::SelectSettings(
|
||||
GetInvariant(aConstraints.mAudio), audios);
|
||||
NormalizedConstraints(GetInvariant(aConstraints.mAudio)), audios);
|
||||
}
|
||||
if (!badConstraint &&
|
||||
!needVideo == !videos.Length() &&
|
||||
|
@ -1451,8 +1451,8 @@ public:
|
|||
if (rv == NS_ERROR_NOT_AVAILABLE && !badConstraint) {
|
||||
nsTArray<RefPtr<AudioDevice>> audios;
|
||||
audios.AppendElement(mAudioDevice);
|
||||
badConstraint = MediaConstraintsHelper::SelectSettings(constraints,
|
||||
audios);
|
||||
badConstraint = MediaConstraintsHelper::SelectSettings(
|
||||
NormalizedConstraints(constraints), audios);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1464,8 +1464,8 @@ public:
|
|||
if (rv == NS_ERROR_NOT_AVAILABLE && !badConstraint) {
|
||||
nsTArray<RefPtr<VideoDevice>> videos;
|
||||
videos.AppendElement(mVideoDevice);
|
||||
badConstraint = MediaConstraintsHelper::SelectSettings(constraints,
|
||||
videos);
|
||||
badConstraint = MediaConstraintsHelper::SelectSettings(
|
||||
NormalizedConstraints(constraints), videos);
|
||||
}
|
||||
if (mAudioDevice) {
|
||||
mAudioDevice->Deallocate();
|
||||
|
@ -3456,16 +3456,16 @@ GetUserMediaCallbackMediaStreamListener::ApplyConstraintsToTrack(
|
|||
if (rv == NS_ERROR_NOT_AVAILABLE && !badConstraint) {
|
||||
nsTArray<RefPtr<AudioDevice>> audios;
|
||||
audios.AppendElement(audioDevice);
|
||||
badConstraint = MediaConstraintsHelper::SelectSettings(aConstraints,
|
||||
audios);
|
||||
badConstraint = MediaConstraintsHelper::SelectSettings(
|
||||
NormalizedConstraints(aConstraints), audios);
|
||||
}
|
||||
} else {
|
||||
rv = videoDevice->Restart(aConstraints, mgr->mPrefs, &badConstraint);
|
||||
if (rv == NS_ERROR_NOT_AVAILABLE && !badConstraint) {
|
||||
nsTArray<RefPtr<VideoDevice>> videos;
|
||||
videos.AppendElement(videoDevice);
|
||||
badConstraint = MediaConstraintsHelper::SelectSettings(aConstraints,
|
||||
videos);
|
||||
badConstraint = MediaConstraintsHelper::SelectSettings(
|
||||
NormalizedConstraints(aConstraints), videos);
|
||||
}
|
||||
}
|
||||
NS_DispatchToMainThread(NewRunnableFrom([id, windowId, rv,
|
||||
|
|
|
@ -266,7 +266,7 @@ template<> void NormalizedConstraintSet::Range<bool>::FinalizeMerge();
|
|||
// Used instead of MediaTrackConstraints in lower-level code.
|
||||
struct NormalizedConstraints : public NormalizedConstraintSet
|
||||
{
|
||||
NormalizedConstraints(const dom::MediaTrackConstraints& aOther,
|
||||
explicit NormalizedConstraints(const dom::MediaTrackConstraints& aOther,
|
||||
nsTArray<MemberPtrType>* aList = nullptr);
|
||||
|
||||
// Merge constructor
|
||||
|
|
Загрузка…
Ссылка в новой задаче