Title: [109974] branches/subpixellayout/Source/WebCore/platform

Diff

Modified: branches/subpixellayout/Source/WebCore/platform/Theme.h (109973 => 109974)


--- branches/subpixellayout/Source/WebCore/platform/Theme.h	2012-03-07 00:16:41 UTC (rev 109973)
+++ branches/subpixellayout/Source/WebCore/platform/Theme.h	2012-03-07 00:24:39 UTC (rev 109974)
@@ -49,7 +49,7 @@
     // position cannot be determined by examining child content. Checkboxes and radio buttons are examples of
     // controls that need to do this.  The adjustment is an offset that adds to the baseline, e.g., marginTop() + height() + |offset|.
     // The offset is not zoomed.
-    virtual LayoutUnit baselinePositionAdjustment(ControlPart) const { return 0; }
+    virtual int baselinePositionAdjustment(ControlPart) const { return 0; }
 
     // A method asking if the control changes its appearance when the window is inactive.
     virtual bool controlHasInactiveAppearance(ControlPart) const { return false; }

Modified: branches/subpixellayout/Source/WebCore/platform/chromium/ThemeChromiumMac.h (109973 => 109974)


--- branches/subpixellayout/Source/WebCore/platform/chromium/ThemeChromiumMac.h	2012-03-07 00:16:41 UTC (rev 109973)
+++ branches/subpixellayout/Source/WebCore/platform/chromium/ThemeChromiumMac.h	2012-03-07 00:24:39 UTC (rev 109974)
@@ -39,7 +39,7 @@
     ThemeChromiumMac() { }
     virtual ~ThemeChromiumMac() { }
     
-    virtual LayoutUnit baselinePositionAdjustment(ControlPart) const;
+    virtual int baselinePositionAdjustment(ControlPart) const;
 
     virtual FontDescription controlFont(ControlPart, const Font&, float zoomFactor) const;
     

Modified: branches/subpixellayout/Source/WebCore/platform/graphics/qt/GraphicsContextQt.cpp (109973 => 109974)


--- branches/subpixellayout/Source/WebCore/platform/graphics/qt/GraphicsContextQt.cpp	2012-03-07 00:16:41 UTC (rev 109973)
+++ branches/subpixellayout/Source/WebCore/platform/graphics/qt/GraphicsContextQt.cpp	2012-03-07 00:24:39 UTC (rev 109974)
@@ -45,7 +45,6 @@
 #include "AffineTransform.h"
 #include "Color.h"
 #include "FloatConversion.h"
-#include "FractionalLayoutRect.h"
 #include "Font.h"
 #include "ImageBuffer.h"
 #include "NotImplemented.h"
@@ -795,7 +794,7 @@
     else
         clipRect = p->transform().inverted().mapRect(p->window());
 
-    return enclosingIntRect(FractionalLayoutRect(clipRect));
+    return enclosingIntRect(clipRect);
 }
 
 void GraphicsContext::clipPath(const Path& path, WindRule clipRule)
