Disable edit button in the Launcher if we start with a built-in profile

This commit is contained in:
Alexander Bock
2025-08-16 12:19:32 +02:00
committed by Alexander Bock
parent 9b35f45430
commit 49183b8f26

View File

@@ -240,7 +240,9 @@ LauncherWindow::LauncherWindow(bool profileEnabled, const Configuration& globalC
{
// Set up the default value for the edit button
std::string selection = std::get<1>(_profileBox->currentSelection());
_editProfileButton->setEnabled(std::filesystem::exists(selection));
const bool exists = std::filesystem::exists(selection);
const bool isUser = selection.starts_with(_userProfilePath.string());
_editProfileButton->setEnabled(isUser && exists);
}
{