From: APTX Date: Tue, 3 Jul 2012 13:24:20 +0000 (+0200) Subject: Disable expanding on double click. Open file instead X-Git-Url: https://gitweb.tyo.aptx.org/?a=commitdiff_plain;h=8604a3f84b60cf96e763af1fdab89afa6166efd8;p=localmylist.git Disable expanding on double click. Open file instead --- diff --git a/management-gui/mylistview.cpp b/management-gui/mylistview.cpp index de59d76..8f1f24e 100644 --- a/management-gui/mylistview.cpp +++ b/management-gui/mylistview.cpp @@ -14,6 +14,9 @@ MyListView::MyListView(QWidget *parent) : setContextMenuPolicy(Qt::CustomContextMenu); connect(this, SIGNAL(customContextMenuRequested(QPoint)), this, SLOT(showCustomContextMenu(QPoint))); + this->setExpandsOnDoubleClick(false); + connect(this, SIGNAL(doubleClicked(QModelIndex)), this, SIGNAL(openFileRequested(QModelIndex))); + openAction = new QAction(tr("Open"), this); connect(openAction, SIGNAL(triggered()), this, SLOT(requestOpenFile())); openNextAction = new QAction(tr("Open Next"), this);