summaryrefslogtreecommitdiffstats
path: root/gui/versionselectdialog.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'gui/versionselectdialog.cpp')
-rw-r--r--gui/versionselectdialog.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/gui/versionselectdialog.cpp b/gui/versionselectdialog.cpp
index b55c106c..6ead83c0 100644
--- a/gui/versionselectdialog.cpp
+++ b/gui/versionselectdialog.cpp
@@ -21,6 +21,7 @@
#include <gui/taskdialog.h>
#include <instversionlist.h>
+#include <instversion.h>
#include <task.h>
VersionSelectDialog::VersionSelectDialog(InstVersionList *vlist, QWidget *parent) :
@@ -56,6 +57,15 @@ void VersionSelectDialog::loadList()
taskDlg->exec(loadTask);
}
+const InstVersion *VersionSelectDialog::selectedVersion() const
+{
+ const InstVersion *versionPtr = (const InstVersion *)
+ m_vlist->data(ui->listView->selectionModel()->currentIndex(),
+ InstVersionList::VersionPointerRole).value<void *>();
+
+ return versionPtr;
+}
+
void VersionSelectDialog::on_refreshButton_clicked()
{
loadList();