summaryrefslogtreecommitdiffstats
path: root/src/gui/styles
diff options
context:
space:
mode:
authorOlivier Goffart <ogoffart@trolltech.com>2009-10-26 14:55:16 (GMT)
committerOlivier Goffart <ogoffart@trolltech.com>2009-10-27 11:52:38 (GMT)
commit11b1ced7cdc2af028164381d43c146ec79919f19 (patch)
treeabefca8174d2ab470775b4631cd45e8b21f58dfc /src/gui/styles
parentbc49cbaab3356770eb4b27dcbc2e585bf21e9200 (diff)
downloadQt-11b1ced7cdc2af028164381d43c146ec79919f19.zip
Qt-11b1ced7cdc2af028164381d43c146ec79919f19.tar.gz
Qt-11b1ced7cdc2af028164381d43c146ec79919f19.tar.bz2
Do not hardecode the ToolBar Icon Size
So we correctly get the size from the platform plugin Reviewed-by: jbache
Diffstat (limited to 'src/gui/styles')
-rw-r--r--src/gui/styles/qcommonstyle.cpp2
-rw-r--r--src/gui/styles/qplastiquestyle.cpp3
-rw-r--r--src/gui/styles/qwindowsstyle.cpp3
3 files changed, 1 insertions, 7 deletions
diff --git a/src/gui/styles/qcommonstyle.cpp b/src/gui/styles/qcommonstyle.cpp
index 5886512..b871842 100644
--- a/src/gui/styles/qcommonstyle.cpp
+++ b/src/gui/styles/qcommonstyle.cpp
@@ -4661,7 +4661,7 @@ int QCommonStyle::pixelMetric(PixelMetric m, const QStyleOption *opt, const QWid
case PM_ToolBarIconSize:
ret = qt_guiPlatformPlugin()->platformHint(QGuiPlatformPlugin::PH_ToolBarIconSize);
if (!ret)
- ret = proxy()->pixelMetric(PM_SmallIconSize, opt, widget);
+ ret = int(QStyleHelper::dpiScaled(24.));
break;
case PM_TabBarIconSize:
diff --git a/src/gui/styles/qplastiquestyle.cpp b/src/gui/styles/qplastiquestyle.cpp
index ce2109a..1f77d90 100644
--- a/src/gui/styles/qplastiquestyle.cpp
+++ b/src/gui/styles/qplastiquestyle.cpp
@@ -5514,9 +5514,6 @@ int QPlastiqueStyle::pixelMetric(PixelMetric metric, const QStyleOption *option,
case PM_MenuHMargin:
ret = 0;
break;
- case PM_ToolBarIconSize:
- ret = 24;
- break;
case PM_ButtonShiftHorizontal:
case PM_ButtonShiftVertical:
ret = 1;
diff --git a/src/gui/styles/qwindowsstyle.cpp b/src/gui/styles/qwindowsstyle.cpp
index 0f72440..5cf738e 100644
--- a/src/gui/styles/qwindowsstyle.cpp
+++ b/src/gui/styles/qwindowsstyle.cpp
@@ -454,9 +454,6 @@ int QWindowsStyle::pixelMetric(PixelMetric pm, const QStyleOption *opt, const QW
ret = proxy()->pixelMetric(PM_LargeIconSize, opt, widget);
break;
- case PM_ToolBarIconSize:
- ret = int(QStyleHelper::dpiScaled(24.));
- break;
case PM_DockWidgetTitleMargin:
ret = int(QStyleHelper::dpiScaled(2.));
break;