1
Fork 0
mirror of https://github.com/redstrate/Astra.git synced 2025-04-21 04:07:46 +00:00

Prevent deletion of the initial default profile

This commit is contained in:
Joshua Goins 2022-04-14 16:52:36 -04:00
parent c907ed11d8
commit e5ebac764a

View file

@ -458,7 +458,7 @@ void SettingsWindow::reloadControls() {
showNewsList->setChecked(core.appSettings.showNewsList); showNewsList->setChecked(core.appSettings.showNewsList);
// deleting the main profile is unsupported behavior // deleting the main profile is unsupported behavior
deleteProfileButton->setEnabled(core.profileList().size() > 1); deleteProfileButton->setEnabled(profileWidget->currentRow() != 0);
ProfileSettings& profile = core.getProfile(profileWidget->currentRow()); ProfileSettings& profile = core.getProfile(profileWidget->currentRow());
nameEdit->setText(profile.name); nameEdit->setText(profile.name);