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

Side by Side Diff: third_party/WebKit/Source/core/layout/LayoutBlockFlow.cpp

Issue 2828453002: Add NeedsPreferredWidthsRecalculation() for block (Closed)
Patch Set: Make inline-block container's width update 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/LayoutTests/fast/inline-block/inline-block-update-width-expected.txt ('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) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 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 are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 2920 matching lines...) Expand 10 before | Expand all | Expand 10 after
2931 } 2931 }
2932 } 2932 }
2933 2933
2934 void LayoutBlockFlow::UpdateBlockChildDirtyBitsBeforeLayout( 2934 void LayoutBlockFlow::UpdateBlockChildDirtyBitsBeforeLayout(
2935 bool relayout_children, 2935 bool relayout_children,
2936 LayoutBox& child) { 2936 LayoutBox& child) {
2937 if (child.IsLayoutMultiColumnSpannerPlaceholder()) 2937 if (child.IsLayoutMultiColumnSpannerPlaceholder())
2938 ToLayoutMultiColumnSpannerPlaceholder(child) 2938 ToLayoutMultiColumnSpannerPlaceholder(child)
2939 .MarkForLayoutIfObjectInFlowThreadNeedsLayout(); 2939 .MarkForLayoutIfObjectInFlowThreadNeedsLayout();
2940 LayoutBlock::UpdateBlockChildDirtyBitsBeforeLayout(relayout_children, child); 2940 LayoutBlock::UpdateBlockChildDirtyBitsBeforeLayout(relayout_children, child);
2941 if (child.PreferredLogicalWidthsDirty() && IsInlineBlockOrInlineTable())
2942 child.SetPreferredLogicalWidthsDirty(kMarkContainerChain);
rhogan 2017/04/18 18:46:30 If someone called SetPreferredLogicalWidthsDirty o
2941 } 2943 }
2942 2944
2943 void LayoutBlockFlow::UpdateStaticInlinePositionForChild( 2945 void LayoutBlockFlow::UpdateStaticInlinePositionForChild(
2944 LayoutBox& child, 2946 LayoutBox& child,
2945 LayoutUnit logical_top, 2947 LayoutUnit logical_top,
2946 IndentTextOrNot indent_text) { 2948 IndentTextOrNot indent_text) {
2947 if (child.Style()->IsOriginalDisplayInlineType()) 2949 if (child.Style()->IsOriginalDisplayInlineType())
2948 SetStaticInlinePositionForChild( 2950 SetStaticInlinePositionForChild(
2949 child, StartAlignedOffsetForLine(logical_top, indent_text)); 2951 child, StartAlignedOffsetForLine(logical_top, indent_text));
2950 else 2952 else
(...skipping 1704 matching lines...) Expand 10 before | Expand all | Expand 10 after
4655 return LayoutBlock::InvalidatePaintIfNeeded(paint_invalidation_state); 4657 return LayoutBlock::InvalidatePaintIfNeeded(paint_invalidation_state);
4656 } 4658 }
4657 4659
4658 void LayoutBlockFlow::InvalidateDisplayItemClients( 4660 void LayoutBlockFlow::InvalidateDisplayItemClients(
4659 PaintInvalidationReason invalidation_reason) const { 4661 PaintInvalidationReason invalidation_reason) const {
4660 BlockFlowPaintInvalidator(*this).InvalidateDisplayItemClients( 4662 BlockFlowPaintInvalidator(*this).InvalidateDisplayItemClients(
4661 invalidation_reason); 4663 invalidation_reason);
4662 } 4664 }
4663 4665
4664 } // namespace blink 4666 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/LayoutTests/fast/inline-block/inline-block-update-width-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698