| Index: Source/core/dom/ViewportArguments.h
|
| diff --git a/Source/core/dom/ViewportArguments.h b/Source/core/dom/ViewportArguments.h
|
| index 9eaf555e5f11781fda7cdec86be75e18f6bb4642..2b02b718905f82edc4dbb15f83860e23e8c5c975 100644
|
| --- a/Source/core/dom/ViewportArguments.h
|
| +++ b/Source/core/dom/ViewportArguments.h
|
| @@ -50,13 +50,11 @@ struct ViewportArguments {
|
|
|
| enum Type {
|
| // These are ordered in increasing importance.
|
| - Implicit,
|
| - XHTMLMobileProfile,
|
| + UserAgentStyleSheet,
|
| HandheldFriendlyMeta,
|
| MobileOptimizedMeta,
|
| ViewportMeta,
|
| - ViewportMetaLayoutSizeQuirk,
|
| - CSSDeviceAdaptation
|
| + AuthorStyleSheet
|
| } type;
|
|
|
| enum {
|
| @@ -72,10 +70,8 @@ struct ViewportArguments {
|
| ValueExtendToZoom = -10
|
| };
|
|
|
| - ViewportArguments(Type type = Implicit)
|
| + ViewportArguments(Type type = UserAgentStyleSheet)
|
| : type(type)
|
| - , width(ValueAuto)
|
| - , height(ValueAuto)
|
| , zoom(ValueAuto)
|
| , minZoom(ValueAuto)
|
| , maxZoom(ValueAuto)
|
| @@ -86,12 +82,10 @@ struct ViewportArguments {
|
| }
|
|
|
| // All arguments are in CSS units.
|
| - PageScaleConstraints resolve(const FloatSize& initialViewportSize, int defaultWidth) const;
|
| + PageScaleConstraints resolve(const FloatSize& initialViewportSize) const;
|
|
|
| - float width;
|
| Length minWidth;
|
| Length maxWidth;
|
| - float height;
|
| Length minHeight;
|
| Length maxHeight;
|
| float zoom;
|
| @@ -105,10 +99,8 @@ struct ViewportArguments {
|
| {
|
| // Used for figuring out whether to reset the viewport or not,
|
| // thus we are not taking type into account.
|
| - return width == other.width
|
| - && minWidth == other.minWidth
|
| + return minWidth == other.minWidth
|
| && maxWidth == other.maxWidth
|
| - && height == other.height
|
| && minHeight == other.minHeight
|
| && maxHeight == other.maxHeight
|
| && zoom == other.zoom
|
| @@ -124,6 +116,8 @@ struct ViewportArguments {
|
| return !(*this == other);
|
| }
|
|
|
| + bool isLegacyViewportType() const { return type >= HandheldFriendlyMeta && type <= ViewportMeta; }
|
| +
|
| private:
|
| enum Direction { Horizontal, Vertical };
|
| static float resolveViewportLength(const Length&, const FloatSize& initialViewportSize, Direction);
|
|
|