Title: [150135] trunk/Source/WebCore
- Revision
- 150135
- Author
- [email protected]
- Date
- 2013-05-15 12:12:21 -0700 (Wed, 15 May 2013)
Log Message
Revert http://trac.webkit.org/changeset/150047
It introduced unwanted behavioral differences between
Retina and non-Retina Mac hardware.
* platform/graphics/ca/GraphicsLayerCA.cpp:
(WebCore::GraphicsLayerCA::requiresTiledLayer):
(WebCore::GraphicsLayerCA::computePixelAlignment):
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (150134 => 150135)
--- trunk/Source/WebCore/ChangeLog 2013-05-15 19:12:04 UTC (rev 150134)
+++ trunk/Source/WebCore/ChangeLog 2013-05-15 19:12:21 UTC (rev 150135)
@@ -1,3 +1,14 @@
+2013-05-14 Simon Fraser <[email protected]>
+
+ Revert http://trac.webkit.org/changeset/150047
+
+ It introduced unwanted behavioral differences between
+ Retina and non-Retina Mac hardware.
+
+ * platform/graphics/ca/GraphicsLayerCA.cpp:
+ (WebCore::GraphicsLayerCA::requiresTiledLayer):
+ (WebCore::GraphicsLayerCA::computePixelAlignment):
+
2013-05-15 Darin Adler <[email protected]>
[Mac] Remove the ClipboardMac class and header file
Modified: trunk/Source/WebCore/platform/graphics/ca/GraphicsLayerCA.cpp (150134 => 150135)
--- trunk/Source/WebCore/platform/graphics/ca/GraphicsLayerCA.cpp 2013-05-15 19:12:04 UTC (rev 150134)
+++ trunk/Source/WebCore/platform/graphics/ca/GraphicsLayerCA.cpp 2013-05-15 19:12:21 UTC (rev 150135)
@@ -2676,10 +2676,8 @@
if (!m_drawsContent || !m_allowTiledLayer || m_isPageTiledBackingLayer)
return false;
- float effectiveScale = pageScaleFactor * deviceScaleFactor();
-
// FIXME: catch zero-size height or width here (or earlier)?
- return m_size.width() * effectiveScale > cMaxPixelDimension || m_size.height() * effectiveScale > cMaxPixelDimension;
+ return m_size.width() * pageScaleFactor > cMaxPixelDimension || m_size.height() * pageScaleFactor > cMaxPixelDimension;
}
void GraphicsLayerCA::swapFromOrToTiledLayer(bool useTiledLayer)
@@ -3010,8 +3008,7 @@
void GraphicsLayerCA::computePixelAlignment(float pageScaleFactor, const FloatPoint& positionRelativeToBase,
FloatPoint& position, FloatSize& size, FloatPoint3D& anchorPoint, FloatSize& alignmentOffset) const
{
- float effectiveScale = pageScaleFactor * deviceScaleFactor();
- if (!m_maintainsPixelAlignment || isIntegral(effectiveScale) || !m_drawsContent || m_masksToBounds) {
+ if (!m_maintainsPixelAlignment || isIntegral(pageScaleFactor) || !m_drawsContent || m_masksToBounds) {
position = m_position;
size = m_size;
anchorPoint = m_anchorPoint;
@@ -3022,12 +3019,12 @@
FloatRect baseRelativeBounds(positionRelativeToBase, m_size);
FloatRect scaledBounds = baseRelativeBounds;
// Scale by the page scale factor to compute the screen-relative bounds.
- scaledBounds.scale(effectiveScale);
+ scaledBounds.scale(pageScaleFactor);
// Round to integer boundaries.
FloatRect alignedBounds = enclosingIntRect(scaledBounds);
// Convert back to layer coordinates.
- alignedBounds.scale(1 / effectiveScale);
+ alignedBounds.scale(1 / pageScaleFactor);
// Epsilon is necessary to ensure that backing store size computation in CA, which involves integer truncation,
// will match our aligned bounds.
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes