Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
| 4 * (C) 2007 David Smith (catfish.man@gmail.com) | 4 * (C) 2007 David Smith (catfish.man@gmail.com) |
| 5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserved. | 5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserved. |
| 6 * Copyright (C) Research In Motion Limited 2010. All rights reserved. | 6 * Copyright (C) Research In Motion Limited 2010. All rights reserved. |
| 7 * | 7 * |
| 8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
| 9 * modify it under the terms of the GNU Library General Public | 9 * modify it under the terms of the GNU Library General Public |
| 10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
| (...skipping 338 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 349 if (TrackedLayoutBoxListHashSet* positionedObjects = this->positionedObjects ()) { | 349 if (TrackedLayoutBoxListHashSet* positionedObjects = this->positionedObjects ()) { |
| 350 for (auto* box : *positionedObjects) { | 350 for (auto* box : *positionedObjects) { |
| 351 | 351 |
| 352 // One of the layoutObjects we're skipping over here may be the chil d's paint invalidation container, | 352 // One of the layoutObjects we're skipping over here may be the chil d's paint invalidation container, |
| 353 // so we can't pass our own paint invalidation container along. | 353 // so we can't pass our own paint invalidation container along. |
| 354 const LayoutBoxModelObject& paintInvalidationContainerForChild = box ->containerForPaintInvalidation(); | 354 const LayoutBoxModelObject& paintInvalidationContainerForChild = box ->containerForPaintInvalidation(); |
| 355 | 355 |
| 356 // If it's a new paint invalidation container, we won't have properl y accumulated the offset into the | 356 // If it's a new paint invalidation container, we won't have properl y accumulated the offset into the |
| 357 // PaintInvalidationState. | 357 // PaintInvalidationState. |
| 358 // FIXME: Teach PaintInvalidationState to handle this case. crbug.co m/371485 | 358 // FIXME: Teach PaintInvalidationState to handle this case. crbug.co m/371485 |
| 359 if (paintInvalidationContainerForChild != childPaintInvalidationStat e.paintInvalidationContainer()) { | 359 if (&paintInvalidationContainerForChild != box && paintInvalidationC ontainerForChild != childPaintInvalidationState.paintInvalidationContainer()) { |
|
chrishtr
2016/03/11 22:11:44
Explain this in a comment also.
Xianzhu
2016/03/11 22:30:51
Done.
| |
| 360 ForceHorriblySlowRectMapping slowRectMapping(&childPaintInvalida tionState); | 360 ForceHorriblySlowRectMapping slowRectMapping(&childPaintInvalida tionState); |
| 361 PaintInvalidationState disabledPaintInvalidationState(childPaint InvalidationState, *this, paintInvalidationContainerForChild); | 361 PaintInvalidationState disabledPaintInvalidationState(childPaint InvalidationState, *this, paintInvalidationContainerForChild); |
| 362 box->invalidateTreeIfNeeded(disabledPaintInvalidationState); | 362 box->invalidateTreeIfNeeded(disabledPaintInvalidationState); |
| 363 continue; | 363 continue; |
| 364 } | 364 } |
| 365 | 365 |
| 366 // If the positioned layoutObject is absolutely positioned and it is inside | 366 // If the positioned layoutObject is absolutely positioned and it is inside |
| 367 // a relatively positioned inline element, we need to account for | 367 // a relatively positioned inline element, we need to account for |
| 368 // the inline elements position in PaintInvalidationState. | 368 // the inline elements position in PaintInvalidationState. |
| 369 if (box->style()->position() == AbsolutePosition) { | 369 if (box->style()->position() == AbsolutePosition) { |
| (...skipping 2485 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 2855 void LayoutBlock::showLineTreeAndMark(const InlineBox* markedBox1, const char* m arkedLabel1, const InlineBox* markedBox2, const char* markedLabel2, const Layout Object* obj) const | 2855 void LayoutBlock::showLineTreeAndMark(const InlineBox* markedBox1, const char* m arkedLabel1, const InlineBox* markedBox2, const char* markedLabel2, const Layout Object* obj) const |
| 2856 { | 2856 { |
| 2857 showLayoutObject(); | 2857 showLayoutObject(); |
| 2858 for (const RootInlineBox* root = firstRootBox(); root; root = root->nextRoot Box()) | 2858 for (const RootInlineBox* root = firstRootBox(); root; root = root->nextRoot Box()) |
| 2859 root->showLineTreeAndMark(markedBox1, markedLabel1, markedBox2, markedLa bel2, obj, 1); | 2859 root->showLineTreeAndMark(markedBox1, markedLabel1, markedBox2, markedLa bel2, obj, 1); |
| 2860 } | 2860 } |
| 2861 | 2861 |
| 2862 #endif | 2862 #endif |
| 2863 | 2863 |
| 2864 } // namespace blink | 2864 } // namespace blink |
| OLD | NEW |