From 25a2123e5ffe66715d0a1ec09297ee91a9fcbe1c Mon Sep 17 00:00:00 2001 From: Mikaƫl Capelle Date: Thu, 31 Dec 2020 21:24:29 +0100 Subject: Move keyboard event to PluginListView. --- src/mainwindow.cpp | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'src/mainwindow.cpp') diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 60e2a1e0..38417df5 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -2868,12 +2868,14 @@ void MainWindow::disableSelectedPlugins_clicked() void MainWindow::sendSelectedPluginsToTop_clicked() { - m_OrganizerCore.pluginList()->sendToPriority(ui->espList->selectionModel(), 0); + m_OrganizerCore.pluginList()->sendToPriority( + ui->espList->indexViewToModel(ui->espList->selectionModel()->selectedRows()), 0); } void MainWindow::sendSelectedPluginsToBottom_clicked() { - m_OrganizerCore.pluginList()->sendToPriority(ui->espList->selectionModel(), INT_MAX); + m_OrganizerCore.pluginList()->sendToPriority( + ui->espList->indexViewToModel(ui->espList->selectionModel()->selectedRows()), INT_MAX); } void MainWindow::sendSelectedPluginsToPriority_clicked() @@ -2884,7 +2886,8 @@ void MainWindow::sendSelectedPluginsToPriority_clicked() 0, 0, INT_MAX, 1, &ok); if (!ok) return; - m_OrganizerCore.pluginList()->sendToPriority(ui->espList->selectionModel(), newPriority); + m_OrganizerCore.pluginList()->sendToPriority( + ui->espList->indexViewToModel(ui->espList->selectionModel()->selectedRows()), newPriority); } void MainWindow::updateAvailable() -- cgit v1.3.1