Skip to content

Commit

Permalink
Set scanning threads idle priority
Browse files Browse the repository at this point in the history
(cherry picked from commit 5a57e28)
  • Loading branch information
jefferai authored and lfranchi committed Mar 30, 2012
1 parent 43c4daa commit 04864c7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/musicscanner.cpp
Expand Up @@ -173,6 +173,7 @@ MusicScanner::scan()
SLOT( commitBatch( QVariantList, QVariantList ) ), Qt::DirectConnection );

m_dirListerThreadController = new QThread( this );
m_dirListerThreadController->setPriority( QThread::IdlePriority );

m_dirLister = QWeakPointer< DirLister >( new DirLister( m_dirs ) );
m_dirLister.data()->moveToThread( m_dirListerThreadController );
Expand Down
1 change: 1 addition & 0 deletions src/scanmanager.cpp
Expand Up @@ -195,6 +195,7 @@ ScanManager::runDirScan()
{
m_scanTimer->stop();
m_musicScannerThreadController = new QThread( this );
m_musicScannerThreadController->setPriority( QThread::IdlePriority );
m_scanner = QWeakPointer< MusicScanner >( new MusicScanner( paths ) );
m_scanner.data()->moveToThread( m_musicScannerThreadController );
connect( m_scanner.data(), SIGNAL( finished() ), SLOT( scannerFinished() ) );
Expand Down

0 comments on commit 04864c7

Please sign in to comment.