Loading dom/base/ScreenOrientation.cpp +10 −3 Changes for dom/base/ScreenOrientation.cpp: 10 added lines, 3 removed lines. Original line number Diff line number Diff line Loading @@ -700,8 +700,11 @@ OrientationType ScreenOrientation::DeviceType(CallerType aCallerType) const { if (!bc) { return nsRFPService::GetDefaultOrientationType(); } if (bc->GetOrientationLock() == hal::ScreenOrientation::None) { CSSIntSize size = bc->TopInnerSizeSpoofedForRFP(); return nsRFPService::ViewportSizeToOrientationType(size.width, size.height); return nsRFPService::ViewportSizeToOrientationType(size.width, size.height); } } return mType; } Loading @@ -714,9 +717,11 @@ uint16_t ScreenOrientation::DeviceAngle(CallerType aCallerType) const { if (!bc) { return 0; } if (bc->GetOrientationLock() == hal::ScreenOrientation::None) { CSSIntSize size = bc->TopInnerSizeSpoofedForRFP(); return nsRFPService::ViewportSizeToAngle(size.width, size.height); } } return mAngle; } Loading @@ -731,7 +736,8 @@ OrientationType ScreenOrientation::GetType(CallerType aCallerType, OrientationType orientation = bc->GetCurrentOrientationType(); if (nsContentUtils::ShouldResistFingerprinting( aCallerType, GetRelevantGlobal(), RFPTarget::ScreenOrientation)) { aCallerType, GetRelevantGlobal(), RFPTarget::ScreenOrientation) && bc->GetOrientationLock() == hal::ScreenOrientation::None) { CSSIntSize size = bc->TopInnerSizeSpoofedForRFP(); return nsRFPService::ViewportSizeToOrientationType(size.width, size.height); } Loading @@ -749,7 +755,8 @@ uint16_t ScreenOrientation::GetAngle(CallerType aCallerType, uint16_t angle = static_cast<uint16_t>(bc->GetCurrentOrientationAngle()); if (nsContentUtils::ShouldResistFingerprinting( aCallerType, GetRelevantGlobal(), RFPTarget::ScreenOrientation)) { aCallerType, GetRelevantGlobal(), RFPTarget::ScreenOrientation) && bc->GetOrientationLock() == hal::ScreenOrientation::None) { CSSIntSize size = bc->TopInnerSizeSpoofedForRFP(); return nsRFPService::ViewportSizeToAngle(size.width, size.height); } Loading Loading
dom/base/ScreenOrientation.cpp +10 −3 Changes for dom/base/ScreenOrientation.cpp: 10 added lines, 3 removed lines. Original line number Diff line number Diff line Loading @@ -700,8 +700,11 @@ OrientationType ScreenOrientation::DeviceType(CallerType aCallerType) const { if (!bc) { return nsRFPService::GetDefaultOrientationType(); } if (bc->GetOrientationLock() == hal::ScreenOrientation::None) { CSSIntSize size = bc->TopInnerSizeSpoofedForRFP(); return nsRFPService::ViewportSizeToOrientationType(size.width, size.height); return nsRFPService::ViewportSizeToOrientationType(size.width, size.height); } } return mType; } Loading @@ -714,9 +717,11 @@ uint16_t ScreenOrientation::DeviceAngle(CallerType aCallerType) const { if (!bc) { return 0; } if (bc->GetOrientationLock() == hal::ScreenOrientation::None) { CSSIntSize size = bc->TopInnerSizeSpoofedForRFP(); return nsRFPService::ViewportSizeToAngle(size.width, size.height); } } return mAngle; } Loading @@ -731,7 +736,8 @@ OrientationType ScreenOrientation::GetType(CallerType aCallerType, OrientationType orientation = bc->GetCurrentOrientationType(); if (nsContentUtils::ShouldResistFingerprinting( aCallerType, GetRelevantGlobal(), RFPTarget::ScreenOrientation)) { aCallerType, GetRelevantGlobal(), RFPTarget::ScreenOrientation) && bc->GetOrientationLock() == hal::ScreenOrientation::None) { CSSIntSize size = bc->TopInnerSizeSpoofedForRFP(); return nsRFPService::ViewportSizeToOrientationType(size.width, size.height); } Loading @@ -749,7 +755,8 @@ uint16_t ScreenOrientation::GetAngle(CallerType aCallerType, uint16_t angle = static_cast<uint16_t>(bc->GetCurrentOrientationAngle()); if (nsContentUtils::ShouldResistFingerprinting( aCallerType, GetRelevantGlobal(), RFPTarget::ScreenOrientation)) { aCallerType, GetRelevantGlobal(), RFPTarget::ScreenOrientation) && bc->GetOrientationLock() == hal::ScreenOrientation::None) { CSSIntSize size = bc->TopInnerSizeSpoofedForRFP(); return nsRFPService::ViewportSizeToAngle(size.width, size.height); } Loading