Changed: Disable widgets if no profile selected

--HG--
branch : feature-ryzom-installer
This commit is contained in:
kervala 2016-03-12 21:59:29 +01:00
parent 0d06721689
commit d34b434b23

View file

@ -79,6 +79,15 @@ void CProfilesDialog::onProfileClicked(const QModelIndex &index)
void CProfilesDialog::displayProfile(int index)
{
bool enabled = index > -1;
profileIdLabel->setEnabled(enabled);
accountEdit->setEnabled(enabled);
nameEdit->setEnabled(enabled);
serverComboBox->setEnabled(enabled);
argumentsEdit->setEnabled(enabled);
commentsEdit->setEnabled(enabled);
if (index < 0) return;
saveProfile(m_currentProfileIndex);