Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(301)

Side by Side Diff: Source/core/rendering/RenderListItem.cpp

Issue 16402019: Remove clips where we can show that they are unnecessary. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: per jchaffraix Created 7 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « Source/core/rendering/RenderBox.cpp ('k') | Source/core/rendering/RenderOverflow.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 * Copyright (C) 2003, 2004, 2005, 2006, 2010 Apple Inc. All rights reserved. 4 * Copyright (C) 2003, 2004, 2005, 2006, 2010 Apple Inc. All rights reserved.
5 * Copyright (C) 2006 Andrew Wellington (proton@wiretapped.net) 5 * Copyright (C) 2006 Andrew Wellington (proton@wiretapped.net)
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 374 matching lines...) Expand 10 before | Expand all | Expand 10 after
385 385
386 if (adjustOverflow) { 386 if (adjustOverflow) {
387 LayoutRect markerRect(markerLogicalLeft + lineOffset, blockOffset, m _marker->width(), m_marker->height()); 387 LayoutRect markerRect(markerLogicalLeft + lineOffset, blockOffset, m _marker->width(), m_marker->height());
388 if (!style()->isHorizontalWritingMode()) 388 if (!style()->isHorizontalWritingMode())
389 markerRect = markerRect.transposedRect(); 389 markerRect = markerRect.transposedRect();
390 RenderBox* o = m_marker; 390 RenderBox* o = m_marker;
391 bool propagateVisualOverflow = true; 391 bool propagateVisualOverflow = true;
392 bool propagateLayoutOverflow = true; 392 bool propagateLayoutOverflow = true;
393 do { 393 do {
394 o = o->parentBox(); 394 o = o->parentBox();
395 if (o->hasOverflowClip())
396 propagateVisualOverflow = false;
397 if (o->isRenderBlock()) { 395 if (o->isRenderBlock()) {
398 if (propagateVisualOverflow) 396 if (propagateVisualOverflow)
399 toRenderBlock(o)->addVisualOverflow(markerRect); 397 toRenderBlock(o)->addContentsVisualOverflow(markerRect);
400 if (propagateLayoutOverflow) 398 if (propagateLayoutOverflow)
401 toRenderBlock(o)->addLayoutOverflow(markerRect); 399 toRenderBlock(o)->addLayoutOverflow(markerRect);
402 } 400 }
403 if (o->hasOverflowClip()) 401 if (o->hasOverflowClip()) {
404 propagateLayoutOverflow = false; 402 propagateLayoutOverflow = false;
403 propagateVisualOverflow = false;
404 }
405 if (o->hasSelfPaintingLayer()) 405 if (o->hasSelfPaintingLayer())
406 propagateVisualOverflow = false; 406 propagateVisualOverflow = false;
407 markerRect.moveBy(-o->location()); 407 markerRect.moveBy(-o->location());
408 } while (o != this && propagateVisualOverflow && propagateLayoutOver flow); 408 } while (o != this && propagateVisualOverflow && propagateLayoutOver flow);
409 } 409 }
410 } 410 }
411 } 411 }
412 412
413 void RenderListItem::paint(PaintInfo& paintInfo, const LayoutPoint& paintOffset) 413 void RenderListItem::paint(PaintInfo& paintInfo, const LayoutPoint& paintOffset)
414 { 414 {
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
505 // assume that all the following ones have too. 505 // assume that all the following ones have too.
506 // This gives us the opportunity to stop here and avoid 506 // This gives us the opportunity to stop here and avoid
507 // marking the same nodes again. 507 // marking the same nodes again.
508 break; 508 break;
509 } 509 }
510 item->updateValue(); 510 item->updateValue();
511 } 511 }
512 } 512 }
513 513
514 } // namespace WebCore 514 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/core/rendering/RenderBox.cpp ('k') | Source/core/rendering/RenderOverflow.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698