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

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

Issue 134473008: 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: Rebase master 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
« no previous file with comments | « Source/core/rendering/RenderGrid.cpp ('k') | Source/core/rendering/RenderInline.cpp » ('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 * (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 200 matching lines...) Expand 10 before | Expand all | Expand 10 after
211 return; 211 return;
212 212
213 bool shouldRepaint = true; 213 bool shouldRepaint = true;
214 if (intrinsicSizeChanged) { 214 if (intrinsicSizeChanged) {
215 if (!preferredLogicalWidthsDirty()) 215 if (!preferredLogicalWidthsDirty())
216 setPreferredLogicalWidthsDirty(); 216 setPreferredLogicalWidthsDirty();
217 217
218 bool hasOverrideSize = hasOverrideHeight() || hasOverrideWidth(); 218 bool hasOverrideSize = hasOverrideHeight() || hasOverrideWidth();
219 if (!hasOverrideSize && !imageSizeChanged) { 219 if (!hasOverrideSize && !imageSizeChanged) {
220 LogicalExtentComputedValues computedValues; 220 LogicalExtentComputedValues computedValues;
221 computeLogicalWidthInRegion(computedValues); 221 computeLogicalWidth(computedValues);
222 LayoutUnit newWidth = computedValues.m_extent; 222 LayoutUnit newWidth = computedValues.m_extent;
223 computeLogicalHeight(height(), 0, computedValues); 223 computeLogicalHeight(height(), 0, computedValues);
224 LayoutUnit newHeight = computedValues.m_extent; 224 LayoutUnit newHeight = computedValues.m_extent;
225 225
226 imageSizeChanged = width() != newWidth || height() != newHeight; 226 imageSizeChanged = width() != newWidth || height() != newHeight;
227 } 227 }
228 228
229 // FIXME: We only need to recompute the containing block's preferred siz e 229 // FIXME: We only need to recompute the containing block's preferred siz e
230 // if the containing block's size depends on the image's size (i.e., the container uses shrink-to-fit sizing). 230 // if the containing block's size depends on the image's size (i.e., the container uses shrink-to-fit sizing).
231 // There's no easy way to detect that shrink-to-fit is needed, always fo rce a layout. 231 // 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
626 return 0; 626 return 0;
627 627
628 ImageResource* cachedImage = m_imageResource->cachedImage(); 628 ImageResource* cachedImage = m_imageResource->cachedImage();
629 if (cachedImage && cachedImage->image() && cachedImage->image()->isSVGImage( )) 629 if (cachedImage && cachedImage->image() && cachedImage->image()->isSVGImage( ))
630 return toSVGImage(cachedImage->image())->embeddedContentBox(); 630 return toSVGImage(cachedImage->image())->embeddedContentBox();
631 631
632 return 0; 632 return 0;
633 } 633 }
634 634
635 } // namespace WebCore 635 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/core/rendering/RenderGrid.cpp ('k') | Source/core/rendering/RenderInline.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698