OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
3 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. | 3 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. |
4 * All rights reserved. | 4 * All rights reserved. |
5 * | 5 * |
6 * This library is free software; you can redistribute it and/or | 6 * This library is free software; you can redistribute it and/or |
7 * modify it under the terms of the GNU Library General Public | 7 * modify it under the terms of the GNU Library General Public |
8 * License as published by the Free Software Foundation; either | 8 * License as published by the Free Software Foundation; either |
9 * version 2 of the License, or (at your option) any later version. | 9 * version 2 of the License, or (at your option) any later version. |
10 * | 10 * |
(...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
181 | 181 |
182 void LayoutView::updateLogicalWidth() { | 182 void LayoutView::updateLogicalWidth() { |
183 setLogicalWidth(LayoutUnit(viewLogicalWidthForBoxSizing())); | 183 setLogicalWidth(LayoutUnit(viewLogicalWidthForBoxSizing())); |
184 } | 184 } |
185 | 185 |
186 bool LayoutView::isChildAllowed(LayoutObject* child, | 186 bool LayoutView::isChildAllowed(LayoutObject* child, |
187 const ComputedStyle&) const { | 187 const ComputedStyle&) const { |
188 return child->isBox(); | 188 return child->isBox(); |
189 } | 189 } |
190 | 190 |
| 191 bool LayoutView::canHaveChildren() const { |
| 192 FrameOwner* owner = frame()->owner(); |
| 193 if (!owner) |
| 194 return true; |
| 195 return !owner->isDisplayNone(); |
| 196 } |
| 197 |
191 void LayoutView::layoutContent() { | 198 void LayoutView::layoutContent() { |
192 ASSERT(needsLayout()); | 199 ASSERT(needsLayout()); |
193 | 200 |
194 LayoutBlockFlow::layout(); | 201 LayoutBlockFlow::layout(); |
195 | 202 |
196 #if ENABLE(ASSERT) | 203 #if ENABLE(ASSERT) |
197 checkLayoutState(); | 204 checkLayoutState(); |
198 #endif | 205 #endif |
199 } | 206 } |
200 | 207 |
(...skipping 839 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1040 if (block) | 1047 if (block) |
1041 block->adjustChildDebugRect(rect); | 1048 block->adjustChildDebugRect(rect); |
1042 | 1049 |
1043 rect.setWidth(LayoutUnit(viewWidth(IncludeScrollbars))); | 1050 rect.setWidth(LayoutUnit(viewWidth(IncludeScrollbars))); |
1044 rect.setHeight(LayoutUnit(viewHeight(IncludeScrollbars))); | 1051 rect.setHeight(LayoutUnit(viewHeight(IncludeScrollbars))); |
1045 | 1052 |
1046 return rect; | 1053 return rect; |
1047 } | 1054 } |
1048 | 1055 |
1049 } // namespace blink | 1056 } // namespace blink |
OLD | NEW |