diff options
author | Arno <am@disconnect.de> | 2010-05-14 15:25:39 +0200 |
---|---|---|
committer | Arno <am@disconnect.de> | 2010-05-14 15:25:39 +0200 |
commit | a785a3f264c0efad18e3e459158c22af081db9b1 (patch) | |
tree | 46de18d109979f2250d1491b8f64eb875c3ef4ff /shemov.cpp | |
parent | 8557681bb922613603eae641e88746eaa16914a4 (diff) | |
download | SheMov-a785a3f264c0efad18e3e459158c22af081db9b1.tar.gz SheMov-a785a3f264c0efad18e3e459158c22af081db9b1.tar.bz2 SheMov-a785a3f264c0efad18e3e459158c22af081db9b1.zip |
Fix calls to setFsFree()
Move connect() to constructor and also recalculate free space after
removing files by connecting to rowsRemoved(QModelIndex,int,int).
Diffstat (limited to 'shemov.cpp')
-rw-r--r-- | shemov.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -98,6 +98,9 @@ SheMov::SheMov(QWidget *parent, Qt::WindowFlags flags) : QMainWindow(parent, fla connect(mFSWidget, SIGNAL(newTemplate(const QString &)), this, SLOT(setTemplate(const QString &))); connect(mAVWidget, SIGNAL(statusbarMessage(const QString &)), this, SLOT(statusbarMessage(const QString &))); connect(mTab, SIGNAL(currentChanged(int)), this, SLOT(tabChanged(int))); + connect(mFSWidget->dirModel(), SIGNAL(dataChanged(QModelIndex,QModelIndex)), this, SLOT(setFsFree())); + connect(mFSWidget->dirModel(), SIGNAL(layoutChanged()), this, SLOT(setFsFree())); + connect(mFSWidget->dirModel(), SIGNAL(rowsRemoved(QModelIndex,int,int)), this, SLOT(setFsFree())); QWidget *centralWidget = new QWidget; centralWidget->setLayout(mainLayout); @@ -351,8 +354,7 @@ void SheMov::createActions(){ mOpenWithMapperAV = new QSignalMapper(this); connect(mOpenWithMapperFS, SIGNAL(mapped(QString)), mFSWidget, SLOT(playSelected(QString))); connect(mOpenWithMapperAV, SIGNAL(mapped(QString)), mAVWidget, SLOT(playSelected(QString))); - connect(mFSWidget->dirModel(), SIGNAL(dataChanged(QModelIndex,QModelIndex)), this, SLOT(setFsFree())); - connect(mFSWidget->dirModel(), SIGNAL(layoutChanged()), this, SLOT(setFsFree())); + } void SheMov::createMenus(){ |