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

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

Issue 2701993002: DO NOT COMMIT: Results of running new (proposed) clang-format on Blink (Closed)
Patch Set: Created 3 years, 10 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
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) 2007 David Smith (catfish.man@gmail.com) 4 * (C) 2007 David Smith (catfish.man@gmail.com)
5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. 5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc.
6 * All rights reserved. 6 * All rights reserved.
7 * Copyright (C) Research In Motion Limited 2010. All rights reserved. 7 * Copyright (C) Research In Motion Limited 2010. All rights reserved.
8 * 8 *
9 * This library is free software; you can redistribute it and/or 9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Library General Public 10 * modify it under the terms of the GNU Library General Public
(...skipping 622 matching lines...) Expand 10 before | Expand all | Expand 10 after
633 if (logicalLeft < m_offset) { 633 if (logicalLeft < m_offset) {
634 m_offset = logicalLeft; 634 m_offset = logicalLeft;
635 return true; 635 return true;
636 } 636 }
637 return false; 637 return false;
638 } 638 }
639 639
640 template <FloatingObject::Type FloatTypeValue> 640 template <FloatingObject::Type FloatTypeValue>
641 LayoutUnit ComputeFloatOffsetForFloatLayoutAdapter< 641 LayoutUnit ComputeFloatOffsetForFloatLayoutAdapter<
642 FloatTypeValue>::heightRemaining() const { 642 FloatTypeValue>::heightRemaining() const {
643 return this->m_outermostFloat 643 return this->m_outermostFloat ? this->m_layoutObject->logicalBottomForFloat(
644 ? this->m_layoutObject->logicalBottomForFloat( 644 *this->m_outermostFloat) -
645 *this->m_outermostFloat) - 645 this->m_lineTop
646 this->m_lineTop 646 : LayoutUnit(1);
647 : LayoutUnit(1);
648 } 647 }
649 648
650 template <FloatingObject::Type FloatTypeValue> 649 template <FloatingObject::Type FloatTypeValue>
651 DISABLE_CFI_PERF inline void 650 DISABLE_CFI_PERF inline void
652 ComputeFloatOffsetAdapter<FloatTypeValue>::collectIfNeeded( 651 ComputeFloatOffsetAdapter<FloatTypeValue>::collectIfNeeded(
653 const IntervalType& interval) { 652 const IntervalType& interval) {
654 const FloatingObject& floatingObject = *(interval.data()); 653 const FloatingObject& floatingObject = *(interval.data());
655 if (floatingObject.getType() != FloatTypeValue || 654 if (floatingObject.getType() != FloatTypeValue ||
656 !rangesIntersect(interval.low(), interval.high(), m_lineTop, 655 !rangesIntersect(interval.low(), interval.high(), m_lineTop,
657 m_lineBottom)) 656 m_lineBottom))
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
726 const FloatingObject* floatingObject) { 725 const FloatingObject* floatingObject) {
727 return String::format("%p (%gx%g %gx%g)", floatingObject, 726 return String::format("%p (%gx%g %gx%g)", floatingObject,
728 floatingObject->frameRect().x().toFloat(), 727 floatingObject->frameRect().x().toFloat(),
729 floatingObject->frameRect().y().toFloat(), 728 floatingObject->frameRect().y().toFloat(),
730 floatingObject->frameRect().maxX().toFloat(), 729 floatingObject->frameRect().maxX().toFloat(),
731 floatingObject->frameRect().maxY().toFloat()); 730 floatingObject->frameRect().maxY().toFloat());
732 } 731 }
733 #endif 732 #endif
734 733
735 } // namespace blink 734 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698