Diff
Modified: branches/subpixellayout/Source/WebCore/rendering/RenderFileUploadControl.cpp (110481 => 110482)
--- branches/subpixellayout/Source/WebCore/rendering/RenderFileUploadControl.cpp 2012-03-12 21:36:10 UTC (rev 110481)
+++ branches/subpixellayout/Source/WebCore/rendering/RenderFileUploadControl.cpp 2012-03-12 21:51:01 UTC (rev 110482)
@@ -104,7 +104,7 @@
// Push a clip.
GraphicsContextStateSaver stateSaver(*paintInfo.context, false);
if (paintInfo.phase == PaintPhaseForeground || paintInfo.phase == PaintPhaseChildBlockBackgrounds) {
- LayoutRect clipRect(paintOffset.x() + borderLeft(), paintOffset.y() + borderTop(),
+ IntRect clipRect = pixelSnappedIntRect(paintOffset.x() + borderLeft(), paintOffset.y() + borderTop(),
width() - borderLeft() - borderRight(), height() - borderBottom() - borderTop() + buttonShadowHeight);
if (clipRect.isEmpty())
return;
@@ -142,7 +142,7 @@
paintInfo.context->setFillColor(style()->visitedDependentColor(CSSPropertyColor), style()->colorSpace());
// Draw the filename
- paintInfo.context->drawBidiText(font, textRun, LayoutPoint(textX, textY));
+ paintInfo.context->drawBidiText(font, textRun, IntPoint(roundToInt(textX), roundToInt(textY)));
if (input->icon()) {
// Determine where the icon should be placed
@@ -154,7 +154,7 @@
iconX = contentLeft + contentWidth() - buttonWidth - afterButtonSpacing - iconWidth;
// Draw the file icon
- input->icon()->paint(paintInfo.context, IntRect(iconX, iconY, iconWidth, iconHeight));
+ input->icon()->paint(paintInfo.context, IntRect(roundToInt(iconX), roundToInt(iconY), iconWidth, iconHeight));
}
}
Modified: branches/subpixellayout/Source/WebCore/rendering/RenderLayer.cpp (110481 => 110482)
--- branches/subpixellayout/Source/WebCore/rendering/RenderLayer.cpp 2012-03-12 21:36:10 UTC (rev 110481)
+++ branches/subpixellayout/Source/WebCore/rendering/RenderLayer.cpp 2012-03-12 21:51:01 UTC (rev 110482)
@@ -3923,9 +3923,9 @@
return result;
}
-LayoutRect RenderLayer::absoluteBoundingBox() const
+IntRect RenderLayer::absoluteBoundingBox() const
{
- return boundingBox(root());
+ return pixelSnappedIntRect(boundingBox(root()));
}
void RenderLayer::clearClipRectsIncludingDescendants()
Modified: branches/subpixellayout/Source/WebCore/rendering/RenderLayer.h (110481 => 110482)
--- branches/subpixellayout/Source/WebCore/rendering/RenderLayer.h 2012-03-12 21:36:10 UTC (rev 110481)
+++ branches/subpixellayout/Source/WebCore/rendering/RenderLayer.h 2012-03-12 21:51:01 UTC (rev 110482)
@@ -475,8 +475,8 @@
LayoutRect boundingBox(const RenderLayer* rootLayer) const;
// Bounding box in the coordinates of this layer.
LayoutRect localBoundingBox() const;
- // Bounding box relative to the root.
- LayoutRect absoluteBoundingBox() const;
+ // Pixel snapped bounding box relative to the root.
+ IntRect absoluteBoundingBox() const;
void updateHoverActiveState(const HitTestRequest&, HitTestResult&);
Modified: branches/subpixellayout/Source/WebCore/rendering/RenderLayerCompositor.cpp (110481 => 110482)
--- branches/subpixellayout/Source/WebCore/rendering/RenderLayerCompositor.cpp 2012-03-12 21:36:10 UTC (rev 110481)
+++ branches/subpixellayout/Source/WebCore/rendering/RenderLayerCompositor.cpp 2012-03-12 21:51:01 UTC (rev 110482)
@@ -1609,7 +1609,7 @@
// Fixed position elements that are invisible in the current view don't get their own layer.
FrameView* frameView = m_renderView->frameView();
- if (frameView && !layer->absoluteBoundingBox().intersects(LayoutRect(frameView->scrollXForFixedPosition(), frameView->scrollYForFixedPosition(), frameView->layoutWidth(), frameView->layoutHeight())))
+ if (frameView && !layer->absoluteBoundingBox().intersects(IntRect(frameView->scrollXForFixedPosition(), frameView->scrollYForFixedPosition(), frameView->layoutWidth(), frameView->layoutHeight())))
return false;
return true;
Modified: branches/subpixellayout/Source/WebCore/rendering/RenderListBox.cpp (110481 => 110482)
--- branches/subpixellayout/Source/WebCore/rendering/RenderListBox.cpp 2012-03-12 21:36:10 UTC (rev 110481)
+++ branches/subpixellayout/Source/WebCore/rendering/RenderListBox.cpp 2012-03-12 21:51:01 UTC (rev 110482)
@@ -444,7 +444,7 @@
ColorSpace colorSpace = element->renderStyle() ? element->renderStyle()->colorSpace() : style()->colorSpace();
LayoutRect itemRect = itemBoundingBoxRect(paintOffset, listIndex);
itemRect.intersect(controlClipRect(paintOffset));
- paintInfo.context->fillRect(itemRect, backColor, colorSpace);
+ paintInfo.context->fillRect(pixelSnappedIntRect(itemRect), backColor, colorSpace);
}
}
Modified: branches/subpixellayout/Source/WebKit/mac/WebView/WebRenderLayer.mm (110481 => 110482)
--- branches/subpixellayout/Source/WebKit/mac/WebView/WebRenderLayer.mm 2012-03-12 21:36:10 UTC (rev 110481)
+++ branches/subpixellayout/Source/WebKit/mac/WebView/WebRenderLayer.mm 2012-03-12 21:51:01 UTC (rev 110482)
@@ -112,7 +112,7 @@
{
if ((self = [super init])) {
name = [[WebRenderLayer nameForLayer:layer] retain];
- bounds = pixelSnappedIntRect(layer->absoluteBoundingBox());
+ bounds = layer->absoluteBoundingBox();
composited = layer->isComposited();
compositingInfo = [[WebRenderLayer compositingInfoForLayer:layer] retain];
}
@@ -151,7 +151,7 @@
RenderLayer* layer = toRenderBoxModelObject(renderer)->layer();
name = [[WebRenderLayer nameForLayer:layer] retain];
- bounds = pixelSnappedIntRect(layer->absoluteBoundingBox());
+ bounds = layer->absoluteBoundingBox();
composited = layer->isComposited();
compositingInfo = [[WebRenderLayer compositingInfoForLayer:layer] retain];
Modified: branches/subpixellayout/Source/WebKit2/Shared/WebRenderLayer.cpp (110481 => 110482)
--- branches/subpixellayout/Source/WebKit2/Shared/WebRenderLayer.cpp 2012-03-12 21:36:10 UTC (rev 110481)
+++ branches/subpixellayout/Source/WebKit2/Shared/WebRenderLayer.cpp 2012-03-12 21:51:01 UTC (rev 110482)
@@ -126,7 +126,7 @@
}
#endif
- m_absoluteBoundingBox = pixelSnappedIntRect(layer->absoluteBoundingBox());
+ m_absoluteBoundingBox = layer->absoluteBoundingBox();
m_negativeZOrderList = createArrayFromLayerList(layer->negZOrderList());
m_normalFlowList = createArrayFromLayerList(layer->normalFlowList());