]> Shamusworld >> Repos - virtualjaguar/blobdiff - src/gui/filepicker.cpp
Initial stab at controller UI.
[virtualjaguar] / src / gui / filepicker.cpp
index 288605274d0dc47d6978dc6eb3b2414b093f5ff8..86fbe55b410d25cb62cc1776099a5aed63c06a78 100644 (file)
@@ -198,6 +198,12 @@ New sizes: 373x172 (label), 420x340 (cart)
        connect(fileList->selectionModel(), SIGNAL(currentChanged(const QModelIndex &, const QModelIndex &)), this, SLOT(UpdateSelection(const QModelIndex &, const QModelIndex &)));
 
        connect(insertCart, SIGNAL(clicked()), this, SLOT(LoadButtonPressed()));
+
+       connect(fileList, SIGNAL(doubleClicked(const QModelIndex &)), this, SLOT(CatchDoubleClick(const QModelIndex &)));
+
+//     connect(fileList, SIGNAL(doubleClicked()), this, SLOT(LoadButtonPressed()));
+// This returns:
+// Object::connect: No such signal QListView::QAbstractItemView::doubleClicked() in src/gui/filepicker.cpp:203
 }
 
 void FilePickerWindow::keyPressEvent(QKeyEvent * e)
@@ -208,6 +214,11 @@ void FilePickerWindow::keyPressEvent(QKeyEvent * e)
                LoadButtonPressed();
 }
 
+void FilePickerWindow::CatchDoubleClick(const QModelIndex &)
+{
+       LoadButtonPressed();
+}
+
 QString FilePickerWindow::GetSelectedPrettyName(void)
 {
        return prettyFilename;