Changeset 87989 in webkit
- Timestamp:
- Jun 2, 2011 7:41:09 PM (13 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 32 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r87988 r87989 1 2011-06-02 Levi Weintraub <leviw@chromium.org> 2 3 Reviewed by Eric Seidel. 4 5 Switch paintReplaced to use IntPoint 6 https://bugs.webkit.org/show_bug.cgi?id=61891 7 8 Switching paintReplaced to use IntPoint to represent the paint offset instead 9 of a pair of ints. 10 11 Also renaming the IntPoint flavor of IntRect::move to moveBy to clear up the 12 fact that the IntPoint is added as an offset as opposed to being relocated 13 to that point. 14 15 No tests because this is just a refactoring. 16 17 * page/FrameView.cpp: 18 (WebCore::FrameView::invalidateScrollbarRect): 19 (WebCore::FrameView::convertFromRenderer): 20 (WebCore::FrameView::convertToRenderer): 21 * platform/ScrollView.cpp: 22 (WebCore::ScrollView::wheelEvent): 23 * platform/ScrollbarThemeComposite.cpp: 24 (WebCore::ScrollbarThemeComposite::invalidatePart): 25 * platform/graphics/gpu/Texture.cpp 26 (WebCore::Texture::updateSubRect) 27 * platform/graphics/IntRect.h: 28 (WebCore::IntRect::moveBy): 29 * platform/mac/WidgetMac.mm: 30 (WebCore::Widget::paint): 31 * rendering/InlineFlowBox.cpp: 32 (WebCore::InlineFlowBox::paint): 33 * rendering/RenderBlock.cpp: 34 (WebCore::RenderBlock::logicalRectToPhysicalRect): 35 (WebCore::RenderBlock::selectionGaps): 36 * rendering/RenderBox.cpp: 37 (WebCore::RenderBox::offsetFromContainer): 38 (WebCore::RenderBox::computeRectForRepaint): 39 (WebCore::RenderBox::localCaretRect): 40 * rendering/RenderDetailsMarker.cpp: 41 (WebCore::RenderDetailsMarker::paint): 42 * rendering/RenderEmbeddedObject.cpp: 43 (WebCore::RenderEmbeddedObject::paintReplaced): 44 * rendering/RenderEmbeddedObject.h: 45 * rendering/RenderHTMLCanvas.cpp: 46 (WebCore::RenderHTMLCanvas::paintReplaced): 47 * rendering/RenderHTMLCanvas.h: 48 * rendering/RenderImage.cpp: 49 (WebCore::RenderImage::paintReplaced): 50 * rendering/RenderImage.h: 51 * rendering/RenderInline.cpp: 52 (WebCore::RenderInline::culledInlineVisualOverflowBoundingBox): 53 * rendering/RenderLayer.cpp: 54 (WebCore::expandClipRectForDescendantsAndReflection): 55 (WebCore::RenderLayer::paintScrollCorner): 56 (WebCore::RenderLayer::paintResizer): 57 (WebCore::RenderLayer::paintChildLayerIntoColumns): 58 (WebCore::RenderLayer::hitTestChildLayerColumns): 59 (WebCore::RenderLayer::boundingBox): 60 (WebCore::RenderLayer::setBackingNeedsRepaintInRect): 61 * rendering/RenderLayerBacking.cpp: 62 (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry): 63 (WebCore::paintScrollbar): 64 (WebCore::RenderLayerBacking::paintContents): 65 * rendering/RenderLayerCompositor.cpp: 66 (WebCore::RenderLayerCompositor::calculateCompositedBounds): 67 (WebCore::RenderLayerCompositor::layerWillBeRemoved): 68 (WebCore::paintScrollbar): 69 (WebCore::RenderLayerCompositor::paintContents): 70 * rendering/RenderListBox.cpp: 71 (WebCore::RenderListBox::controlClipRect): 72 * rendering/RenderListItem.cpp: 73 (WebCore::RenderListItem::positionListMarker): 74 * rendering/RenderListMarker.cpp: 75 (WebCore::RenderListMarker::paint): 76 * rendering/RenderReplaced.cpp: 77 (WebCore::RenderReplaced::paint): 78 * rendering/RenderReplaced.h: 79 (WebCore::RenderReplaced::paintReplaced): 80 * rendering/RenderTableCell.cpp: 81 (WebCore::RenderTableCell::computeRectForRepaint): 82 * rendering/RenderTextControlSingleLine.cpp: 83 (WebCore::RenderTextControlSingleLine::controlClipRect): 84 * rendering/RenderVideo.cpp: 85 (WebCore::RenderVideo::paintReplaced): 86 * rendering/RenderVideo.h: 87 * rendering/RenderView.cpp: 88 (WebCore::RenderView::repaintViewRectangle): 89 1 90 2011-06-02 James Robinson <jamesr@chromium.org> 2 91 -
trunk/Source/WebCore/page/FrameView.cpp
r87726 r87989 2164 2164 // Add in our offset within the FrameView. 2165 2165 IntRect dirtyRect = rect; 2166 dirtyRect.move (scrollbar->location());2166 dirtyRect.moveBy(scrollbar->location()); 2167 2167 invalidateRect(dirtyRect); 2168 2168 } … … 2628 2628 2629 2629 // Convert from page ("absolute") to FrameView coordinates. 2630 rect.move (-scrollPosition());2630 rect.moveBy(-scrollPosition()); 2631 2631 2632 2632 return rect; … … 2638 2638 2639 2639 // Convert from FrameView coords into page ("absolute") coordinates. 2640 rect.move (scrollPosition());2640 rect.moveBy(scrollPosition()); 2641 2641 2642 2642 // FIXME: we don't have a way to map an absolute rect down to a local quad, so just -
trunk/Source/WebCore/platform/ScrollView.cpp
r87303 r87989 1009 1009 1010 1010 context->translate(x(), y()); 1011 documentDirtyRect.move (-location());1011 documentDirtyRect.moveBy(-location()); 1012 1012 1013 1013 if (!paintsEntireContents()) { 1014 1014 context->translate(-scrollX(), -scrollY()); 1015 documentDirtyRect.move (scrollPosition());1015 documentDirtyRect.moveBy(scrollPosition()); 1016 1016 1017 1017 context->clip(visibleContentRect()); … … 1034 1034 scrollViewDirtyRect.intersect(frameRect()); 1035 1035 context->translate(x(), y()); 1036 scrollViewDirtyRect.move (-location());1036 scrollViewDirtyRect.moveBy(-location()); 1037 1037 1038 1038 paintScrollbars(context, scrollViewDirtyRect); … … 1128 1128 // Scrollbars won't be transformed within us 1129 1129 IntRect newRect = localRect; 1130 newRect.move (scrollbar->location());1130 newRect.moveBy(scrollbar->location()); 1131 1131 return newRect; 1132 1132 } … … 1136 1136 IntRect newRect = parentRect; 1137 1137 // Scrollbars won't be transformed within us 1138 newRect.move (-scrollbar->location());1138 newRect.moveBy(-scrollbar->location()); 1139 1139 return newRect; 1140 1140 } -
trunk/Source/WebCore/platform/ScrollbarThemeComposite.cpp
r87303 r87989 235 235 } 236 236 } 237 result.move (-scrollbar->location());237 result.moveBy(-scrollbar->location()); 238 238 scrollbar->invalidateRect(result); 239 239 } -
trunk/Source/WebCore/platform/graphics/IntRect.h
r87312 r87989 109 109 110 110 void move(const IntSize& size) { m_location += size; } 111 void move (const IntPoint& offset) { m_location.move(offset.x(), offset.y()); }111 void moveBy(const IntPoint& offset) { m_location.move(offset.x(), offset.y()); } 112 112 void move(int dx, int dy) { m_location.move(dx, dy); } 113 113 -
trunk/Source/WebCore/platform/graphics/gpu/Texture.cpp
r87303 r87989 177 177 178 178 IntRect dstRect = updateRectIntersected; 179 dstRect.move (-tileBoundsWithBorder.location());179 dstRect.moveBy(-tileBoundsWithBorder.location()); 180 180 181 181 if (updateRectIntersected.isEmpty()) -
trunk/Source/WebCore/platform/mac/WidgetMac.mm
r87303 r87989 249 249 250 250 IntRect dirtyRect = r; 251 dirtyRect.move (-transformOrigin);251 dirtyRect.moveBy(-transformOrigin); 252 252 if (![view isFlipped]) 253 253 dirtyRect.setY([view bounds].size.height - dirtyRect.maxY()); … … 293 293 294 294 IntRect dirtyRect = r; 295 dirtyRect.move (-transformOrigin);295 dirtyRect.moveBy(-transformOrigin); 296 296 if (![view isFlipped]) 297 297 dirtyRect.setY([view bounds].size.height - dirtyRect.maxY()); -
trunk/Source/WebCore/rendering/InlineFlowBox.cpp
r87753 r87989 952 952 overflowRect.inflate(renderer()->maximalOutlineSize(paintInfo.phase)); 953 953 flipForWritingMode(overflowRect); 954 overflowRect.move (paintOffset);954 overflowRect.moveBy(paintOffset); 955 955 956 956 if (!paintInfo.rect.intersects(overflowRect)) -
trunk/Source/WebCore/rendering/RenderBlock.cpp
r87936 r87989 2799 2799 result = IntRect(logicalRect.y(), logicalRect.x(), logicalRect.height(), logicalRect.width()); 2800 2800 flipForWritingMode(result); 2801 result.move (rootBlockPhysicalPosition);2801 result.moveBy(rootBlockPhysicalPosition); 2802 2802 return result; 2803 2803 } … … 2812 2812 IntRect flippedBlockRect = IntRect(offsetFromRootBlock.width(), offsetFromRootBlock.height(), width(), height()); 2813 2813 rootBlock->flipForWritingMode(flippedBlockRect); 2814 flippedBlockRect.move (rootBlockPhysicalPosition);2814 flippedBlockRect.moveBy(rootBlockPhysicalPosition); 2815 2815 clipOutPositionedObjects(paintInfo, flippedBlockRect.location(), m_positionedObjects.get()); 2816 2816 if (isBody() || isRoot()) // The <body> must make sure to examine its containingBlock's positioned objects. -
trunk/Source/WebCore/rendering/RenderBox.cpp
r87881 r87989 1309 1309 toRenderBlock(o)->flipForWritingModeIncludingColumns(columnRect); 1310 1310 offset += IntSize(columnRect.location().x(), columnRect.location().y()); 1311 columnRect.move (point);1311 columnRect.moveBy(point); 1312 1312 o->adjustForColumns(offset, columnRect.location()); 1313 1313 } else … … 1435 1435 rect.move(layer()->relativePositionOffset()); 1436 1436 1437 rect.move (location());1437 rect.moveBy(location()); 1438 1438 rect.move(layoutState->m_paintOffset); 1439 1439 if (layoutState->m_clipped) … … 3100 3100 3101 3101 // Move to local coords 3102 rect.move (-location());3102 rect.moveBy(-location()); 3103 3103 return rect; 3104 3104 } -
trunk/Source/WebCore/rendering/RenderDetailsMarker.cpp
r87303 r87989 130 130 IntPoint boxOrigin(tx + x(), ty + y()); 131 131 IntRect overflowRect(visualOverflowRect()); 132 overflowRect.move (boxOrigin);132 overflowRect.moveBy(boxOrigin); 133 133 overflowRect.inflate(maximalOutlineSize(paintInfo.phase)); 134 134 -
trunk/Source/WebCore/rendering/RenderEmbeddedObject.cpp
r86739 r87989 146 146 } 147 147 148 void RenderEmbeddedObject::paintReplaced(PaintInfo& paintInfo, int tx, int ty)148 void RenderEmbeddedObject::paintReplaced(PaintInfo& paintInfo, const IntPoint& paintOffset) 149 149 { 150 150 if (!pluginCrashedOrWasMissing()) … … 164 164 TextRun run(""); 165 165 float textWidth; 166 if (!getReplacementTextGeometry( tx, ty, contentRect, path, replacementTextRect, font, run, textWidth))166 if (!getReplacementTextGeometry(paintOffset.x(), paintOffset.y(), contentRect, path, replacementTextRect, font, run, textWidth)) 167 167 return; 168 168 -
trunk/Source/WebCore/rendering/RenderEmbeddedObject.h
r66711 r87989 57 57 virtual bool isEmbeddedObject() const { return true; } 58 58 59 virtual void paintReplaced(PaintInfo&, int, int);59 virtual void paintReplaced(PaintInfo&, const IntPoint&); 60 60 virtual void paint(PaintInfo& paintInfo, int, int); 61 61 -
trunk/Source/WebCore/rendering/RenderHTMLCanvas.cpp
r87121 r87989 55 55 } 56 56 57 void RenderHTMLCanvas::paintReplaced(PaintInfo& paintInfo, int tx, int ty)57 void RenderHTMLCanvas::paintReplaced(PaintInfo& paintInfo, const IntPoint& paintOffset) 58 58 { 59 59 IntRect rect = contentBoxRect(); 60 rect.move (tx, ty);60 rect.moveBy(paintOffset); 61 61 bool useLowQualityScale = style()->imageRendering() == ImageRenderingOptimizeContrast; 62 62 static_cast<HTMLCanvasElement*>(node())->paint(paintInfo.context, rect, useLowQualityScale); -
trunk/Source/WebCore/rendering/RenderHTMLCanvas.h
r79920 r87989 44 44 private: 45 45 virtual const char* renderName() const { return "RenderHTMLCanvas"; } 46 virtual void paintReplaced(PaintInfo&, int tx, int ty);46 virtual void paintReplaced(PaintInfo&, const IntPoint&); 47 47 virtual void intrinsicSizeChanged() { canvasSizeChanged(); } 48 48 }; -
trunk/Source/WebCore/rendering/RenderImage.cpp
r87866 r87989 229 229 } 230 230 231 void RenderImage::paintReplaced(PaintInfo& paintInfo, int tx, int ty)231 void RenderImage::paintReplaced(PaintInfo& paintInfo, const IntPoint& paintOffset) 232 232 { 233 233 int cWidth = contentWidth(); … … 249 249 context->setStrokeColor(Color::lightGray, style()->colorSpace()); 250 250 context->setFillColor(Color::transparent, style()->colorSpace()); 251 context->drawRect(IntRect( tx + leftBorder + leftPad, ty+ topBorder + topPad, cWidth, cHeight));251 context->drawRect(IntRect(paintOffset.x() + leftBorder + leftPad, paintOffset.y() + topBorder + topPad, cWidth, cHeight)); 252 252 253 253 bool errorPictureDrawn = false; 254 int imageX = 0; 255 int imageY = 0; 254 IntSize imageOffset; 256 255 // When calculating the usable dimensions, exclude the pixels of 257 256 // the ouline rect so the error image/alt text doesn't draw on it. … … 269 268 if (centerY < 0) 270 269 centerY = 0; 271 imageX = leftBorder + leftPad + centerX + 1; 272 imageY = topBorder + topPad + centerY + 1; 273 context->drawImage(image.get(), style()->colorSpace(), IntPoint(tx + imageX, ty + imageY)); 270 imageOffset = IntSize(leftBorder + leftPad + centerX + 1, topBorder + topPad + centerY + 1); 271 context->drawImage(image.get(), style()->colorSpace(), paintOffset + imageOffset); 274 272 errorPictureDrawn = true; 275 273 } … … 278 276 String text = document()->displayStringModifiedByEncoding(m_altText); 279 277 context->setFillColor(style()->visitedDependentColor(CSSPropertyColor), style()->colorSpace()); 280 int ax = tx + leftBorder + leftPad;281 int ay = ty + topBorder + topPad;282 278 const Font& font = style()->font(); 283 279 const FontMetrics& fontMetrics = font.fontMetrics(); 284 280 int ascent = fontMetrics.ascent(); 281 IntPoint altTextOffset = paintOffset; 282 altTextOffset.move(leftBorder + leftPad, topBorder + topPad + ascent); 285 283 286 284 // Only draw the alt text if it'll fit within the content box, … … 289 287 int textWidth = font.width(textRun); 290 288 if (errorPictureDrawn) { 291 if (usableWidth >= textWidth && fontMetrics.height() <= image Y)292 context->drawText(font, textRun, IntPoint(ax, ay + ascent));289 if (usableWidth >= textWidth && fontMetrics.height() <= imageOffset.height()) 290 context->drawText(font, textRun, altTextOffset); 293 291 } else if (usableWidth >= textWidth && cHeight >= fontMetrics.height()) 294 context->drawText(font, textRun, IntPoint(ax, ay + ascent));292 context->drawText(font, textRun, altTextOffset); 295 293 } 296 294 } … … 302 300 #if PLATFORM(MAC) 303 301 if (style()->highlight() != nullAtom && !paintInfo.context->paintingDisabled()) 304 paintCustomHighlight( IntPoint(tx - x(), ty - y()), style()->highlight(), true);302 paintCustomHighlight(toPoint(paintOffset - location()), style()->highlight(), true); 305 303 #endif 306 304 307 305 IntSize contentSize(cWidth, cHeight); 308 IntRect rect(IntPoint(tx + leftBorder + leftPad, ty + topBorder + topPad), contentSize); 309 paintIntoRect(context, rect); 306 IntPoint contentLocation = paintOffset; 307 contentLocation.move(leftBorder + leftPad, topBorder + topPad); 308 paintIntoRect(context, IntRect(contentLocation, contentSize)); 310 309 } 311 310 } -
trunk/Source/WebCore/rendering/RenderImage.h
r86705 r87989 77 77 virtual bool isRenderImage() const { return true; } 78 78 79 virtual void paintReplaced(PaintInfo&, int tx, int ty);79 virtual void paintReplaced(PaintInfo&, const IntPoint&); 80 80 81 81 virtual int minimumReplacedHeight() const; -
trunk/Source/WebCore/rendering/RenderInline.cpp
r87738 r87989 900 900 IntRect logicalRect = currBox->logicalVisualOverflowRectForPropagation(style()); 901 901 if (isHorizontal) { 902 logicalRect.move (currBox->location());902 logicalRect.moveBy(currBox->location()); 903 903 result.uniteIfNonZero(logicalRect); 904 904 } else { 905 logicalRect.move (currBox->location());905 logicalRect.moveBy(currBox->location()); 906 906 result.uniteIfNonZero(logicalRect.transposedRect()); 907 907 } -
trunk/Source/WebCore/rendering/RenderInputSpeech.cpp
r87303 r87989 83 83 buttonRect.move(offsetFromInputRenderer); 84 84 // Account for the local drawing offset. 85 buttonRect.move (rect.location());85 buttonRect.moveBy(rect.location()); 86 86 87 87 DEFINE_STATIC_LOCAL(RefPtr<Image>, imageStateNormal, (Image::loadPlatformResource("inputSpeech"))); -
trunk/Source/WebCore/rendering/RenderLayer.cpp
r87880 r87989 901 901 clipRect.move(-delta.x(), -delta.y()); 902 902 clipRect.unite(l->renderBox()->reflectedRect(clipRect)); 903 clipRect.move (delta);903 clipRect.moveBy(delta); 904 904 } 905 905 } … … 2326 2326 2327 2327 IntRect absRect = scrollCornerRect(); 2328 absRect.move (paintOffset);2328 absRect.moveBy(paintOffset); 2329 2329 if (!absRect.intersects(damageRect)) 2330 2330 return; … … 2355 2355 2356 2356 IntRect absRect = resizerCornerRect(this, box->borderBoxRect()); 2357 absRect.move (paintOffset);2357 absRect.moveBy(paintOffset); 2358 2358 if (!absRect.intersects(damageRect)) 2359 2359 return; … … 2773 2773 IntSize offset = isHorizontal ? IntSize(logicalLeftOffset, currLogicalTopOffset) : IntSize(currLogicalTopOffset, logicalLeftOffset); 2774 2774 2775 colRect.move (layerOffset);2775 colRect.moveBy(layerOffset); 2776 2776 2777 2777 IntRect localDirtyRect(paintDirtyRect); … … 3257 3257 else 3258 3258 currLogicalTopOffset += blockDelta; 3259 colRect.move (layerOffset);3259 colRect.moveBy(layerOffset); 3260 3260 3261 3261 IntRect localClipRect(hitTestRect); … … 3598 3598 IntPoint delta; 3599 3599 convertToLayerCoords(ancestorLayer, delta); 3600 result.move (delta);3600 result.moveBy(delta); 3601 3601 return result; 3602 3602 } … … 3935 3935 IntPoint delta; 3936 3936 convertToLayerCoords(root(), delta); 3937 absRect.move (delta);3937 absRect.moveBy(delta); 3938 3938 3939 3939 RenderView* view = renderer()->view(); -
trunk/Source/WebCore/rendering/RenderLayerBacking.cpp
r87880 r87989 358 358 IntPoint delta; 359 359 m_owningLayer->convertToLayerCoords(compAncestor, delta); 360 relativeCompositingBounds.move (delta);360 relativeCompositingBounds.moveBy(delta); 361 361 362 362 IntPoint graphicsLayerParentLocation; … … 1198 1198 context.translate(-scrollbarRect.x(), -scrollbarRect.y()); 1199 1199 IntRect transformedClip = clip; 1200 transformedClip.move (scrollbarRect.location());1200 transformedClip.moveBy(scrollbarRect.location()); 1201 1201 scrollbar->paint(&context, transformedClip); 1202 1202 context.restore(); … … 1232 1232 context.translate(-scrollCornerAndResizer.x(), -scrollCornerAndResizer.y()); 1233 1233 IntRect transformedClip = clip; 1234 transformedClip.move (scrollCornerAndResizer.location());1234 transformedClip.moveBy(scrollCornerAndResizer.location()); 1235 1235 m_owningLayer->paintScrollCorner(&context, IntPoint(), transformedClip); 1236 1236 m_owningLayer->paintResizer(&context, IntPoint(), transformedClip); -
trunk/Source/WebCore/rendering/RenderLayerCompositor.cpp
r87880 r87989 452 452 IntPoint ancestorRelOffset; 453 453 layer->convertToLayerCoords(ancestorLayer, ancestorRelOffset); 454 boundingBoxRect.move (ancestorRelOffset);454 boundingBoxRect.moveBy(ancestorRelOffset); 455 455 return boundingBoxRect; 456 456 } … … 506 506 IntPoint ancestorRelOffset; 507 507 layer->convertToLayerCoords(ancestorLayer, ancestorRelOffset); 508 unionBounds.move (ancestorRelOffset);508 unionBounds.moveBy(ancestorRelOffset); 509 509 510 510 return unionBounds; … … 530 530 IntPoint offset; 531 531 child->convertToLayerCoords(compLayer, offset); 532 compBounds.move (offset);532 compBounds.moveBy(offset); 533 533 534 534 compLayer->setBackingNeedsRepaintInRect(compBounds); … … 1437 1437 context.translate(-scrollbarRect.x(), -scrollbarRect.y()); 1438 1438 IntRect transformedClip = clip; 1439 transformedClip.move (scrollbarRect.location());1439 transformedClip.moveBy(scrollbarRect.location()); 1440 1440 scrollbar->paint(&context, transformedClip); 1441 1441 context.restore(); … … 1453 1453 context.translate(-scrollCorner.x(), -scrollCorner.y()); 1454 1454 IntRect transformedClip = clip; 1455 transformedClip.move (scrollCorner.location());1455 transformedClip.moveBy(scrollCorner.location()); 1456 1456 m_renderView->frameView()->paintScrollCorner(&context, transformedClip); 1457 1457 context.restore(); -
trunk/Source/WebCore/rendering/RenderListBox.cpp
r87773 r87989 691 691 { 692 692 IntRect clipRect = contentBoxRect(); 693 clipRect.move (additionalOffset);693 clipRect.moveBy(additionalOffset); 694 694 return clipRect; 695 695 } -
trunk/Source/WebCore/rendering/RenderListItem.cpp
r87303 r87989 339 339 if (o->hasSelfPaintingLayer()) 340 340 propagateVisualOverflow = false; 341 markerRect.move (-o->location());341 markerRect.moveBy(-o->location()); 342 342 } while (o != this && propagateVisualOverflow && propagateLayoutOverflow); 343 343 } -
trunk/Source/WebCore/rendering/RenderListMarker.cpp
r87866 r87989 1112 1112 IntPoint boxOrigin(tx + x(), ty + y()); 1113 1113 IntRect overflowRect(visualOverflowRect()); 1114 overflowRect.move (boxOrigin);1114 overflowRect.moveBy(boxOrigin); 1115 1115 overflowRect.inflate(maximalOutlineSize(paintInfo.phase)); 1116 1116 … … 1121 1121 1122 1122 IntRect marker = getRelativeMarkerRect(); 1123 marker.move (boxOrigin);1123 marker.moveBy(boxOrigin); 1124 1124 1125 1125 GraphicsContext* context = paintInfo.context; … … 1133 1133 if (selectionState() != SelectionNone) { 1134 1134 IntRect selRect = localSelectionRect(); 1135 selRect.move (boxOrigin);1135 selRect.moveBy(boxOrigin); 1136 1136 context->fillRect(selRect, selectionBackgroundColor(), style()->colorSpace()); 1137 1137 } … … 1147 1147 if (selectionState() != SelectionNone) { 1148 1148 IntRect selRect = localSelectionRect(); 1149 selRect.move (boxOrigin);1149 selRect.moveBy(boxOrigin); 1150 1150 context->fillRect(selRect, selectionBackgroundColor(), style()->colorSpace()); 1151 1151 } … … 1258 1258 GraphicsContextStateSaver stateSaver(*context, false); 1259 1259 if (!style()->isHorizontalWritingMode()) { 1260 marker.move (-boxOrigin);1260 marker.moveBy(-boxOrigin); 1261 1261 marker = marker.transposedRect(); 1262 1262 marker.move(box.x(), box.y() - logicalHeight()); -
trunk/Source/WebCore/rendering/RenderReplaced.cpp
r87801 r87989 142 142 143 143 if (!completelyClippedOut) { 144 paintReplaced(paintInfo, tx, ty);144 paintReplaced(paintInfo, IntPoint(tx, ty)); 145 145 146 146 if (style()->hasBorderRadius()) -
trunk/Source/WebCore/rendering/RenderReplaced.h
r71563 r87989 66 66 int calcAspectRatioLogicalHeight() const; 67 67 68 virtual void paintReplaced(PaintInfo&, int /*tx*/, int /*ty*/) { }68 virtual void paintReplaced(PaintInfo&, const IntPoint&) { } 69 69 70 70 virtual IntRect clippedOverflowRectForRepaint(RenderBoxModelObject* repaintContainer); -
trunk/Source/WebCore/rendering/RenderTableCell.cpp
r87387 r87989 295 295 RenderView* v = view(); 296 296 if ((!v || !v->layoutStateEnabled() || repaintContainer) && parent()) 297 r.move (-parentBox()->location()); // Rows are in the same coordinate space, so don't add their offset in.297 r.moveBy(-parentBox()->location()); // Rows are in the same coordinate space, so don't add their offset in. 298 298 RenderBlock::computeRectForRepaint(repaintContainer, r, fixed); 299 299 } -
trunk/Source/WebCore/rendering/RenderTextControlSingleLine.cpp
r87881 r87989 489 489 490 490 IntRect clipRect = IntRect(innerBlockElement()->renderBox()->frameRect()); 491 clipRect.move (additionalOffset);491 clipRect.moveBy(additionalOffset); 492 492 return clipRect; 493 493 } -
trunk/Source/WebCore/rendering/RenderVideo.cpp
r82051 r87989 185 185 } 186 186 187 void RenderVideo::paintReplaced(PaintInfo& paintInfo, int tx, int ty)187 void RenderVideo::paintReplaced(PaintInfo& paintInfo, const IntPoint& paintOffset) 188 188 { 189 189 MediaPlayer* mediaPlayer = mediaElement()->player(); … … 199 199 if (rect.isEmpty()) 200 200 return; 201 rect.move (tx, ty);201 rect.moveBy(paintOffset); 202 202 203 203 if (displayingPoster) -
trunk/Source/WebCore/rendering/RenderVideo.h
r68917 r87989 67 67 virtual bool isVideo() const { return true; } 68 68 69 virtual void paintReplaced(PaintInfo&, int tx, int ty);69 virtual void paintReplaced(PaintInfo&, const IntPoint&); 70 70 71 71 virtual void layout(); -
trunk/Source/WebCore/rendering/RenderView.cpp
r87467 r87989 274 274 // Subtract out the contentsX and contentsY offsets to get our coords within the viewing 275 275 // rectangle. 276 r.move (-vr.location());276 r.moveBy(-vr.location()); 277 277 278 278 // FIXME: Hardcoded offsets here are not good.
Note: See TracChangeset
for help on using the changeset viewer.