Use qt5 connect() syntax

This commit is contained in:
thalieht 2018-04-18 16:59:41 +03:00
parent 7af83ab704
commit 6b4455e13d
37 changed files with 198 additions and 175 deletions

View file

@ -86,7 +86,7 @@ ScanFoldersModel::ScanFoldersModel(QObject *parent)
, m_fsWatcher(nullptr)
{
configure();
connect(Preferences::instance(), SIGNAL(changed()), SLOT(configure()));
connect(Preferences::instance(), &Preferences::changed, this, &ScanFoldersModel::configure);
}
ScanFoldersModel::~ScanFoldersModel()
@ -222,7 +222,7 @@ ScanFoldersModel::PathStatus ScanFoldersModel::addPath(const QString &watchPath,
if (!m_fsWatcher) {
m_fsWatcher = new FileSystemWatcher(this);
connect(m_fsWatcher, SIGNAL(torrentsAdded(const QStringList &)), this, SLOT(addTorrentsToSession(const QStringList &)));
connect(m_fsWatcher, &FileSystemWatcher::torrentsAdded, this, &ScanFoldersModel::addTorrentsToSession);
}
beginInsertRows(QModelIndex(), rowCount(), rowCount());