| 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. All rights reserv
ed. | 3 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserv
ed. |
| 4 * | 4 * |
| 5 * This library is free software; you can redistribute it and/or | 5 * This library is free software; you can redistribute it and/or |
| 6 * modify it under the terms of the GNU Library General Public | 6 * modify it under the terms of the GNU Library General Public |
| 7 * License as published by the Free Software Foundation; either | 7 * License as published by the Free Software Foundation; either |
| 8 * version 2 of the License, or (at your option) any later version. | 8 * version 2 of the License, or (at your option) any later version. |
| 9 * | 9 * |
| 10 * This library is distributed in the hope that it will be useful, | 10 * This library is distributed in the hope that it will be useful, |
| (...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 184 LayoutState rootLayoutState(*this); | 184 LayoutState rootLayoutState(*this); |
| 185 | 185 |
| 186 layoutContent(); | 186 layoutContent(); |
| 187 | 187 |
| 188 #if ENABLE(ASSERT) | 188 #if ENABLE(ASSERT) |
| 189 checkLayoutState(); | 189 checkLayoutState(); |
| 190 #endif | 190 #endif |
| 191 clearNeedsLayout(); | 191 clearNeedsLayout(); |
| 192 } | 192 } |
| 193 | 193 |
| 194 void RenderView::mapLocalToContainer(const RenderLayerModelObject* paintInvalida
tionContainer, TransformState& transformState, MapCoordinatesFlags mode, bool* w
asFixed, const PaintInvalidationState* paintInvalidationState) const | 194 void RenderView::mapLocalToContainer(const RenderLayerModelObject* paintInvalida
tionContainer, TransformState& transformState, MapCoordinatesFlags mode, const P
aintInvalidationState* paintInvalidationState) const |
| 195 { | 195 { |
| 196 ASSERT_UNUSED(wasFixed, !wasFixed || *wasFixed == static_cast<bool>(mode & I
sFixed)); | |
| 197 | |
| 198 if (!paintInvalidationContainer && mode & UseTransforms && shouldUseTransfor
mFromContainer(0)) { | 196 if (!paintInvalidationContainer && mode & UseTransforms && shouldUseTransfor
mFromContainer(0)) { |
| 199 TransformationMatrix t; | 197 TransformationMatrix t; |
| 200 getTransformFromContainer(0, LayoutSize(), t); | 198 getTransformFromContainer(0, LayoutSize(), t); |
| 201 transformState.applyTransform(t); | 199 transformState.applyTransform(t); |
| 202 } | 200 } |
| 203 } | 201 } |
| 204 | 202 |
| 205 const RenderObject* RenderView::pushMappingToContainer(const RenderLayerModelObj
ect* ancestorToStopAt, RenderGeometryMap& geometryMap) const | 203 const RenderObject* RenderView::pushMappingToContainer(const RenderLayerModelObj
ect* ancestorToStopAt, RenderGeometryMap& geometryMap) const |
| 206 { | 204 { |
| 207 LayoutSize offset; | 205 LayoutSize offset; |
| (...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 362 if (!paintInvalidationContainer && layer() && layer()->transform()) | 360 if (!paintInvalidationContainer && layer() && layer()->transform()) |
| 363 rect = layer()->transform()->mapRect(rect); | 361 rect = layer()->transform()->mapRect(rect); |
| 364 } | 362 } |
| 365 | 363 |
| 366 | 364 |
| 367 void RenderView::absoluteRects(Vector<IntRect>& rects, const LayoutPoint& accumu
latedOffset) const | 365 void RenderView::absoluteRects(Vector<IntRect>& rects, const LayoutPoint& accumu
latedOffset) const |
| 368 { | 366 { |
| 369 rects.append(pixelSnappedIntRect(accumulatedOffset, layer()->size())); | 367 rects.append(pixelSnappedIntRect(accumulatedOffset, layer()->size())); |
| 370 } | 368 } |
| 371 | 369 |
| 372 void RenderView::absoluteQuads(Vector<FloatQuad>& quads, bool* wasFixed) const | 370 void RenderView::absoluteQuads(Vector<FloatQuad>& quads) const |
| 373 { | 371 { |
| 374 if (wasFixed) | |
| 375 *wasFixed = false; | |
| 376 quads.append(FloatRect(FloatPoint(), layer()->size())); | 372 quads.append(FloatRect(FloatPoint(), layer()->size())); |
| 377 } | 373 } |
| 378 | 374 |
| 379 static RenderObject* rendererAfterPosition(RenderObject* object, unsigned offset
) | 375 static RenderObject* rendererAfterPosition(RenderObject* object, unsigned offset
) |
| 380 { | 376 { |
| 381 if (!object) | 377 if (!object) |
| 382 return 0; | 378 return 0; |
| 383 | 379 |
| 384 RenderObject* child = object->childAt(offset); | 380 RenderObject* child = object->childAt(offset); |
| 385 return child ? child : object->nextInPreOrderAfterChildren(); | 381 return child ? child : object->nextInPreOrderAfterChildren(); |
| (...skipping 406 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 792 return viewWidth(IncludeScrollbars) / scale; | 788 return viewWidth(IncludeScrollbars) / scale; |
| 793 } | 789 } |
| 794 | 790 |
| 795 double RenderView::layoutViewportHeight() const | 791 double RenderView::layoutViewportHeight() const |
| 796 { | 792 { |
| 797 float scale = m_frameView ? m_frameView->frame().pageZoomFactor() : 1; | 793 float scale = m_frameView ? m_frameView->frame().pageZoomFactor() : 1; |
| 798 return viewHeight(IncludeScrollbars) / scale; | 794 return viewHeight(IncludeScrollbars) / scale; |
| 799 } | 795 } |
| 800 | 796 |
| 801 } // namespace blink | 797 } // namespace blink |
| OLD | NEW |