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 Apple Inc. All r
ights reserved. | 5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All r
ights reserved. |
6 * | 6 * |
7 * This library is free software; you can redistribute it and/or | 7 * This library is free software; you can redistribute it and/or |
8 * modify it under the terms of the GNU Library General Public | 8 * modify it under the terms of the GNU Library General Public |
9 * License as published by the Free Software Foundation; either | 9 * License as published by the Free Software Foundation; either |
10 * version 2 of the License, or (at your option) any later version. | 10 * version 2 of the License, or (at your option) any later version. |
(...skipping 1173 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1184 | 1184 |
1185 // When computing the offset caused by the floats on a given line, if | 1185 // When computing the offset caused by the floats on a given line, if |
1186 // the outermost float on that line has a shape-outside, the inline | 1186 // the outermost float on that line has a shape-outside, the inline |
1187 // content that butts up against that float must be positioned using | 1187 // content that butts up against that float must be positioned using |
1188 // the contours of the shape, not the margin box of the float. | 1188 // the contours of the shape, not the margin box of the float. |
1189 // We save the last float encountered so that the offset can be | 1189 // We save the last float encountered so that the offset can be |
1190 // computed correctly by the code using this adapter. | 1190 // computed correctly by the code using this adapter. |
1191 const FloatingObject* lastFloat() const { return m_last; } | 1191 const FloatingObject* lastFloat() const { return m_last; } |
1192 | 1192 |
1193 private: | 1193 private: |
| 1194 bool updateOffsetIfNeeded(const FloatingObject*) const; |
| 1195 |
1194 const RenderBlock* m_renderer; | 1196 const RenderBlock* m_renderer; |
1195 int m_lowValue; | 1197 int m_lowValue; |
1196 int m_highValue; | 1198 int m_highValue; |
1197 LayoutUnit& m_offset; | 1199 LayoutUnit& m_offset; |
1198 LayoutUnit* m_heightRemaining; | 1200 LayoutUnit* m_heightRemaining; |
1199 // This member variable is mutable because the collectIfNeeded method | 1201 // This member variable is mutable because the collectIfNeeded method |
1200 // is declared as const, even though it doesn't actually respect that | 1202 // is declared as const, even though it doesn't actually respect that |
1201 // contract. It modifies other member variables via loopholes in the | 1203 // contract. It modifies other member variables via loopholes in the |
1202 // const behavior. Instead of using loopholes, I decided it was better | 1204 // const behavior. Instead of using loopholes, I decided it was better |
1203 // to make the fact that this is modified in a const method explicit. | 1205 // to make the fact that this is modified in a const method explicit. |
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1340 static String string(const int value); | 1342 static String string(const int value); |
1341 }; | 1343 }; |
1342 template<> struct ValueToString<RenderBlock::FloatingObject*> { | 1344 template<> struct ValueToString<RenderBlock::FloatingObject*> { |
1343 static String string(const RenderBlock::FloatingObject*); | 1345 static String string(const RenderBlock::FloatingObject*); |
1344 }; | 1346 }; |
1345 #endif | 1347 #endif |
1346 | 1348 |
1347 } // namespace WebCore | 1349 } // namespace WebCore |
1348 | 1350 |
1349 #endif // RenderBlock_h | 1351 #endif // RenderBlock_h |
OLD | NEW |