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

Side by Side Diff: third_party/WebKit/Source/core/frame/UseCounter.cpp

Issue 2804623002: [css-align] Implement place-self alignment shorthand (Closed)
Patch Set: Added a regression test. Created 3 years, 8 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
« no previous file with comments | « third_party/WebKit/Source/core/css/parser/CSSPropertyParser.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012 Google, Inc. All rights reserved. 2 * Copyright (C) 2012 Google, Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 28 matching lines...) Expand all
39 #include "platform/instrumentation/tracing/TraceEvent.h" 39 #include "platform/instrumentation/tracing/TraceEvent.h"
40 #include "platform/weborigin/SchemeRegistry.h" 40 #include "platform/weborigin/SchemeRegistry.h"
41 41
42 namespace { 42 namespace {
43 43
44 int totalPagesMeasuredCSSSampleId() { 44 int totalPagesMeasuredCSSSampleId() {
45 return 1; 45 return 1;
46 } 46 }
47 47
48 // Make sure update_use_counter_css.py was run which updates histograms.xml. 48 // Make sure update_use_counter_css.py was run which updates histograms.xml.
49 constexpr int kMaximumCSSSampleId = 559; 49 constexpr int kMaximumCSSSampleId = 560;
50 50
51 } // namespace 51 } // namespace
52 52
53 namespace blink { 53 namespace blink {
54 54
55 int UseCounter::mapCSSPropertyIdToCSSSampleIdForHistogram( 55 int UseCounter::mapCSSPropertyIdToCSSSampleIdForHistogram(
56 CSSPropertyID cssPropertyID) { 56 CSSPropertyID cssPropertyID) {
57 switch (cssPropertyID) { 57 switch (cssPropertyID) {
58 // Begin at 2, because 1 is reserved for totalPagesMeasuredCSSSampleId. 58 // Begin at 2, because 1 is reserved for totalPagesMeasuredCSSSampleId.
59 case CSSPropertyColor: 59 case CSSPropertyColor:
(...skipping 1020 matching lines...) Expand 10 before | Expand all | Expand 10 after
1080 case CSSPropertyMaxBlockSize: 1080 case CSSPropertyMaxBlockSize:
1081 return 555; 1081 return 555;
1082 case CSSPropertyAliasLineBreak: 1082 case CSSPropertyAliasLineBreak:
1083 return 556; 1083 return 556;
1084 case CSSPropertyPlaceContent: 1084 case CSSPropertyPlaceContent:
1085 return 557; 1085 return 557;
1086 case CSSPropertyPlaceItems: 1086 case CSSPropertyPlaceItems:
1087 return 558; 1087 return 558;
1088 case CSSPropertyTransformBox: 1088 case CSSPropertyTransformBox:
1089 return 559; 1089 return 559;
1090 case CSSPropertyPlaceSelf:
1091 return 560;
1090 // 1. Add new features above this line (don't change the assigned numbers of 1092 // 1. Add new features above this line (don't change the assigned numbers of
1091 // the existing items). 1093 // the existing items).
1092 // 2. Update kMaximumCSSSampleId with the new maximum value. 1094 // 2. Update kMaximumCSSSampleId with the new maximum value.
1093 // 3. Run the update_use_counter_css.py script in 1095 // 3. Run the update_use_counter_css.py script in
1094 // chromium/src/tools/metrics/histograms to update the UMA histogram names. 1096 // chromium/src/tools/metrics/histograms to update the UMA histogram names.
1095 1097
1096 case CSSPropertyInvalid: 1098 case CSSPropertyInvalid:
1097 ASSERT_NOT_REACHED(); 1099 ASSERT_NOT_REACHED();
1098 return 0; 1100 return 0;
1099 } 1101 }
(...skipping 313 matching lines...) Expand 10 before | Expand all | Expand 10 after
1413 } 1415 }
1414 } 1416 }
1415 1417
1416 if (needsPagesMeasuredUpdate) 1418 if (needsPagesMeasuredUpdate)
1417 cssPropertiesHistogram.count(totalPagesMeasuredCSSSampleId()); 1419 cssPropertiesHistogram.count(totalPagesMeasuredCSSSampleId());
1418 1420
1419 m_CSSBits.clearAll(); 1421 m_CSSBits.clearAll();
1420 } 1422 }
1421 1423
1422 } // namespace blink 1424 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/css/parser/CSSPropertyParser.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698