Chromium Code Reviews| 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 313 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 324 | 324 |
| 325 if (widget->frameRect() == newFrame) | 325 if (widget->frameRect() == newFrame) |
| 326 return false; | 326 return false; |
| 327 | 327 |
| 328 RefPtr<LayoutPart> protector(this); | 328 RefPtr<LayoutPart> protector(this); |
| 329 RefPtrWillBeRawPtr<Node> protectedNode(node()); | 329 RefPtrWillBeRawPtr<Node> protectedNode(node()); |
| 330 widget->setFrameRect(newFrame); | 330 widget->setFrameRect(newFrame); |
| 331 return widget->frameRect().size() != newFrame.size(); | 331 return widget->frameRect().size() != newFrame.size(); |
| 332 } | 332 } |
| 333 | 333 |
| 334 PaintInvalidationReason LayoutPart::invalidatePaintIfNeeded(PaintInvalidationSta te& paintInvalidationState, const LayoutBoxModelObject& paintInvalidationContain er) | |
| 335 { | |
| 336 if (widget() && widget()->isFrameView()) { | |
| 337 LayoutView* childLayoutView = toFrameView(widget())->layoutView(); | |
| 338 if (!childLayoutView->isPaintInvalidationContainer()) { | |
|
chrishtr
2015/06/26 23:32:46
Why can't you just pass down these parameters in t
Xianzhu
2015/06/27 00:17:15
We don't walk into the sub frames during a paint i
chrishtr
2015/06/29 17:42:28
This does seem a cleaner approach. To make it easi
| |
| 339 childLayoutView->setForceCheckForPaintInvalidationByParent(paintInva lidationState.forceCheckForPaintInvalidation()); | |
| 340 childLayoutView->setPaintInvalidationCachedOffsetsEnabledByParent(pa intInvalidationState.cachedOffsetsEnabled()); | |
| 341 } | |
| 342 } | |
| 343 | |
| 344 return LayoutReplaced::invalidatePaintIfNeeded(paintInvalidationState, paint InvalidationContainer); | |
| 334 } | 345 } |
| 346 | |
| 347 } | |
| OLD | NEW |