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

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

Issue 159863002: Remove CSS regions support, keeping a bare minimum to support "region-based" multicol. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 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) 2000 Dirk Mueller (mueller@kde.org) 4 * (C) 2000 Dirk Mueller (mueller@kde.org)
5 * (C) 2006 Allan Sandfeld Jensen (kde@carewolf.com) 5 * (C) 2006 Allan Sandfeld Jensen (kde@carewolf.com)
6 * (C) 2006 Samuel Weinig (sam.weinig@gmail.com) 6 * (C) 2006 Samuel Weinig (sam.weinig@gmail.com)
7 * Copyright (C) 2003, 2004, 2005, 2006, 2008, 2009, 2010, 2011 Apple Inc. All r ights reserved. 7 * Copyright (C) 2003, 2004, 2005, 2006, 2008, 2009, 2010, 2011 Apple Inc. All r ights reserved.
8 * Copyright (C) 2010 Google Inc. All rights reserved. 8 * Copyright (C) 2010 Google Inc. All rights reserved.
9 * Copyright (C) Research In Motion Limited 2011-2012. All rights reserved. 9 * Copyright (C) Research In Motion Limited 2011-2012. All rights reserved.
10 * 10 *
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after
215 return; 215 return;
216 216
217 bool shouldRepaint = true; 217 bool shouldRepaint = true;
218 if (intrinsicSizeChanged) { 218 if (intrinsicSizeChanged) {
219 if (!preferredLogicalWidthsDirty()) 219 if (!preferredLogicalWidthsDirty())
220 setPreferredLogicalWidthsDirty(); 220 setPreferredLogicalWidthsDirty();
221 221
222 bool hasOverrideSize = hasOverrideHeight() || hasOverrideWidth(); 222 bool hasOverrideSize = hasOverrideHeight() || hasOverrideWidth();
223 if (!hasOverrideSize && !imageSizeChanged) { 223 if (!hasOverrideSize && !imageSizeChanged) {
224 LogicalExtentComputedValues computedValues; 224 LogicalExtentComputedValues computedValues;
225 computeLogicalWidthInRegion(computedValues); 225 computeLogicalWidth(computedValues);
226 LayoutUnit newWidth = computedValues.m_extent; 226 LayoutUnit newWidth = computedValues.m_extent;
227 computeLogicalHeight(height(), 0, computedValues); 227 computeLogicalHeight(height(), 0, computedValues);
228 LayoutUnit newHeight = computedValues.m_extent; 228 LayoutUnit newHeight = computedValues.m_extent;
229 229
230 imageSizeChanged = width() != newWidth || height() != newHeight; 230 imageSizeChanged = width() != newWidth || height() != newHeight;
231 } 231 }
232 232
233 // FIXME: We only need to recompute the containing block's preferred siz e 233 // FIXME: We only need to recompute the containing block's preferred siz e
234 // if the containing block's size depends on the image's size (i.e., the container uses shrink-to-fit sizing). 234 // if the containing block's size depends on the image's size (i.e., the container uses shrink-to-fit sizing).
235 // There's no easy way to detect that shrink-to-fit is needed, always fo rce a layout. 235 // There's no easy way to detect that shrink-to-fit is needed, always fo rce a layout.
(...skipping 394 matching lines...) Expand 10 before | Expand all | Expand 10 after
630 return 0; 630 return 0;
631 631
632 ImageResource* cachedImage = m_imageResource->cachedImage(); 632 ImageResource* cachedImage = m_imageResource->cachedImage();
633 if (cachedImage && cachedImage->image() && cachedImage->image()->isSVGImage( )) 633 if (cachedImage && cachedImage->image() && cachedImage->image()->isSVGImage( ))
634 return toSVGImage(cachedImage->image())->embeddedContentBox(); 634 return toSVGImage(cachedImage->image())->embeddedContentBox();
635 635
636 return 0; 636 return 0;
637 } 637 }
638 638
639 } // namespace WebCore 639 } // namespace WebCore
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698