Changeset 86197 in webkit
- Timestamp:
- May 10, 2011 5:10:26 PM (13 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 1 deleted
- 23 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r86196 r86197 1 2011-05-10 Sheriff Bot <webkit.review.bot@gmail.com> 2 3 Unreviewed, rolling out r86195. 4 http://trac.webkit.org/changeset/86195 5 https://bugs.webkit.org/show_bug.cgi?id=60597 6 7 LayerOffset is a really bad name (Requested by smfr on 8 #webkit). 9 10 * GNUmakefile.list.am: 11 * WebCore.gypi: 12 * WebCore.pro: 13 * WebCore.vcproj/WebCore.vcproj: 14 * WebCore.xcodeproj/project.pbxproj: 15 * page/FrameView.cpp: 16 (WebCore::FrameView::paintScrollCorner): 17 * platform/graphics/LayerOffset.h: Removed. 18 * rendering/InlineTextBox.cpp: 19 (WebCore::InlineTextBox::paint): 20 (WebCore::InlineTextBox::paintCustomHighlight): 21 * rendering/InlineTextBox.h: 22 * rendering/RenderBox.cpp: 23 (WebCore::RenderBox::paintCustomHighlight): 24 * rendering/RenderBox.h: 25 * rendering/RenderImage.cpp: 26 (WebCore::RenderImage::paintReplaced): 27 * rendering/RenderLayer.cpp: 28 (WebCore::RenderLayer::paintScrollCorner): 29 (WebCore::RenderLayer::paintResizer): 30 * rendering/RenderListMarker.cpp: 31 (WebCore::RenderListMarker::paint): 32 * rendering/RenderObject.h: 33 * rendering/RenderScrollbar.cpp: 34 (WebCore::RenderScrollbar::paintPart): 35 * rendering/RenderScrollbarPart.cpp: 36 (WebCore::RenderScrollbarPart::paintIntoRect): 37 * rendering/RenderScrollbarPart.h: 38 * rendering/RenderTable.cpp: 39 (WebCore::RenderTable::paintObject): 40 (WebCore::RenderTable::paintMask): 41 * rendering/RenderTable.h: 42 * rendering/RenderWidget.cpp: 43 (WebCore::RenderWidget::paint): 44 * rendering/RootInlineBox.cpp: 45 (WebCore::RootInlineBox::paintCustomHighlight): 46 (WebCore::RootInlineBox::paint): 47 * rendering/RootInlineBox.h: 48 1 49 2011-05-10 Emil A Eklund <eae@chromium.org> 2 50 -
trunk/Source/WebCore/GNUmakefile.list.am
r86195 r86197 2440 2440 Source/WebCore/platform/graphics/IntSize.h \ 2441 2441 Source/WebCore/platform/graphics/IntSizeHash.h \ 2442 Source/WebCore/platform/graphics/LayerOffset.h \2443 2442 Source/WebCore/platform/graphics/MediaPlayer.cpp \ 2444 2443 Source/WebCore/platform/graphics/MediaPlayer.h \ -
trunk/Source/WebCore/WebCore.gypi
r86195 r86197 849 849 'platform/graphics/IntSize.h', 850 850 'platform/graphics/IntSizeHash.h', 851 'platform/graphics/LayerOffset.h',852 851 'platform/graphics/MediaPlayer.h', 853 852 'platform/graphics/Path.h', -
trunk/Source/WebCore/WebCore.pro
r86195 r86197 1952 1952 platform/graphics/IntPointHash.h \ 1953 1953 platform/graphics/IntRect.h \ 1954 platform/graphics/LayerOffset.h \1955 1954 platform/graphics/MediaPlayer.h \ 1956 1955 platform/graphics/Path.h \ -
trunk/Source/WebCore/WebCore.vcproj/WebCore.vcproj
r86195 r86197 26918 26918 </File> 26919 26919 <File 26920 RelativePath="..\platform\graphics\LayerOffset.h"26921 >26922 </File>26923 <File26924 26920 RelativePath="..\platform\graphics\MediaPlayer.cpp" 26925 26921 > -
trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj
r86195 r86197 4799 4799 B8DBDB4D130B0F8A00F5CDB1 /* SpellingCorrectionCommand.cpp in Sources */ = {isa = PBXBuildFile; fileRef = B8DBDB49130B0F8A00F5CDB1 /* SpellingCorrectionCommand.cpp */; }; 4800 4800 B8DBDB4E130B0F8A00F5CDB1 /* SpellingCorrectionCommand.h in Headers */ = {isa = PBXBuildFile; fileRef = B8DBDB4A130B0F8A00F5CDB1 /* SpellingCorrectionCommand.h */; }; 4801 BA5175C813789735008BFCBF /* LayerOffset.h in Headers */ = {isa = PBXBuildFile; fileRef = BA5175C713789735008BFCBF /* LayerOffset.h */; settings = {ATTRIBUTES = (Private, ); }; };4802 4801 BC00F0040E0A185500FD04E3 /* DOMFile.h in Headers */ = {isa = PBXBuildFile; fileRef = BC00EFFE0E0A185500FD04E3 /* DOMFile.h */; }; 4803 4802 BC00F0050E0A185500FD04E3 /* DOMFile.mm in Sources */ = {isa = PBXBuildFile; fileRef = BC00EFFF0E0A185500FD04E3 /* DOMFile.mm */; }; … … 11209 11208 B8DBDB49130B0F8A00F5CDB1 /* SpellingCorrectionCommand.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = SpellingCorrectionCommand.cpp; sourceTree = "<group>"; }; 11210 11209 B8DBDB4A130B0F8A00F5CDB1 /* SpellingCorrectionCommand.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SpellingCorrectionCommand.h; sourceTree = "<group>"; }; 11211 BA5175C713789735008BFCBF /* LayerOffset.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LayerOffset.h; sourceTree = "<group>"; };11212 11210 BC00EFFE0E0A185500FD04E3 /* DOMFile.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DOMFile.h; sourceTree = "<group>"; }; 11213 11211 BC00EFFF0E0A185500FD04E3 /* DOMFile.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = DOMFile.mm; sourceTree = "<group>"; }; … … 17685 17683 B27535470B053814002CE64F /* IntSize.h */, 17686 17684 B27535480B053814002CE64F /* IntSizeHash.h */, 17687 BA5175C713789735008BFCBF /* LayerOffset.h */,17688 17685 E4B41E0C0CBF90BD00AF2ECE /* MediaPlayer.cpp */, 17689 17686 E4B41E0D0CBF90BD00AF2ECE /* MediaPlayer.h */, … … 22752 22749 37AFFDF71370A0B800E895C0 /* SharedBufferCRLFLineReader.h in Headers */, 22753 22750 379E371713736A6600B9E919 /* QuotedPrintable.h in Headers */, 22754 BA5175C813789735008BFCBF /* LayerOffset.h in Headers */,22755 22751 FD1660A513787C6D001FFA7B /* DenormalDisabler.h in Headers */, 22756 22752 ); -
trunk/Source/WebCore/page/FrameView.cpp
r86195 r86197 2262 2262 2263 2263 if (m_scrollCorner) { 2264 m_scrollCorner->paintIntoRect(context, cornerRect. location(), cornerRect);2264 m_scrollCorner->paintIntoRect(context, cornerRect.x(), cornerRect.y(), cornerRect); 2265 2265 return; 2266 2266 } -
trunk/Source/WebCore/rendering/InlineTextBox.cpp
r86195 r86197 547 547 // Custom highlighters go behind everything else. 548 548 if (styleToUse->highlight() != nullAtom && !context->paintingDisabled()) 549 paintCustomHighlight( LayerOffset(tx, ty), styleToUse->highlight());549 paintCustomHighlight(tx, ty, styleToUse->highlight()); 550 550 #endif 551 551 … … 858 858 #if PLATFORM(MAC) 859 859 860 void InlineTextBox::paintCustomHighlight( LayerOffset layerOffset, const AtomicString& type)860 void InlineTextBox::paintCustomHighlight(int tx, int ty, const AtomicString& type) 861 861 { 862 862 Frame* frame = renderer()->frame(); … … 868 868 869 869 RootInlineBox* r = root(); 870 FloatRect rootRect( layerOffset.x() + r->x(), layerOffset.y()+ selectionTop(), r->logicalWidth(), selectionHeight());871 FloatRect textRect( layerOffset.x()+ x(), rootRect.y(), logicalWidth(), rootRect.height());870 FloatRect rootRect(tx + r->x(), ty + selectionTop(), r->logicalWidth(), selectionHeight()); 871 FloatRect textRect(tx + x(), rootRect.y(), logicalWidth(), rootRect.height()); 872 872 873 873 page->chrome()->client()->paintCustomHighlight(renderer()->node(), type, textRect, rootRect, true, false); -
trunk/Source/WebCore/rendering/InlineTextBox.h
r86195 r86197 166 166 void paintCompositionUnderline(GraphicsContext*, const FloatPoint& boxOrigin, const CompositionUnderline&); 167 167 #if PLATFORM(MAC) 168 void paintCustomHighlight( LayerOffset, const AtomicString& type);168 void paintCustomHighlight(int tx, int ty, const AtomicString& type); 169 169 #endif 170 170 -
trunk/Source/WebCore/rendering/RenderBox.cpp
r86195 r86197 1078 1078 #if PLATFORM(MAC) 1079 1079 1080 void RenderBox::paintCustomHighlight( LayerOffset layoutOffset, const AtomicString& type, bool behindText)1080 void RenderBox::paintCustomHighlight(int tx, int ty, const AtomicString& type, bool behindText) 1081 1081 { 1082 1082 Frame* frame = this->frame(); … … 1090 1090 RootInlineBox* r = boxWrap ? boxWrap->root() : 0; 1091 1091 if (r) { 1092 FloatRect rootRect( layoutOffset.x() + r->x(), layoutOffset.y()+ r->selectionTop(), r->logicalWidth(), r->selectionHeight());1093 FloatRect imageRect( location() + layoutOffset, IntSize(width(), rootRect.height()));1092 FloatRect rootRect(tx + r->x(), ty + r->selectionTop(), r->logicalWidth(), r->selectionHeight()); 1093 FloatRect imageRect(tx + x(), rootRect.y(), width(), rootRect.height()); 1094 1094 page->chrome()->client()->paintCustomHighlight(node(), type, imageRect, rootRect, behindText, false); 1095 1095 } else { 1096 FloatRect imageRect( location() + layoutOffset, IntSize(width(), height()));1096 FloatRect imageRect(tx + x(), ty + y(), width(), height()); 1097 1097 page->chrome()->client()->paintCustomHighlight(node(), type, imageRect, imageRect, behindText, false); 1098 1098 } -
trunk/Source/WebCore/rendering/RenderBox.h
r86195 r86197 413 413 414 414 #if PLATFORM(MAC) 415 void paintCustomHighlight( LayerOffset, const AtomicString& type, bool behindText);415 void paintCustomHighlight(int tx, int ty, const AtomicString& type, bool behindText); 416 416 #endif 417 417 -
trunk/Source/WebCore/rendering/RenderImage.cpp
r86195 r86197 303 303 #if PLATFORM(MAC) 304 304 if (style()->highlight() != nullAtom && !paintInfo.context->paintingDisabled()) 305 paintCustomHighlight( LayerOffset(tx - x(), ty - y()), style()->highlight(), true);305 paintCustomHighlight(tx - x(), ty - y(), style()->highlight(), true); 306 306 #endif 307 307 -
trunk/Source/WebCore/rendering/RenderLayer.cpp
r86196 r86197 2297 2297 2298 2298 if (m_scrollCorner) { 2299 m_scrollCorner->paintIntoRect(context, LayerOffset(tx, ty), absRect);2299 m_scrollCorner->paintIntoRect(context, tx, ty, absRect); 2300 2300 return; 2301 2301 } … … 2326 2326 2327 2327 if (m_resizer) { 2328 m_resizer->paintIntoRect(context, LayerOffset(tx, ty), absRect);2328 m_resizer->paintIntoRect(context, tx, ty, absRect); 2329 2329 return; 2330 2330 } -
trunk/Source/WebCore/rendering/RenderListMarker.cpp
r86195 r86197 1129 1129 #if PLATFORM(MAC) 1130 1130 if (style()->highlight() != nullAtom && !paintInfo.context->paintingDisabled()) 1131 paintCustomHighlight( LayerOffset(tx, ty), style()->highlight(), true);1131 paintCustomHighlight(tx, ty, style()->highlight(), true); 1132 1132 #endif 1133 1133 context->drawImage(m_image->image(this, marker.size()).get(), style()->colorSpace(), marker); … … 1143 1143 // FIXME: paint gap between marker and list item proper 1144 1144 if (style()->highlight() != nullAtom && !paintInfo.context->paintingDisabled()) 1145 paintCustomHighlight( LayerOffset(tx, ty), style()->highlight(), true);1145 paintCustomHighlight(tx, ty, style()->highlight(), true); 1146 1146 #endif 1147 1147 -
trunk/Source/WebCore/rendering/RenderObject.h
r86195 r86197 31 31 #include "Element.h" 32 32 #include "FloatQuad.h" 33 #include "LayerOffset.h"34 33 #include "PaintPhase.h" 35 34 #include "RenderObjectChildList.h" -
trunk/Source/WebCore/rendering/RenderScrollbar.cpp
r86195 r86197 276 276 if (!partRenderer) 277 277 return; 278 partRenderer->paintIntoRect(graphicsContext, pos(), rect);278 partRenderer->paintIntoRect(graphicsContext, x(), y(), rect); 279 279 } 280 280 -
trunk/Source/WebCore/rendering/RenderScrollbarPart.cpp
r86195 r86197 160 160 } 161 161 162 void RenderScrollbarPart::paintIntoRect(GraphicsContext* graphicsContext, LayerOffset layerOffset, const IntRect& rect)162 void RenderScrollbarPart::paintIntoRect(GraphicsContext* graphicsContext, int tx, int ty, const IntRect& rect) 163 163 { 164 164 // Make sure our dimensions match the rect. 165 setLocation(rect. location() - layerOffset.toSize());165 setLocation(rect.x() - tx, rect.y() - ty); 166 166 setWidth(rect.width()); 167 167 setHeight(rect.height()); … … 172 172 // Now do the paint. 173 173 PaintInfo paintInfo(graphicsContext, rect, PaintPhaseBlockBackground, false, 0, 0); 174 paint(paintInfo, layerOffset.x(), layerOffset.y());174 paint(paintInfo, tx, ty); 175 175 paintInfo.phase = PaintPhaseChildBlockBackgrounds; 176 paint(paintInfo, layerOffset.x(), layerOffset.y());176 paint(paintInfo, tx, ty); 177 177 paintInfo.phase = PaintPhaseFloat; 178 paint(paintInfo, layerOffset.x(), layerOffset.y());178 paint(paintInfo, tx, ty); 179 179 paintInfo.phase = PaintPhaseForeground; 180 paint(paintInfo, layerOffset.x(), layerOffset.y());180 paint(paintInfo, tx, ty); 181 181 paintInfo.phase = PaintPhaseOutline; 182 paint(paintInfo, layerOffset.x(), layerOffset.y());182 paint(paintInfo, tx, ty); 183 183 } 184 184 -
trunk/Source/WebCore/rendering/RenderScrollbarPart.h
r86195 r86197 27 27 #define RenderScrollbarPart_h 28 28 29 #include "LayerOffset.h"30 29 #include "RenderBlock.h" 31 30 #include "ScrollTypes.h" … … 47 46 virtual void computePreferredLogicalWidths(); 48 47 49 void paintIntoRect(GraphicsContext*, LayerOffset, const IntRect&);48 void paintIntoRect(GraphicsContext*, int tx, int ty, const IntRect&); 50 49 51 50 protected: -
trunk/Source/WebCore/rendering/RenderTable.cpp
r86195 r86197 481 481 482 482 if (paintPhase == PaintPhaseMask) { 483 paintMask(paintInfo, LayerOffset(tx, ty));483 paintMask(paintInfo, tx, ty); 484 484 return; 485 485 } … … 574 574 } 575 575 576 void RenderTable::paintMask(PaintInfo& paintInfo, LayerOffset layerOffset)576 void RenderTable::paintMask(PaintInfo& paintInfo, int tx, int ty) 577 577 { 578 578 if (style()->visibility() != VISIBLE || paintInfo.phase != PaintPhaseMask) 579 579 return; 580 580 581 IntRect rect( layerOffset.toPoint(), IntSize(width(), height()));581 IntRect rect(tx, ty, width(), height()); 582 582 subtractCaptionRect(rect); 583 583 -
trunk/Source/WebCore/rendering/RenderTable.h
r86195 r86197 218 218 virtual void paintObject(PaintInfo&, int tx, int ty); 219 219 virtual void paintBoxDecorations(PaintInfo&, int tx, int ty); 220 virtual void paintMask(PaintInfo&, LayerOffset);220 virtual void paintMask(PaintInfo&, int tx, int ty); 221 221 virtual void layout(); 222 222 virtual void computePreferredLogicalWidths(); -
trunk/Source/WebCore/rendering/RenderWidget.cpp
r86195 r86197 268 268 #if PLATFORM(MAC) 269 269 if (style()->highlight() != nullAtom && !paintInfo.context->paintingDisabled()) 270 paintCustomHighlight( LayerOffset(tx - x(), ty - y()), style()->highlight(), true);270 paintCustomHighlight(tx - x(), ty - y(), style()->highlight(), true); 271 271 #endif 272 272 -
trunk/Source/WebCore/rendering/RootInlineBox.cpp
r86195 r86197 158 158 } 159 159 160 void RootInlineBox::paintCustomHighlight(PaintInfo& paintInfo, LayerOffset layerOffset, const AtomicString& highlightType)160 void RootInlineBox::paintCustomHighlight(PaintInfo& paintInfo, int tx, int ty, const AtomicString& highlightType) 161 161 { 162 162 if (!paintInfo.shouldPaintWithinRoot(renderer()) || renderer()->style()->visibility() != VISIBLE || paintInfo.phase != PaintPhaseForeground) … … 171 171 172 172 // Get the inflated rect so that we can properly hit test. 173 FloatRect rootRect( layerOffset.x() + x(), layerOffset.y()+ selectionTop(), logicalWidth(), selectionHeight());173 FloatRect rootRect(tx + x(), ty + selectionTop(), logicalWidth(), selectionHeight()); 174 174 FloatRect inflatedRect = page->chrome()->client()->customHighlightRect(renderer()->node(), highlightType, rootRect); 175 175 if (inflatedRect.intersects(paintInfo.rect)) … … 186 186 RenderStyle* styleToUse = renderer()->style(m_firstLine); 187 187 if (styleToUse->highlight() != nullAtom && !paintInfo.context->paintingDisabled()) 188 paintCustomHighlight(paintInfo, LayerOffset(tx, ty), styleToUse->highlight());188 paintCustomHighlight(paintInfo, tx, ty, styleToUse->highlight()); 189 189 #endif 190 190 } -
trunk/Source/WebCore/rendering/RootInlineBox.h
r86195 r86197 93 93 #if PLATFORM(MAC) 94 94 void addHighlightOverflow(); 95 void paintCustomHighlight(PaintInfo&, LayerOffset, const AtomicString& highlightType);95 void paintCustomHighlight(PaintInfo&, int tx, int ty, const AtomicString& highlightType); 96 96 #endif 97 97
Note: See TracChangeset
for help on using the changeset viewer.