diff --git a/mobile/chrome/content/browser.js b/mobile/chrome/content/browser.js index 6aa924ff4333..e5755fbd224d 100644 --- a/mobile/chrome/content/browser.js +++ b/mobile/chrome/content/browser.js @@ -2487,6 +2487,10 @@ Tab.prototype = { } else if (!validW && !validH) { viewportW = this.useFallbackWidth ? kFallbackBrowserWidth : kDefaultBrowserWidth; viewportH = kDefaultBrowserWidth * (screenH / screenW); + + // Make sure the viewport height is not shorter than the window when + // the page is zoomed out to show its full width. + viewportH = Math.max(viewportH, screenH * (browser.contentDocumentWidth / screenW)); } }