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

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

Issue 2758683002: Replace ASSERT_NOT_REACHED with NOTREACHED in core/layout/ (Closed)
Patch Set: Rebase with latest Created 3 years, 9 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 * Copyright (C) 2000 Dirk Mueller (mueller@kde.org) 3 * Copyright (C) 2000 Dirk Mueller (mueller@kde.org)
4 * Copyright (C) 2004, 2006, 2007 Apple Inc. All rights reserved. 4 * Copyright (C) 2004, 2006, 2007 Apple Inc. All rights reserved.
5 * Copyright (C) Research In Motion Limited 2011-2012. All rights reserved. 5 * Copyright (C) Research In Motion Limited 2011-2012. All rights reserved.
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 586 matching lines...) Expand 10 before | Expand all | Expand 10 after
597 if (objectFit != ObjectFitScaleDown || 597 if (objectFit != ObjectFitScaleDown ||
598 finalRect.width() <= intrinsicSize.width()) 598 finalRect.width() <= intrinsicSize.width())
599 break; 599 break;
600 // fall through 600 // fall through
601 case ObjectFitNone: 601 case ObjectFitNone:
602 finalRect.setSize(intrinsicSize); 602 finalRect.setSize(intrinsicSize);
603 break; 603 break;
604 case ObjectFitFill: 604 case ObjectFitFill:
605 break; 605 break;
606 default: 606 default:
607 ASSERT_NOT_REACHED(); 607 NOTREACHED();
608 } 608 }
609 609
610 LayoutUnit xOffset = minimumValueForLength( 610 LayoutUnit xOffset = minimumValueForLength(
611 style()->objectPosition().x(), contentRect.width() - finalRect.width()); 611 style()->objectPosition().x(), contentRect.width() - finalRect.width());
612 LayoutUnit yOffset = minimumValueForLength( 612 LayoutUnit yOffset = minimumValueForLength(
613 style()->objectPosition().y(), contentRect.height() - finalRect.height()); 613 style()->objectPosition().y(), contentRect.height() - finalRect.height());
614 finalRect.move(xOffset, yOffset); 614 finalRect.move(xOffset, yOffset);
615 615
616 return finalRect; 616 return finalRect;
617 } 617 }
(...skipping 309 matching lines...) Expand 10 before | Expand all | Expand 10 after
927 inlineBoxWrapper()->root().setHasSelectedChildren(state != SelectionNone); 927 inlineBoxWrapper()->root().setHasSelectedChildren(state != SelectionNone);
928 } 928 }
929 929
930 void LayoutReplaced::IntrinsicSizingInfo::transpose() { 930 void LayoutReplaced::IntrinsicSizingInfo::transpose() {
931 size = size.transposedSize(); 931 size = size.transposedSize();
932 aspectRatio = aspectRatio.transposedSize(); 932 aspectRatio = aspectRatio.transposedSize();
933 std::swap(hasWidth, hasHeight); 933 std::swap(hasWidth, hasHeight);
934 } 934 }
935 935
936 } // namespace blink 936 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/layout/LayoutQuote.cpp ('k') | third_party/WebKit/Source/core/layout/LayoutRuby.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698