OLD | NEW |
---|---|
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 412 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
423 bool heightChanged = (previousHeight != newHeight); | 423 bool heightChanged = (previousHeight != newHeight); |
424 if (heightChanged) | 424 if (heightChanged) |
425 relayoutChildren = true; | 425 relayoutChildren = true; |
426 | 426 |
427 layoutPositionedObjects(relayoutChildren || isDocumentElement(), oldLeft != logicalLeft() ? ForcedLayoutAfterContainingBlockMoved : DefaultLayout); | 427 layoutPositionedObjects(relayoutChildren || isDocumentElement(), oldLeft != logicalLeft() ? ForcedLayoutAfterContainingBlockMoved : DefaultLayout); |
428 | 428 |
429 // Add overflow from children (unless we're multi-column, since in that case all our child overflow is clipped anyway). | 429 // Add overflow from children (unless we're multi-column, since in that case all our child overflow is clipped anyway). |
430 computeOverflow(oldClientAfterEdge); | 430 computeOverflow(oldClientAfterEdge); |
431 | 431 |
432 m_descendantsWithFloatsMarkedForLayout = false; | 432 m_descendantsWithFloatsMarkedForLayout = false; |
433 m_heightAvailableToChildrenChanged = false; | |
mstensho (USE GERRIT)
2016/02/17 10:19:42
So we'll only reset this flag for LayoutBlockFlow,
| |
433 return true; | 434 return true; |
434 } | 435 } |
435 | 436 |
436 void LayoutBlockFlow::addLowestFloatFromChildren(LayoutBlockFlow* block) | 437 void LayoutBlockFlow::addLowestFloatFromChildren(LayoutBlockFlow* block) |
437 { | 438 { |
438 // TODO(robhogan): Make createsNewFormattingContext an ASSERT. | 439 // TODO(robhogan): Make createsNewFormattingContext an ASSERT. |
439 if (!block || !block->containsFloats() || block->createsNewFormattingContext ()) | 440 if (!block || !block->containsFloats() || block->createsNewFormattingContext ()) |
440 return; | 441 return; |
441 | 442 |
442 FloatingObject* floatingObject = block->m_floatingObjects->lowestFloatingObj ect(); | 443 FloatingObject* floatingObject = block->m_floatingObjects->lowestFloatingObj ect(); |
(...skipping 2415 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2858 FrameView* frameView = document().view(); | 2859 FrameView* frameView = document().view(); |
2859 LayoutUnit top = LayoutUnit((style()->position() == FixedPosition) ? 0 : fra meView->scrollOffset().height()); | 2860 LayoutUnit top = LayoutUnit((style()->position() == FixedPosition) ? 0 : fra meView->scrollOffset().height()); |
2860 int visibleHeight = frameView->visibleContentRect(IncludeScrollbars).height( ); | 2861 int visibleHeight = frameView->visibleContentRect(IncludeScrollbars).height( ); |
2861 if (size().height() < visibleHeight) | 2862 if (size().height() < visibleHeight) |
2862 top += (visibleHeight - size().height()) / 2; | 2863 top += (visibleHeight - size().height()) / 2; |
2863 setY(top); | 2864 setY(top); |
2864 dialog->setCentered(top); | 2865 dialog->setCentered(top); |
2865 } | 2866 } |
2866 | 2867 |
2867 } // namespace blink | 2868 } // namespace blink |
OLD | NEW |