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

Unified Diff: third_party/WebKit/Source/core/layout/LayoutTableCell.cpp

Issue 1577433003: Statistics of LayoutBox rare data reasons Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: - Created 3 years, 9 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/layout/LayoutTableCell.cpp
diff --git a/third_party/WebKit/Source/core/layout/LayoutTableCell.cpp b/third_party/WebKit/Source/core/layout/LayoutTableCell.cpp
index f10f6cedcf210fca9c0f990dd5e8dff9d81ee92b..a5f0298eddf5b339b068d106d53b7d47eb966969 100644
--- a/third_party/WebKit/Source/core/layout/LayoutTableCell.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutTableCell.cpp
@@ -66,6 +66,7 @@ LayoutTableCell::LayoutTableCell(Element* element)
// colSpanOrRowSpanChanged() so we need to set their initial values here in
// case something asks for colSpan()/rowSpan() before then.
updateColAndRowSpanFlags();
+ m_rareStat.addReason(ReasonLTCAll);
}
LayoutTableCell::CollapsedBorderValues::CollapsedBorderValues(
@@ -1371,6 +1372,13 @@ void LayoutTableCell::collectBorderValues(
addBorderStyle(borderValues, newValues.endBorder());
addBorderStyle(borderValues, newValues.beforeBorder());
addBorderStyle(borderValues, newValues.afterBorder());
+
+ m_rareStat.addReason(ReasonLTCCollapsedBorders);
+ if (!newValues.startBorder().isVisible() &&
+ !newValues.endBorder().isVisible() &&
+ !newValues.beforeBorder().isVisible() &&
+ !newValues.afterBorder().isVisible())
+ m_rareStat.addReason(ReasonLTCInvisibleCollapsedBorders);
}
void LayoutTableCell::sortBorderValues(
« no previous file with comments | « third_party/WebKit/Source/core/layout/LayoutTable.cpp ('k') | third_party/WebKit/Source/core/layout/LayoutTableRow.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698