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

Side by Side Diff: third_party/WebKit/Source/core/layout/LayoutBox.cpp

Issue 2517653002: Convert a few more CFI blacklist entries into DISABLE_CFI_PERF attributes. (Closed)
Patch Set: Revert some of the changes which have a high risk of breaking things Created 4 years, 1 month 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
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 * (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com) 4 * (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com)
5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com) 5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com)
6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. 6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc.
7 * All rights reserved. 7 * All rights reserved.
8 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. 8 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved.
9 * 9 *
10 * This library is free software; you can redistribute it and/or 10 * This library is free software; you can redistribute it and/or
(...skipping 4635 matching lines...) Expand 10 before | Expand all | Expand 10 after
4646 bool LayoutBox::shrinkToAvoidFloats() const { 4646 bool LayoutBox::shrinkToAvoidFloats() const {
4647 // Floating objects don't shrink. Objects that don't avoid floats don't 4647 // Floating objects don't shrink. Objects that don't avoid floats don't
4648 // shrink. 4648 // shrink.
4649 if (isInline() || !avoidsFloats() || isFloating()) 4649 if (isInline() || !avoidsFloats() || isFloating())
4650 return false; 4650 return false;
4651 4651
4652 // Only auto width objects can possibly shrink to avoid floats. 4652 // Only auto width objects can possibly shrink to avoid floats.
4653 return style()->width().isAuto(); 4653 return style()->width().isAuto();
4654 } 4654 }
4655 4655
4656 DISABLE_CFI_PERF
4656 static bool shouldBeConsideredAsReplaced(Node* node) { 4657 static bool shouldBeConsideredAsReplaced(Node* node) {
4657 // Checkboxes and radioboxes are not isAtomicInlineLevel() nor do they have 4658 // Checkboxes and radioboxes are not isAtomicInlineLevel() nor do they have
4658 // their own layoutObject in which to override avoidFloats(). 4659 // their own layoutObject in which to override avoidFloats().
4659 return node && node->isElementNode() && 4660 return node && node->isElementNode() &&
4660 (toElement(node)->isFormControlElement() || 4661 (toElement(node)->isFormControlElement() ||
4661 isHTMLImageElement(toElement(node))); 4662 isHTMLImageElement(toElement(node)));
4662 } 4663 }
4663 4664
4664 DISABLE_CFI_PERF 4665 DISABLE_CFI_PERF
4665 bool LayoutBox::avoidsFloats() const { 4666 bool LayoutBox::avoidsFloats() const {
(...skipping 950 matching lines...) Expand 10 before | Expand all | Expand 10 after
5616 LayoutRect rect = frameRect(); 5617 LayoutRect rect = frameRect();
5617 5618
5618 LayoutBlock* block = containingBlock(); 5619 LayoutBlock* block = containingBlock();
5619 if (block) 5620 if (block)
5620 block->adjustChildDebugRect(rect); 5621 block->adjustChildDebugRect(rect);
5621 5622
5622 return rect; 5623 return rect;
5623 } 5624 }
5624 5625
5625 } // namespace blink 5626 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/css/resolver/StyleResolver.cpp ('k') | third_party/WebKit/Source/core/page/FrameTree.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698