зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1208023 - Avoid using a bad initial-scale when computing the CSS viewport. r=botond
--HG-- extra : commitid : bYtCKg4w35
This commit is contained in:
Родитель
5cf75acb53
Коммит
3b2d3a423c
|
@ -8050,7 +8050,7 @@ nsDocument::GetViewportInfo(const ScreenIntSize& aDisplaySize)
|
|||
|
||||
// We need to perform a conversion, but only if the initial or maximum
|
||||
// scale were set explicitly by the user.
|
||||
if (mValidScaleFloat) {
|
||||
if (mValidScaleFloat && scaleFloat >= scaleMinFloat && scaleFloat <= scaleMaxFloat) {
|
||||
CSSSize displaySize = ScreenSize(aDisplaySize) / scaleFloat;
|
||||
size.width = std::max(size.width, displaySize.width);
|
||||
size.height = std::max(size.height, displaySize.height);
|
||||
|
|
Загрузка…
Ссылка в новой задаче