Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org) |
| 3 * (C) 2000 Antti Koivisto (koivisto@kde.org) | 3 * (C) 2000 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) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2012 Apple Inc. All r ights reserved. | 6 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2012 Apple Inc. All r ights reserved. |
| 7 * Copyright (C) 2009 Google Inc. All rights reserved. | 7 * Copyright (C) 2009 Google Inc. All rights reserved. |
| 8 * | 8 * |
| 9 * This library is free software; you can redistribute it and/or | 9 * This library is free software; you can redistribute it and/or |
| 10 * modify it under the terms of the GNU Library General Public | 10 * modify it under the terms of the GNU Library General Public |
| (...skipping 963 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 974 // If the LayoutBoxModelObject ancestor is non-null, the input quad is in th e space of the ancestor. | 974 // If the LayoutBoxModelObject ancestor is non-null, the input quad is in th e space of the ancestor. |
| 975 // Otherwise: | 975 // Otherwise: |
| 976 // If TraverseDocumentBoundaries is specified, the input quad is in the sp ace of the local root frame. | 976 // If TraverseDocumentBoundaries is specified, the input quad is in the sp ace of the local root frame. |
| 977 // Otherwise, the input quad is in the space of the containing frame. | 977 // Otherwise, the input quad is in the space of the containing frame. |
| 978 FloatQuad ancestorToLocalQuad(LayoutBoxModelObject*, const FloatQuad&, MapCo ordinatesFlags mode = 0) const; | 978 FloatQuad ancestorToLocalQuad(LayoutBoxModelObject*, const FloatQuad&, MapCo ordinatesFlags mode = 0) const; |
| 979 FloatQuad absoluteToLocalQuad(const FloatQuad& quad, MapCoordinatesFlags mod e = 0) const | 979 FloatQuad absoluteToLocalQuad(const FloatQuad& quad, MapCoordinatesFlags mod e = 0) const |
| 980 { | 980 { |
| 981 return ancestorToLocalQuad(nullptr, quad, mode); | 981 return ancestorToLocalQuad(nullptr, quad, mode); |
| 982 } | 982 } |
| 983 | 983 |
| 984 // Convert a local quad into the coordinate system of container, taking tran sforms into account. | 984 // Convert a local quad into the coordinate system of container, taking tran sforms into account. |
|
chrishtr
2016/03/10 16:53:38
Copy the comment from ancestorToLocalQuad regardin
dmazzoni
2016/03/14 20:10:37
Done.
| |
| 985 FloatQuad localToAncestorQuad(const FloatQuad&, const LayoutBoxModelObject* ancestor, MapCoordinatesFlags = 0, bool* wasFixed = nullptr) const; | 985 FloatQuad localToAncestorQuad(const FloatQuad&, const LayoutBoxModelObject* ancestor, MapCoordinatesFlags = 0, bool* wasFixed = nullptr) const; |
| 986 FloatPoint localToAncestorPoint(const FloatPoint&, const LayoutBoxModelObjec t* ancestor, MapCoordinatesFlags = 0, bool* wasFixed = nullptr, const PaintInval idationState* = nullptr) const; | 986 FloatPoint localToAncestorPoint(const FloatPoint&, const LayoutBoxModelObjec t* ancestor, MapCoordinatesFlags = 0, bool* wasFixed = nullptr, const PaintInval idationState* = nullptr) const; |
| 987 void localToAncestorRects(Vector<LayoutRect>&, const LayoutBoxModelObject* a ncestor, const LayoutPoint& preOffset, const LayoutPoint& postOffset) const; | 987 void localToAncestorRects(Vector<LayoutRect>&, const LayoutBoxModelObject* a ncestor, const LayoutPoint& preOffset, const LayoutPoint& postOffset) const; |
| 988 | 988 |
| 989 // Return the transformation matrix to map points from local to the coordina te system of a container, taking transforms into account. | |
| 990 TransformationMatrix localToAncestorTransform(const LayoutBoxModelObject* an cestor, MapCoordinatesFlags = 0, bool* wasFixed = nullptr) const; | |
| 991 TransformationMatrix localToAbsoluteTransform(MapCoordinatesFlags mode = 0, bool* wasFixed = nullptr) const | |
| 992 { | |
| 993 return localToAncestorTransform(nullptr, mode, wasFixed); | |
| 994 } | |
| 995 | |
| 989 // Convert a local point into the coordinate system of backing coordinates. Also returns the backing layer if needed. | 996 // Convert a local point into the coordinate system of backing coordinates. Also returns the backing layer if needed. |
| 990 FloatPoint localToInvalidationBackingPoint(const LayoutPoint&, PaintLayer** backingLayer = nullptr); | 997 FloatPoint localToInvalidationBackingPoint(const LayoutPoint&, PaintLayer** backingLayer = nullptr); |
| 991 | 998 |
| 992 // Return the offset from the container() layoutObject (excluding transforms ). In multi-column layout, | 999 // Return the offset from the container() layoutObject (excluding transforms ). In multi-column layout, |
| 993 // different offsets apply at different points, so return the offset that ap plies to the given point. | 1000 // different offsets apply at different points, so return the offset that ap plies to the given point. |
| 994 virtual LayoutSize offsetFromContainer(const LayoutObject*, const LayoutPoin t&, bool* offsetDependsOnPoint = nullptr) const; | 1001 virtual LayoutSize offsetFromContainer(const LayoutObject*, const LayoutPoin t&, bool* offsetDependsOnPoint = nullptr) const; |
| 995 // Return the offset from an object up the container() chain. Asserts that n one of the intermediate objects have transforms. | 1002 // Return the offset from an object up the container() chain. Asserts that n one of the intermediate objects have transforms. |
| 996 LayoutSize offsetFromAncestorContainer(const LayoutObject*) const; | 1003 LayoutSize offsetFromAncestorContainer(const LayoutObject*) const; |
| 997 | 1004 |
| 998 virtual void absoluteRects(Vector<IntRect>&, const LayoutPoint&) const { } | 1005 virtual void absoluteRects(Vector<IntRect>&, const LayoutPoint&) const { } |
| (...skipping 1151 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 2150 void showTree(const blink::LayoutObject*); | 2157 void showTree(const blink::LayoutObject*); |
| 2151 void showLineTree(const blink::LayoutObject*); | 2158 void showLineTree(const blink::LayoutObject*); |
| 2152 void showLayoutTree(const blink::LayoutObject* object1); | 2159 void showLayoutTree(const blink::LayoutObject* object1); |
| 2153 // We don't make object2 an optional parameter so that showLayoutTree | 2160 // We don't make object2 an optional parameter so that showLayoutTree |
| 2154 // can be called from gdb easily. | 2161 // can be called from gdb easily. |
| 2155 void showLayoutTree(const blink::LayoutObject* object1, const blink::LayoutObjec t* object2); | 2162 void showLayoutTree(const blink::LayoutObject* object1, const blink::LayoutObjec t* object2); |
| 2156 | 2163 |
| 2157 #endif | 2164 #endif |
| 2158 | 2165 |
| 2159 #endif // LayoutObject_h | 2166 #endif // LayoutObject_h |
| OLD | NEW |