Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(312)

Side by Side Diff: third_party/WebKit/Source/core/css/properties/CSSPropertyAPIZoom.cpp

Issue 2689063002: Deprecate CSS values zoom:reset and zoom:document. (Closed)
Patch Set: add test for deprecated properties Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "core/css/properties/CSSPropertyAPIZoom.h" 5 #include "core/css/properties/CSSPropertyAPIZoom.h"
6 6
7 #include "core/css/parser/CSSParserContext.h" 7 #include "core/css/parser/CSSParserContext.h"
8 #include "core/css/parser/CSSPropertyParserHelpers.h" 8 #include "core/css/parser/CSSPropertyParserHelpers.h"
9 #include "core/frame/UseCounter.h" 9 #include "core/frame/UseCounter.h"
10 10
(...skipping 16 matching lines...) Expand all
27 } 27 }
28 } 28 }
29 if (zoom) { 29 if (zoom) {
30 if (!(token.id() == CSSValueNormal || 30 if (!(token.id() == CSSValueNormal ||
31 (token.type() == NumberToken && 31 (token.type() == NumberToken &&
32 toCSSPrimitiveValue(zoom)->getDoubleValue() == 1) || 32 toCSSPrimitiveValue(zoom)->getDoubleValue() == 1) ||
33 (token.type() == PercentageToken && 33 (token.type() == PercentageToken &&
34 toCSSPrimitiveValue(zoom)->getDoubleValue() == 100))) 34 toCSSPrimitiveValue(zoom)->getDoubleValue() == 100)))
35 context->count(UseCounter::CSSZoomNotEqualToOne); 35 context->count(UseCounter::CSSZoomNotEqualToOne);
36 if (token.id() == CSSValueReset) 36 if (token.id() == CSSValueReset)
37 context->count(UseCounter::CSSZoomReset); 37 context->countDeprecation(UseCounter::CSSZoomReset);
38 if (token.id() == CSSValueDocument) 38 if (token.id() == CSSValueDocument)
39 context->count(UseCounter::CSSZoomDocument); 39 context->countDeprecation(UseCounter::CSSZoomDocument);
40 } 40 }
41 return zoom; 41 return zoom;
42 } 42 }
43 43
44 } // namespace blink 44 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698