Title: [100134] trunk/Source/WebCore
Revision
100134
Author
[email protected]
Date
2011-11-14 05:19:29 -0800 (Mon, 14 Nov 2011)

Log Message

[Qt] Unbreak the build on Mac OS X

QMacStyle is guarded by Q_WS_MAC, which is not the case for QPA. Until
that's been fixed in Qt we have to use the same guards in WebKit, not
Q_OS_MAC.

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (100133 => 100134)


--- trunk/Source/WebCore/ChangeLog	2011-11-14 13:19:12 UTC (rev 100133)
+++ trunk/Source/WebCore/ChangeLog	2011-11-14 13:19:29 UTC (rev 100134)
@@ -1,3 +1,19 @@
+2011-11-14  Tor Arne Vestbø  <[email protected]>
+
+        [Qt] Unbreak the build on Mac OS X
+
+        QMacStyle is guarded by Q_WS_MAC, which is not the case for QPA. Until
+        that's been fixed in Qt we have to use the same guards in WebKit, not
+        Q_OS_MAC.
+
+        * platform/qt/RenderThemeQStyle.cpp:
+        (WebCore::RenderThemeQStyle::RenderThemeQStyle):
+        (WebCore::RenderThemeQStyle::adjustButtonStyle):
+        (WebCore::RenderThemeQStyle::paintMenuList):
+        (WebCore::RenderThemeQStyle::paintInnerSpinButton):
+        * platform/qt/ScrollbarThemeQt.cpp:
+        (WebCore::ScrollbarThemeQt::paint):
+
 2011-11-14  Simon Hausmann  <[email protected]>
 
         [Qt] Replace use of QApplication with QGuiApplication.

Modified: trunk/Source/WebCore/platform/qt/RenderThemeQStyle.cpp (100133 => 100134)


--- trunk/Source/WebCore/platform/qt/RenderThemeQStyle.cpp	2011-11-14 13:19:12 UTC (rev 100133)
+++ trunk/Source/WebCore/platform/qt/RenderThemeQStyle.cpp	2011-11-14 13:19:29 UTC (rev 100134)
@@ -138,7 +138,7 @@
     QPushButton button;
     QFont defaultButtonFont = QApplication::font(&button);
     m_buttonFontFamily = defaultButtonFont.family();
-#ifdef Q_OS_MAC
+#ifdef Q_WS_MAC
     button.setAttribute(Qt::WA_MacSmallSize);
     QFontInfo fontInfo(defaultButtonFont);
     m_buttonFontPixelSize = fontInfo.pixelSize();
@@ -295,7 +295,7 @@
     // Ditch the border.
     style->resetBorder();
 
-#ifdef Q_OS_MAC
+#ifdef Q_WS_MAC
     if (style->appearance() == PushButtonPart) {
         // The Mac ports ignore the specified height for <input type="button"> elements
         // unless a border and/or background CSS property is also specified.
@@ -306,7 +306,7 @@
     FontDescription fontDescription = style->fontDescription();
     fontDescription.setIsAbsoluteSize(true);
 
-#ifdef Q_OS_MAC // Use fixed font size and family on Mac (like Safari does)
+#ifdef Q_WS_MAC // Use fixed font size and family on Mac (like Safari does)
     fontDescription.setSpecifiedSize(m_buttonFontPixelSize);
     fontDescription.setComputedSize(m_buttonFontPixelSize);
 #else
@@ -459,7 +459,7 @@
 
     IntRect rect = r;
 
-#if defined(Q_OS_MAC) && !defined(QT_NO_STYLE_MAC)
+#if defined(Q_WS_MAC) && !defined(QT_NO_STYLE_MAC)
     // QMacStyle makes the combo boxes a little bit smaller to leave space for the focus rect.
     // Because of it, the combo button is drawn at a point to the left of where it was expect to be and may end up
     // overlapped with the text. This will force QMacStyle to draw the combo box with the expected width.
@@ -711,7 +711,7 @@
     // Default to moving the buttons a little bit within the editor frame.
     int inflateX = -2;
     int inflateY = -2;
-#if defined(Q_OS_MAC) && !defined(QT_NO_STYLE_MAC)
+#if defined(Q_WS_MAC) && !defined(QT_NO_STYLE_MAC)
     // QMacStyle will position the aqua buttons flush to the right.
     // This will move them more within the control for better style, a la
     // Chromium look & feel.

Modified: trunk/Source/WebCore/platform/qt/ScrollbarThemeQt.cpp (100133 => 100134)


--- trunk/Source/WebCore/platform/qt/ScrollbarThemeQt.cpp	2011-11-14 13:19:12 UTC (rev 100133)
+++ trunk/Source/WebCore/platform/qt/ScrollbarThemeQt.cpp	2011-11-14 13:19:29 UTC (rev 100134)
@@ -41,7 +41,7 @@
 #include "Scrollbar.h"
 
 #include <QApplication>
-#ifdef Q_OS_MAC
+#ifdef Q_WS_MAC
 #include <QMacStyle>
 #endif
 #include <QMenu>
@@ -171,7 +171,7 @@
 
     p.painter->setClipRect(opt->rect.intersected(damageRect), Qt::IntersectClip);
 
-#ifdef Q_OS_MAC
+#ifdef Q_WS_MAC
     // FIXME: We also need to check the widget style but today ScrollbarTheme is not aware of the page so we
     // can't get the widget.
     if (qobject_cast<QMacStyle*>(style()))
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to