| ... |
... |
@@ -1110,7 +1110,7 @@ JSObject* StructuredCloneHolder::CustomReadHandler( |
|
1110
|
1110
|
return ClonedErrorHolder::ReadStructuredClone(aCx, aReader, this);
|
|
1111
|
1111
|
}
|
|
1112
|
1112
|
|
|
1113
|
|
- if (VideoFrame::PrefEnabled() && aTag == SCTAG_DOM_VIDEOFRAME &&
|
|
|
1113
|
+ if (VideoFrame::PrefEnabled(aCx) && aTag == SCTAG_DOM_VIDEOFRAME &&
|
|
1114
|
1114
|
CloneScope() == StructuredCloneScope::SameProcess &&
|
|
1115
|
1115
|
aCloneDataPolicy.areIntraClusterClonableSharedObjectsAllowed()) {
|
|
1116
|
1116
|
JS::Rooted<JSObject*> global(aCx, mGlobal->GetGlobalJSObject());
|
| ... |
... |
@@ -1250,7 +1250,7 @@ bool StructuredCloneHolder::CustomWriteHandler( |
|
1250
|
1250
|
}
|
|
1251
|
1251
|
|
|
1252
|
1252
|
// See if this is a VideoFrame object.
|
|
1253
|
|
- if (VideoFrame::PrefEnabled()) {
|
|
|
1253
|
+ if (VideoFrame::PrefEnabled(aCx)) {
|
|
1254
|
1254
|
VideoFrame* videoFrame = nullptr;
|
|
1255
|
1255
|
if (NS_SUCCEEDED(UNWRAP_OBJECT(VideoFrame, &obj, videoFrame))) {
|
|
1256
|
1256
|
SameProcessScopeRequired(aSameProcessScopeRequired);
|
| ... |
... |
@@ -1446,7 +1446,7 @@ StructuredCloneHolder::CustomReadTransferHandler( |
|
1446
|
1446
|
aReturnObject);
|
|
1447
|
1447
|
}
|
|
1448
|
1448
|
|
|
1449
|
|
- if (VideoFrame::PrefEnabled() && aTag == SCTAG_DOM_VIDEOFRAME &&
|
|
|
1449
|
+ if (VideoFrame::PrefEnabled(aCx) && aTag == SCTAG_DOM_VIDEOFRAME &&
|
|
1450
|
1450
|
CloneScope() == StructuredCloneScope::SameProcess &&
|
|
1451
|
1451
|
aCloneDataPolicy.areIntraClusterClonableSharedObjectsAllowed()) {
|
|
1452
|
1452
|
MOZ_ASSERT(aContent);
|
| ... |
... |
@@ -1591,7 +1591,7 @@ StructuredCloneHolder::CustomWriteTransferHandler( |
|
1591
|
1591
|
return true;
|
|
1592
|
1592
|
}
|
|
1593
|
1593
|
|
|
1594
|
|
- if (VideoFrame::PrefEnabled()) {
|
|
|
1594
|
+ if (VideoFrame::PrefEnabled(aCx)) {
|
|
1595
|
1595
|
VideoFrame* videoFrame = nullptr;
|
|
1596
|
1596
|
rv = UNWRAP_OBJECT(VideoFrame, &obj, videoFrame);
|
|
1597
|
1597
|
if (NS_SUCCEEDED(rv)) {
|
| ... |
... |
@@ -1758,7 +1758,7 @@ void StructuredCloneHolder::CustomFreeTransferHandler( |
|
1758
|
1758
|
return;
|
|
1759
|
1759
|
}
|
|
1760
|
1760
|
|
|
1761
|
|
- if (VideoFrame::PrefEnabled() && aTag == SCTAG_DOM_VIDEOFRAME &&
|
|
|
1761
|
+ if (aTag == SCTAG_DOM_VIDEOFRAME &&
|
|
1762
|
1762
|
CloneScope() == StructuredCloneScope::SameProcess) {
|
|
1763
|
1763
|
if (aContent) {
|
|
1764
|
1764
|
VideoFrame::TransferredData* data =
|
| ... |
... |
@@ -1767,8 +1767,7 @@ void StructuredCloneHolder::CustomFreeTransferHandler( |
|
1767
|
1767
|
}
|
|
1768
|
1768
|
return;
|
|
1769
|
1769
|
}
|
|
1770
|
|
- if (StaticPrefs::dom_media_webcodecs_enabled() &&
|
|
1771
|
|
- aTag == SCTAG_DOM_AUDIODATA &&
|
|
|
1770
|
+ if (aTag == SCTAG_DOM_AUDIODATA &&
|
|
1772
|
1771
|
CloneScope() == StructuredCloneScope::SameProcess) {
|
|
1773
|
1772
|
if (aContent) {
|
|
1774
|
1773
|
AudioData::TransferredData* data =
|
| ... |
... |
@@ -1851,7 +1850,7 @@ bool StructuredCloneHolder::CustomCanTransferHandler( |
|
1851
|
1850
|
}
|
|
1852
|
1851
|
}
|
|
1853
|
1852
|
|
|
1854
|
|
- if (VideoFrame::PrefEnabled()) {
|
|
|
1853
|
+ if (VideoFrame::PrefEnabled(aCx)) {
|
|
1855
|
1854
|
VideoFrame* videoframe = nullptr;
|
|
1856
|
1855
|
nsresult rv = UNWRAP_OBJECT(VideoFrame, &obj, videoframe);
|
|
1857
|
1856
|
if (NS_SUCCEEDED(rv)) {
|