OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (C) 2011 Apple Inc. All rights reserved. | 2 * Copyright (C) 2011 Apple 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 1090 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1101 return style()->isGridAutoFlowDirectionColumn() ? ForRows : ForColumns; | 1101 return style()->isGridAutoFlowDirectionColumn() ? ForRows : ForColumns; |
1102 } | 1102 } |
1103 | 1103 |
1104 void LayoutGrid::dirtyGrid() | 1104 void LayoutGrid::dirtyGrid() |
1105 { | 1105 { |
1106 // Even if this could be redundant, it could be seen as a defensive strategy against | 1106 // Even if this could be redundant, it could be seen as a defensive strategy against |
1107 // style changes events happening during the layout phase or even while the painting process | 1107 // style changes events happening during the layout phase or even while the painting process |
1108 // is still ongoing. | 1108 // is still ongoing. |
1109 // Forcing a new layout for the Grid render would cancel any ongoing paintin g and ensure | 1109 // Forcing a new layout for the Grid render would cancel any ongoing paintin g and ensure |
1110 // the grid and its children are correctly laid out according to the new sty le rules. | 1110 // the grid and its children are correctly laid out according to the new sty le rules. |
1111 setNeedsLayout(); | 1111 setNeedsLayout(LayoutInvalidationReason::Unknown); |
esprehn
2015/03/23 20:19:44
GridChanged ?
| |
1112 | 1112 |
1113 m_grid.resize(0); | 1113 m_grid.resize(0); |
1114 m_gridItemCoordinate.clear(); | 1114 m_gridItemCoordinate.clear(); |
1115 m_gridIsDirty = true; | 1115 m_gridIsDirty = true; |
1116 m_gridItemsOverflowingGridArea.resize(0); | 1116 m_gridItemsOverflowingGridArea.resize(0); |
1117 m_gridItemsIndexesMap.clear(); | 1117 m_gridItemsIndexesMap.clear(); |
1118 } | 1118 } |
1119 | 1119 |
1120 void LayoutGrid::layoutGridItems() | 1120 void LayoutGrid::layoutGridItems() |
1121 { | 1121 { |
(...skipping 643 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1765 if (isFloating()) | 1765 if (isFloating()) |
1766 return "LayoutGrid (floating)"; | 1766 return "LayoutGrid (floating)"; |
1767 if (isAnonymous()) | 1767 if (isAnonymous()) |
1768 return "LayoutGrid (anonymous)"; | 1768 return "LayoutGrid (anonymous)"; |
1769 if (isRelPositioned()) | 1769 if (isRelPositioned()) |
1770 return "LayoutGrid (relative positioned)"; | 1770 return "LayoutGrid (relative positioned)"; |
1771 return "LayoutGrid"; | 1771 return "LayoutGrid"; |
1772 } | 1772 } |
1773 | 1773 |
1774 } // namespace blink | 1774 } // namespace blink |
OLD | NEW |