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

Unified Diff: cc/layer_impl.cc

Issue 11777008: cc: Use maximum tiling contents scales for picture layer scale (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Ok, 1.f Created 7 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/layer_impl.h ('k') | cc/layer_tree_host_common.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/layer_impl.cc
diff --git a/cc/layer_impl.cc b/cc/layer_impl.cc
index 98dc5599467fee9942b73a6314e6fdc2f28f938a..d00f21881be03245e60a3ff4891031a3addbece3 100644
--- a/cc/layer_impl.cc
+++ b/cc/layer_impl.cc
@@ -701,6 +701,19 @@ void LayerImpl::setContentsScale(float contentsScaleX, float contentsScaleY)
noteLayerPropertyChanged();
}
+void LayerImpl::calculateContentsScale(
+ float idealContentsScale,
+ float* contentsScaleX,
+ float* contentsScaleY,
+ gfx::Size* contentBounds)
+{
+ // Base LayerImpl has all of its content scales and content bounds pushed
+ // from its Layer during commit and just reuses those values as-is.
+ *contentsScaleX = this->contentsScaleX();
+ *contentsScaleY = this->contentsScaleY();
+ *contentBounds = this->contentBounds();
+}
+
void LayerImpl::setScrollOffset(gfx::Vector2d scrollOffset)
{
if (m_scrollOffset == scrollOffset)
« no previous file with comments | « cc/layer_impl.h ('k') | cc/layer_tree_host_common.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698