mirror of
https://github.com/PrismLauncher/PrismLauncher.git
synced 2025-06-12 05:07:46 +02:00
Add Change Version action to all pages
Signed-off-by: TheKodeToad <TheKodeToad@proton.me>
This commit is contained in:
@ -316,6 +316,10 @@ void ExternalResourcesPage::updateActions()
|
||||
const bool hasSelection = ui->treeView->selectionModel()->hasSelection();
|
||||
ui->actionUpdateItem->setEnabled(!m_model->empty());
|
||||
ui->actionResetItemMetadata->setEnabled(hasSelection);
|
||||
|
||||
const QModelIndexList rows = ui->treeView->selectionModel()->selectedRows();
|
||||
ui->actionChangeVersion->setEnabled(rows.count() == 1 && m_model->at(m_filterModel->mapToSource(rows[0]).row()).metadata() != nullptr);
|
||||
|
||||
ui->actionRemoveItem->setEnabled(hasSelection);
|
||||
ui->actionEnableItem->setEnabled(hasSelection);
|
||||
ui->actionDisableItem->setEnabled(hasSelection);
|
||||
|
Reference in New Issue
Block a user