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

Side by Side Diff: WebCore/rendering/RenderLayerBacking.cpp

Issue 5523003: Part 1 of merges for Chromium bug #64589... (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/597/
Patch Set: Created 10 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
« no previous file with comments | « WebCore/rendering/RenderLayer.cpp ('k') | WebCore/rendering/RenderLayerCompositor.h » ('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) 2009 Apple Inc. All rights reserved. 2 * Copyright (C) 2009 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 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 m_graphicsLayer->setOpacity(compositingOpacity(style->opacity())); 125 m_graphicsLayer->setOpacity(compositingOpacity(style->opacity()));
126 } 126 }
127 127
128 void RenderLayerBacking::updateLayerTransform(const RenderStyle* style) 128 void RenderLayerBacking::updateLayerTransform(const RenderStyle* style)
129 { 129 {
130 // FIXME: This could use m_owningLayer->transform(), but that currently has transform-origin 130 // FIXME: This could use m_owningLayer->transform(), but that currently has transform-origin
131 // baked into it, and we don't want that. 131 // baked into it, and we don't want that.
132 TransformationMatrix t; 132 TransformationMatrix t;
133 if (m_owningLayer->hasTransform()) { 133 if (m_owningLayer->hasTransform()) {
134 style->applyTransform(t, toRenderBox(renderer())->borderBoxRect().size() , RenderStyle::ExcludeTransformOrigin); 134 style->applyTransform(t, toRenderBox(renderer())->borderBoxRect().size() , RenderStyle::ExcludeTransformOrigin);
135 makeMatrixRenderable(t, compositor()->hasAcceleratedCompositing()); 135 makeMatrixRenderable(t, compositor()->canRender3DTransforms());
136 } 136 }
137 137
138 m_graphicsLayer->setTransform(t); 138 m_graphicsLayer->setTransform(t);
139 } 139 }
140 140
141 static bool hasNonZeroTransformOrigin(const RenderObject* renderer) 141 static bool hasNonZeroTransformOrigin(const RenderObject* renderer)
142 { 142 {
143 RenderStyle* style = renderer->style(); 143 RenderStyle* style = renderer->style();
144 return (style->transformOriginX().type() == Fixed && style->transformOriginX ().value()) 144 return (style->transformOriginX().type() == Fixed && style->transformOriginX ().value())
145 || (style->transformOriginY().type() == Fixed && style->transformOriginY ().value()); 145 || (style->transformOriginY().type() == Fixed && style->transformOriginY ().value());
(...skipping 1153 matching lines...) Expand 10 before | Expand all | Expand 10 after
1299 1299
1300 if (m_graphicsLayer->drawsContent()) 1300 if (m_graphicsLayer->drawsContent())
1301 return m_graphicsLayer->usingTiledLayer() ? TiledCompositingLayer : Norm alCompositingLayer; 1301 return m_graphicsLayer->usingTiledLayer() ? TiledCompositingLayer : Norm alCompositingLayer;
1302 1302
1303 return ContainerCompositingLayer; 1303 return ContainerCompositingLayer;
1304 } 1304 }
1305 1305
1306 } // namespace WebCore 1306 } // namespace WebCore
1307 1307
1308 #endif // USE(ACCELERATED_COMPOSITING) 1308 #endif // USE(ACCELERATED_COMPOSITING)
OLDNEW
« no previous file with comments | « WebCore/rendering/RenderLayer.cpp ('k') | WebCore/rendering/RenderLayerCompositor.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698