#include "core/dom/ViewportDescription.h"
#include "core/page/PageScaleConstraints.h"
+#include "platform/Length.h"
#include "platform/geometry/IntSize.h"
namespace blink {
// Settings defined in the website's viewport tag, if viewport tag support
// is enabled.
const WebCore::PageScaleConstraints& pageDefinedConstraints() const { return m_pageDefinedConstraints; }
- void updatePageDefinedConstraints(const WebCore::ViewportDescription&, WebCore::IntSize viewSize);
- void adjustForAndroidWebViewQuirks(const WebCore::ViewportDescription&, WebCore::IntSize viewSize, int layoutFallbackWidth, float deviceScaleFactor, bool supportTargetDensityDPI, bool wideViewportQuirkEnabled, bool useWideViewport, bool loadWithOverviewMode, bool nonUserScalableQuirkEnabled);
+ void updatePageDefinedConstraints(const WebCore::ViewportDescription&, WebCore::Length legacyFallbackWidth);
+ void adjustForAndroidWebViewQuirks(const WebCore::ViewportDescription&, int layoutFallbackWidth, float deviceScaleFactor, bool supportTargetDensityDPI, bool wideViewportQuirkEnabled, bool useWideViewport, bool loadWithOverviewMode, bool nonUserScalableQuirkEnabled);
// Constraints may also be set from Chromium -- this overrides any
// page-defined values.
// viewport size and document width.
const WebCore::PageScaleConstraints& finalConstraints() const { return m_finalConstraints; }
void computeFinalConstraints();
- void adjustFinalConstraintsToContentsSize(WebCore::IntSize viewSize, WebCore::IntSize contentsSize, int nonOverlayScrollbarWidth);
+ void adjustFinalConstraintsToContentsSize(WebCore::IntSize contentsSize, int nonOverlayScrollbarWidth);
void didChangeContentsSize(WebCore::IntSize contentsSize, float pageScaleFactor);
// This is set when one of the inputs to finalConstraints changes.
bool constraintsDirty() const { return m_constraintsDirty; }
+ void didChangeViewSize(const WebCore::IntSize&);
+
+ WebCore::IntSize mainFrameSize(const WebCore::IntSize& contentsSize) const;
+
private:
WebCore::PageScaleConstraints computeConstraintsStack() const;
WebCore::PageScaleConstraints m_finalConstraints;
int m_lastContentsWidth;
+ WebCore::IntSize m_viewSize;
bool m_needsReset;
bool m_constraintsDirty;