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

Side by Side Diff: third_party/WebKit/Source/core/style/StyleFetchedImageSet.cpp

Issue 1468023002: Rename imageSizeForLayoutObject() to imageSize() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Make LayoutObject::shouldRespectImageOrientation class static and make use of it Created 5 years 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) 2012 Apple Inc. All rights reserved. 2 * Copyright (C) 2012 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
79 return m_bestFitImage->isLoaded(); 79 return m_bestFitImage->isLoaded();
80 } 80 }
81 81
82 bool StyleFetchedImageSet::errorOccurred() const 82 bool StyleFetchedImageSet::errorOccurred() const
83 { 83 {
84 return m_bestFitImage->errorOccurred(); 84 return m_bestFitImage->errorOccurred();
85 } 85 }
86 86
87 LayoutSize StyleFetchedImageSet::imageSize(const LayoutObject* layoutObject, flo at multiplier) const 87 LayoutSize StyleFetchedImageSet::imageSize(const LayoutObject* layoutObject, flo at multiplier) const
88 { 88 {
89 LayoutSize scaledImageSize = m_bestFitImage->imageSizeForLayoutObject(layout Object, multiplier); 89 LayoutSize scaledImageSize = m_bestFitImage->imageSize(LayoutObject::shouldR espectImageOrientation(layoutObject), multiplier);
90 scaledImageSize.scale(1 / m_imageScaleFactor); 90 scaledImageSize.scale(1 / m_imageScaleFactor);
91 return scaledImageSize; 91 return scaledImageSize;
92 } 92 }
93 93
94 bool StyleFetchedImageSet::imageHasRelativeWidth() const 94 bool StyleFetchedImageSet::imageHasRelativeWidth() const
95 { 95 {
96 return m_bestFitImage->imageHasRelativeWidth(); 96 return m_bestFitImage->imageHasRelativeWidth();
97 } 97 }
98 98
99 bool StyleFetchedImageSet::imageHasRelativeHeight() const 99 bool StyleFetchedImageSet::imageHasRelativeHeight() const
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
134 return m_bestFitImage->currentFrameKnownToBeOpaque(layoutObject); 134 return m_bestFitImage->currentFrameKnownToBeOpaque(layoutObject);
135 } 135 }
136 136
137 DEFINE_TRACE(StyleFetchedImageSet) 137 DEFINE_TRACE(StyleFetchedImageSet)
138 { 138 {
139 visitor->trace(m_imageSetValue); 139 visitor->trace(m_imageSetValue);
140 StyleImage::trace(visitor); 140 StyleImage::trace(visitor);
141 } 141 }
142 142
143 } // namespace blink 143 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698