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) 2000 Dirk Mueller (mueller@kde.org) | 4 * (C) 2000 Dirk Mueller (mueller@kde.org) |
| 5 * (C) 2004 Allan Sandfeld Jensen (kde@carewolf.com) | 5 * (C) 2004 Allan Sandfeld Jensen (kde@carewolf.com) |
| 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2011 Apple Inc. | 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2011 Apple Inc. |
| 7 * All rights reserved. | 7 * All rights reserved. |
| 8 * Copyright (C) 2009 Google Inc. All rights reserved. | 8 * Copyright (C) 2009 Google Inc. All rights reserved. |
| 9 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. | 9 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. |
| 10 * (http://www.torchmobile.com/) | 10 * (http://www.torchmobile.com/) |
| (...skipping 2055 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 2066 IntPoint centerPoint = roundedIntPoint(transformState.mappedPoint()); | 2066 IntPoint centerPoint = roundedIntPoint(transformState.mappedPoint()); |
| 2067 transformState.move(toLayoutBox(container)->flipForWritingMode( | 2067 transformState.move(toLayoutBox(container)->flipForWritingMode( |
| 2068 LayoutPoint(centerPoint)) - | 2068 LayoutPoint(centerPoint)) - |
| 2069 centerPoint); | 2069 centerPoint); |
| 2070 } | 2070 } |
| 2071 mode &= ~ApplyContainerFlip; | 2071 mode &= ~ApplyContainerFlip; |
| 2072 } | 2072 } |
| 2073 } | 2073 } |
| 2074 | 2074 |
| 2075 LayoutSize containerOffset = offsetFromContainer(container); | 2075 LayoutSize containerOffset = offsetFromContainer(container); |
| 2076 if (isBoxModelObject() && isStickyPositioned() && (mode & IgnoreSticky)) { | |
| 2077 containerOffset -= toLayoutBoxModelObject(this)->offsetForInFlowPosition(); | |
|
flackr
2017/01/31 18:33:00
It is a little unfortunate to calculate this offse
smcgruer
2017/01/31 20:42:16
Done.
| |
| 2078 } | |
| 2079 | |
| 2076 if (isLayoutFlowThread()) { | 2080 if (isLayoutFlowThread()) { |
| 2077 // So far the point has been in flow thread coordinates (i.e. as if | 2081 // So far the point has been in flow thread coordinates (i.e. as if |
| 2078 // everything in the fragmentation context lived in one tall single column). | 2082 // everything in the fragmentation context lived in one tall single column). |
| 2079 // Convert it to a visual point now, since we're about to escape the flow | 2083 // Convert it to a visual point now, since we're about to escape the flow |
| 2080 // thread. | 2084 // thread. |
| 2081 containerOffset += columnOffset(LayoutPoint(transformState.mappedPoint())); | 2085 containerOffset += columnOffset(LayoutPoint(transformState.mappedPoint())); |
| 2082 } | 2086 } |
| 2083 | 2087 |
| 2084 // Text objects just copy their parent's computed style, so we need to ignore | 2088 // Text objects just copy their parent's computed style, so we need to ignore |
| 2085 // them. | 2089 // them. |
| (...skipping 1406 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 3492 const blink::LayoutObject* root = object1; | 3496 const blink::LayoutObject* root = object1; |
| 3493 while (root->parent()) | 3497 while (root->parent()) |
| 3494 root = root->parent(); | 3498 root = root->parent(); |
| 3495 root->showLayoutTreeAndMark(object1, "*", object2, "-", 0); | 3499 root->showLayoutTreeAndMark(object1, "*", object2, "-", 0); |
| 3496 } else { | 3500 } else { |
| 3497 WTFLogAlways("%s", "Cannot showLayoutTree. Root is (nil)"); | 3501 WTFLogAlways("%s", "Cannot showLayoutTree. Root is (nil)"); |
| 3498 } | 3502 } |
| 3499 } | 3503 } |
| 3500 | 3504 |
| 3501 #endif | 3505 #endif |
| OLD | NEW |