fix: changed paletteType's config value

We only save config's value when caller update paletteType manually.
This commit is contained in:
YeShanShan 2024-02-28 16:52:45 +08:00 committed by mike
parent 754d5baff5
commit 8561847a13
1 changed files with 1 additions and 2 deletions

View File

@ -413,8 +413,6 @@ void DGuiApplicationHelperPrivate::setPaletteType(DGuiApplicationHelper::ColorTy
D_Q(DGuiApplicationHelper);
Q_EMIT q->paletteTypeChanged(paletteType);
_d_dconfig->setValue(APP_THEME_TYPE, paletteType);
}
void DGuiApplicationHelperPrivate::initPaletteType() const
@ -1773,6 +1771,7 @@ void DGuiApplicationHelper::setPaletteType(DGuiApplicationHelper::ColorType pale
d->initPaletteType();
d->setPaletteType(paletteType, true);
_d_dconfig->setValue(APP_THEME_TYPE, paletteType);
}
/*!