NOISSUE disable datapacks button in the world screen if no world is selected

This commit is contained in:
kb1000 2021-03-23 21:54:48 +01:00
parent cbc973a5af
commit 4f3328e71c
No known key found for this signature in database
GPG Key ID: C174DD765CC3E131

View File

@ -314,6 +314,7 @@ void WorldListPage::worldChanged(const QModelIndex &current, const QModelIndex &
ui->actionRemove->setEnabled(enable); ui->actionRemove->setEnabled(enable);
ui->actionCopy->setEnabled(enable); ui->actionCopy->setEnabled(enable);
ui->actionRename->setEnabled(enable); ui->actionRename->setEnabled(enable);
ui->actionDatapacks->setEnabled(enable);
bool hasIcon = !index.data(WorldList::IconFileRole).isNull(); bool hasIcon = !index.data(WorldList::IconFileRole).isNull();
ui->actionReset_Icon->setEnabled(enable && hasIcon); ui->actionReset_Icon->setEnabled(enable && hasIcon);
} }