Windows: Use SM_CXSMICON instead of SM_CXICON for the tray icon size
Partially reverts b465fe7596.
Task-number: QTBUG-63447
Change-Id: Iaf8a54b59a054e33811f65f64322af3aa746885e
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
bb10
parent
b4ac552561
commit
92c61b11c1
|
|
@ -313,9 +313,8 @@ HICON QSystemTrayIconSys::createIcon()
|
|||
const QIcon icon = q->icon();
|
||||
if (icon.isNull())
|
||||
return oldIcon;
|
||||
const QSize requestedSize = QSysInfo::windowsVersion() >= QSysInfo::WV_VISTA
|
||||
? QSize(GetSystemMetrics(SM_CXICON), GetSystemMetrics(SM_CYICON))
|
||||
: QSize(GetSystemMetrics(SM_CXSMICON), GetSystemMetrics(SM_CYSMICON));
|
||||
// When merging this to 5.10, change at src/plugins/platforms/windows/qwindowssystemtrayicon.cpp:351.
|
||||
const QSize requestedSize = QSize(GetSystemMetrics(SM_CXSMICON), GetSystemMetrics(SM_CYSMICON));
|
||||
const QSize size = icon.actualSize(requestedSize);
|
||||
const QPixmap pm = icon.pixmap(size);
|
||||
if (pm.isNull())
|
||||
|
|
|
|||
Loading…
Reference in New Issue