@@ -857,7 +856,7 @@
     int radius = (width - 1) / 2;
     QPainterPath path;
     for (unsigned i = 0; i < rectCount; ++i) {
-        QRect rect = QRect(rects[i]).adjusted(-offset - radius, -offset - radius, offset + radius, offset + radius);
+        QRect rect = QRect((rects[i])).adjusted(-offset - radius, -offset - radius, offset + radius, offset + radius);
         // This is not the most efficient way to add a rect to a path, but if we don't create the tmpPath,
         // we will end up with ugly lines in between rows of text on anchors with multiple lines.
         QPainterPath tmpPath;

Modified: branches/subpixellayout/Source/WebCore/platform/mac/ThemeMac.h (109973 => 109974)


--- branches/subpixellayout/Source/WebCore/platform/mac/ThemeMac.h	2012-03-07 00:16:41 UTC (rev 109973)
+++ branches/subpixellayout/Source/WebCore/platform/mac/ThemeMac.h	2012-03-07 00:24:39 UTC (rev 109974)
@@ -35,7 +35,7 @@
     ThemeMac() { }
     virtual ~ThemeMac() { }
     
-    virtual LayoutUnit baselinePositionAdjustment(ControlPart) const;
+    virtual int baselinePositionAdjustment(ControlPart) const;
 
     virtual FontDescription controlFont(ControlPart, const Font&, float zoomFactor) const;
     

Modified: branches/subpixellayout/Source/WebCore/platform/mac/ThemeMac.mm (109973 => 109974)


--- branches/subpixellayout/Source/WebCore/platform/mac/ThemeMac.mm	2012-03-07 00:16:41 UTC (rev 109973)
+++ branches/subpixellayout/Source/WebCore/platform/mac/ThemeMac.mm	2012-03-07 00:24:39 UTC (rev 109974)
@@ -605,7 +605,7 @@
     
 // Theme overrides
 
-LayoutUnit ThemeMac::baselinePositionAdjustment(ControlPart part) const
+int ThemeMac::baselinePositionAdjustment(ControlPart part) const
 {
     if (part == CheckboxPart || part == RadioPart)
         return -2;

Modified: branches/subpixellayout/Source/WebCore/platform/qt/RenderThemeQt.cpp (109973 => 109974)


--- branches/subpixellayout/Source/WebCore/platform/qt/RenderThemeQt.cpp	2012-03-07 00:16:41 UTC (rev 109973)
+++ branches/subpixellayout/Source/WebCore/platform/qt/RenderThemeQt.cpp	2012-03-07 00:24:39 UTC (rev 109974)
@@ -179,7 +179,7 @@
     }
 }
 
-int RenderThemeQt::baselinePosition(const RenderObject* o) const
+LayoutUnit RenderThemeQt::baselinePosition(const RenderObject* o) const
 {
     if (!o->isBox())
         return 0;
@@ -434,7 +434,7 @@
 IntRect RenderThemeQt::convertToPaintingRect(RenderObject* inputRenderer, const RenderObject* partRenderer, IntRect partRect, const IntRect& localOffset) const
 {
     // Compute an offset between the part renderer and the input renderer.
-    IntSize offsetFromInputRenderer = -expandedIntSize(partRenderer->offsetFromAncestorContainer(inputRenderer));
+    IntSize offsetFromInputRenderer = -(partRenderer->offsetFromAncestorContainer(inputRenderer));
     // Move the rect into partRenderer's coords.
     partRect.move(offsetFromInputRenderer);
     // Account for the local drawing offset.
@@ -453,7 +453,7 @@
     if (!input->renderer()->isBox())
         return false;
     RenderBox* inputRenderBox = toRenderBox(input->renderer());
-    IntRect inputContentBox = enclosingIntRect(inputRenderBox->contentBoxRect());
+    IntRect inputContentBox = inputRenderBox->contentBoxRect();
 
     // Make sure the scaled button stays square and will fit in its parent's box.
     int cancelButtonSize = qMin(inputContentBox.width(), qMin(inputContentBox.height(), r.height()));

Modified: branches/subpixellayout/Source/WebCore/platform/win/PopupMenuWin.cpp (109973 => 109974)


--- branches/subpixellayout/Source/WebCore/platform/win/PopupMenuWin.cpp	2012-03-07 00:16:41 UTC (rev 109973)
+++ branches/subpixellayout/Source/WebCore/platform/win/PopupMenuWin.cpp	2012-03-07 00:24:39 UTC (rev 109974)
@@ -340,7 +340,7 @@
         popupWidth += ScrollbarTheme::theme()->scrollbarThickness(SmallScrollbar);
 
     // Add padding to align the popup text with the <select> text
-    popupWidth += max<int>(0, client()->clientPaddingRight() - client()->clientInsetRight()) + max<int>(0, client()->clientPaddingLeft() - client()->clientInsetLeft());
+    popupWidth += max(0, client()->clientPaddingRight() - client()->clientInsetRight()) + max(0, client()->clientPaddingLeft() - client()->clientInsetLeft());
 
     // Leave room for the border
     popupWidth += 2 * popupWindowBorderWidth;
@@ -661,7 +661,7 @@
     }
 
     if (m_scrollbar)
-        m_scrollbar->paint(&context, enclosingIntRect(damageRect));
+        m_scrollbar->paint(&context, pixelSnappedIntRect(damageRect));
 
     HWndDC hWndDC;
     HDC localDC = hdc ? hdc : hWndDC.setHWnd(m_popup);
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to