WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
[patch]
Patch
bug-83366-20120406162704.patch (text/plain), 5.20 KB, created by
Levi Weintraub
on 2012-04-06 07:27:06 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Levi Weintraub
Created:
2012-04-06 07:27:06 PDT
Size:
5.20 KB
patch
obsolete
>Index: Source/WebCore/ChangeLog >=================================================================== >--- Source/WebCore/ChangeLog (revision 113431) >+++ Source/WebCore/ChangeLog (working copy) >@@ -1,3 +1,26 @@ >+2012-04-06 Levi Weintraub <leviw@chromium.org> >+ >+ Correct some LayoutUnit misuse in FilterEffectRenderer, RenderBlock, and RenderEmbeddedObject >+ https://bugs.webkit.org/show_bug.cgi?id=83366 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Some more preparation of Render classes for FractionalLayoutUnits. See below for details >+ of each change. >+ >+ No new tests. No change in behavior. >+ >+ * rendering/FilterEffectRenderer.cpp: >+ (WebCore::FilterEffectRendererHelper::applyFilterEffect): Pixel snapping image rect before >+ drawing it. >+ * rendering/RenderBlock.cpp: >+ (WebCore::RenderBlock::baselinePosition): baselinePosition is a LayoutUnit, so it should >+ accumulate one internally to return. >+ (WebCore::::string): Pixel snapping outputted values for debug. >+ * rendering/RenderEmbeddedObject.cpp: >+ (WebCore::RenderEmbeddedObject::nodeAtPoint): Rounding the point we're analyzing before >+ passing it to integral scrollbar code. >+ > 2012-04-06 Levi Weintraub <leviw@chromium.org> > > Update LayoutUnit usage in RenderView >Index: Source/WebCore/rendering/FilterEffectRenderer.cpp >=================================================================== >--- Source/WebCore/rendering/FilterEffectRenderer.cpp (revision 113427) >+++ Source/WebCore/rendering/FilterEffectRenderer.cpp (working copy) >@@ -403,7 +403,7 @@ GraphicsContext* FilterEffectRendererHel > LayoutRect destRect = filter->outputRect(); > destRect.move(m_paintOffset.x(), m_paintOffset.y()); > >- m_savedGraphicsContext->drawImageBuffer(filter->output(), m_renderLayer->renderer()->style()->colorSpace(), destRect, CompositeSourceOver); >+ m_savedGraphicsContext->drawImageBuffer(filter->output(), m_renderLayer->renderer()->style()->colorSpace(), pixelSnappedIntRect(destRect), CompositeSourceOver); > > return m_savedGraphicsContext; > } >Index: Source/WebCore/rendering/RenderBlock.cpp >=================================================================== >--- Source/WebCore/rendering/RenderBlock.cpp (revision 113427) >+++ Source/WebCore/rendering/RenderBlock.cpp (working copy) >@@ -5916,9 +5916,9 @@ LayoutUnit RenderBlock::baselinePosition > bool ignoreBaseline = (layer() && (layer()->marquee() || (direction == HorizontalLine ? (layer()->verticalScrollbar() || layer()->scrollYOffset() != 0) > : (layer()->horizontalScrollbar() || layer()->scrollXOffset() != 0)))) || (isWritingModeRoot() && !isRubyRun()); > >- int baselinePos = ignoreBaseline ? LayoutUnit(-1) : lastLineBoxBaseline(); >+ LayoutUnit baselinePos = ignoreBaseline ? static_cast<LayoutUnit>(-1) : lastLineBoxBaseline(); > >- int bottomOfContent = direction == HorizontalLine ? borderTop() + paddingTop() + contentHeight() : borderRight() + paddingRight() + contentWidth(); >+ LayoutUnit bottomOfContent = direction == HorizontalLine ? borderTop() + paddingTop() + contentHeight() : borderRight() + paddingRight() + contentWidth(); > if (baselinePos != -1 && baselinePos <= bottomOfContent) > return direction == HorizontalLine ? marginTop() + baselinePos : marginRight() + baselinePos; > >@@ -7472,7 +7472,7 @@ String ValueToString<int>::string(const > > String ValueToString<RenderBlock::FloatingObject*>::string(const RenderBlock::FloatingObject* floatingObject) > { >- return String::format("%p (%dx%d %dx%d)", floatingObject, floatingObject->x(), floatingObject->y(), floatingObject->maxX(), floatingObject->maxY()); >+ return String::format("%p (%dx%d %dx%d)", floatingObject, floatingObject->pixelSnappedX(), floatingObject->pixelSnappedY(), floatingObject->pixelSnappedMaxX(), floatingObject->pixelSnappedMaxY()); > } > > #endif >Index: Source/WebCore/rendering/RenderEmbeddedObject.cpp >=================================================================== >--- Source/WebCore/rendering/RenderEmbeddedObject.cpp (revision 113427) >+++ Source/WebCore/rendering/RenderEmbeddedObject.cpp (working copy) >@@ -261,16 +261,17 @@ bool RenderEmbeddedObject::nodeAtPoint(c > return true; > > PluginViewBase* view = static_cast<PluginViewBase*>(widget()); >+ IntPoint roundedPoint = roundedIntPoint(pointInContainer); > > if (Scrollbar* horizontalScrollbar = view->horizontalScrollbar()) { >- if (horizontalScrollbar->shouldParticipateInHitTesting() && horizontalScrollbar->frameRect().contains(pointInContainer)) { >+ if (horizontalScrollbar->shouldParticipateInHitTesting() && horizontalScrollbar->frameRect().contains(roundedPoint)) { > result.setScrollbar(horizontalScrollbar); > return true; > } > } > > if (Scrollbar* verticalScrollbar = view->verticalScrollbar()) { >- if (verticalScrollbar->shouldParticipateInHitTesting() && verticalScrollbar->frameRect().contains(pointInContainer)) { >+ if (verticalScrollbar->shouldParticipateInHitTesting() && verticalScrollbar->frameRect().contains(roundedPoint)) { > result.setScrollbar(verticalScrollbar); > return true; > }
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 83366
:
136021
|
136247