Commit 0eaf7627 authored by Kai Uwe Broulik's avatar Kai Uwe Broulik 🍇

Drop QWindow and explicit devicePixelRatio usage for ComboBox

It's not done anywhere and breaks rendering the ComboBox on high dpi.

Differential Revision: https://phabricator.kde.org/D28725
parent a1e1a53f
......@@ -4463,17 +4463,7 @@ namespace Breeze
mode = QIcon::Disabled;
}
QWindow *window = nullptr;
if (widget && widget->window()) {
window = widget->window()->windowHandle();
#if BREEZE_HAVE_QTQUICK
} else if (QQuickItem *quickItem = qobject_cast<QQuickItem *>(option->styleObject)) {
window = quickItem->window();
#endif
}
auto pixmap = _helper->coloredIcon(cb->currentIcon,cb->palette, cb->iconSize * window->devicePixelRatio(), mode);
pixmap.setDevicePixelRatio(window->devicePixelRatio());
const QPixmap pixmap = _helper->coloredIcon(cb->currentIcon,cb->palette, cb->iconSize, mode);
auto iconRect(editRect);
iconRect.setWidth(cb->iconSize.width() + 4);
iconRect = alignedRect(cb->direction,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment