| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 2000 Simon Hausmann <hausmann@kde.org> | 3 * (C) 2000 Simon Hausmann <hausmann@kde.org> |
| 4 * (C) 2000 Stefan Schimanski (1Stein@gmx.de) | 4 * (C) 2000 Stefan Schimanski (1Stein@gmx.de) |
| 5 * Copyright (C) 2004, 2005, 2006, 2009 Apple Inc. All rights reserved. | 5 * Copyright (C) 2004, 2005, 2006, 2009 Apple Inc. All rights reserved. |
| 6 * Copyright (C) Research In Motion Limited 2011. All rights reserved. | 6 * Copyright (C) Research In Motion Limited 2011. All rights reserved. |
| 7 * | 7 * |
| 8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
| 9 * modify it under the terms of the GNU Library General Public | 9 * modify it under the terms of the GNU Library General Public |
| 10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
| (...skipping 297 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 308 { | 308 { |
| 309 Widget* widget = this->widget(); | 309 Widget* widget = this->widget(); |
| 310 ASSERT(widget); | 310 ASSERT(widget); |
| 311 | 311 |
| 312 LayoutRect contentBox = contentBoxRect(); | 312 LayoutRect contentBox = contentBoxRect(); |
| 313 LayoutRect absoluteContentBox(localToAbsoluteQuad(FloatQuad(FloatRect(conten
tBox))).boundingBox()); | 313 LayoutRect absoluteContentBox(localToAbsoluteQuad(FloatQuad(FloatRect(conten
tBox))).boundingBox()); |
| 314 if (widget->isFrameView()) { | 314 if (widget->isFrameView()) { |
| 315 contentBox.setLocation(absoluteContentBox.location()); | 315 contentBox.setLocation(absoluteContentBox.location()); |
| 316 return setWidgetGeometry(contentBox); | 316 return setWidgetGeometry(contentBox); |
| 317 } | 317 } |
| 318 | 318 // TODO(chrishtr): why are these widgets using an absolute rect for their fr
ameRect? |
| 319 return setWidgetGeometry(absoluteContentBox); | 319 return setWidgetGeometry(absoluteContentBox); |
| 320 } | 320 } |
| 321 | 321 |
| 322 // Widgets are always placed on integer boundaries, so rounding the size is actu
ally | 322 // Widgets are always placed on integer boundaries, so rounding the size is actu
ally |
| 323 // the desired behavior. This function is here because it's otherwise seldom wha
t we | 323 // the desired behavior. This function is here because it's otherwise seldom wha
t we |
| 324 // want to do with a LayoutRect. | 324 // want to do with a LayoutRect. |
| 325 static inline IntRect roundedIntRect(const LayoutRect& rect) | 325 static inline IntRect roundedIntRect(const LayoutRect& rect) |
| 326 { | 326 { |
| 327 return IntRect(roundedIntPoint(rect.location()), roundedIntSize(rect.size())
); | 327 return IntRect(roundedIntPoint(rect.location()), roundedIntSize(rect.size())
); |
| 328 } | 328 } |
| (...skipping 30 matching lines...) Expand all Loading... |
| 359 | 359 |
| 360 bool LayoutPart::isThrottledFrameView() const | 360 bool LayoutPart::isThrottledFrameView() const |
| 361 { | 361 { |
| 362 if (!widget() || !widget()->isFrameView()) | 362 if (!widget() || !widget()->isFrameView()) |
| 363 return false; | 363 return false; |
| 364 const FrameView* frameView = toFrameView(widget()); | 364 const FrameView* frameView = toFrameView(widget()); |
| 365 return frameView->shouldThrottleRendering(); | 365 return frameView->shouldThrottleRendering(); |
| 366 } | 366 } |
| 367 | 367 |
| 368 } | 368 } |
| OLD | NEW |