Add null check for face in instance account settings selector
Co-authored-by: flow <flowlnlnln@gmail.com> Signed-off-by: Aaron Sonin <10217842+byteduck@users.noreply.github.com> Signed-off-by: Aaron <10217842+byteduck@users.noreply.github.com>
This commit is contained in:
parent
021e6c02d7
commit
e186523878
@ -514,7 +514,11 @@ void InstanceSettingsPage::changeInstanceAccount()
|
||||
m_settings->set("InstanceAccountId", account->profileId());
|
||||
|
||||
ui->instanceAccountSelector->setText(account->profileName());
|
||||
ui->instanceAccountSelector->setIcon(account->getFace());
|
||||
if (auto face = account->getFace(); !face.isNull()) {
|
||||
ui->instanceAccountSelector->setIcon(face);
|
||||
} else {
|
||||
ui->instanceAccountSelector->setIcon(APPLICATION->getThemedIcon("noaccount"));
|
||||
}
|
||||
}
|
||||
|
||||
void InstanceSettingsPage::on_maxMemSpinBox_valueChanged(int i)
|
||||
|
Loading…
Reference in New Issue
Block a user