fix: only use window scale in children (#5833)

This commit is contained in:
nerix
2025-01-19 11:10:41 +01:00
committed by GitHub
parent 7f9b33051e
commit b0fee11621
2 changed files with 7 additions and 2 deletions
+6 -1
View File
@@ -19,8 +19,13 @@ namespace chatterino {
BaseWidget::BaseWidget(QWidget *parent, Qt::WindowFlags f)
: QWidget(parent, f)
, theme(getApp()->getThemes())
, scale_(this->scale())
{
auto *baseWidget = dynamic_cast<BaseWidget *>(this->window());
if (baseWidget && baseWidget != this)
{
this->scale_ = baseWidget->scale_;
}
this->signalHolder_.managedConnect(this->theme->updated, [this]() {
this->themeChangedEvent();