mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-06 14:16:32 +02:00
* Style fix for JobStatusModel.
This commit is contained in:
@@ -24,10 +24,10 @@
|
|||||||
|
|
||||||
#include <QPixmap>
|
#include <QPixmap>
|
||||||
|
|
||||||
|
|
||||||
JobStatusModel::JobStatusModel( QObject* parent )
|
JobStatusModel::JobStatusModel( QObject* parent )
|
||||||
: QAbstractListModel ( parent )
|
: QAbstractListModel ( parent )
|
||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -52,10 +52,9 @@ JobStatusModel::addJob( JobStatusItem* item )
|
|||||||
currentJobCount++;
|
currentJobCount++;
|
||||||
m_jobTypeCount[ item->type() ] = currentJobCount;
|
m_jobTypeCount[ item->type() ] = currentJobCount;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
connect( item, SIGNAL( statusChanged() ), SLOT( itemUpdated() ) );
|
||||||
connect( item, SIGNAL( statusChanged() ), this, SLOT( itemUpdated() ) );
|
connect( item, SIGNAL( finished() ), SLOT( itemFinished() ) );
|
||||||
connect( item, SIGNAL( finished() ), this, SLOT( itemFinished() ) );
|
|
||||||
|
|
||||||
if ( item->collapseItem() )
|
if ( item->collapseItem() )
|
||||||
{
|
{
|
||||||
@@ -77,6 +76,7 @@ JobStatusModel::addJob( JobStatusItem* item )
|
|||||||
beginInsertRows( QModelIndex(), currentEndRow, currentEndRow );
|
beginInsertRows( QModelIndex(), currentEndRow, currentEndRow );
|
||||||
m_items.append( item );
|
m_items.append( item );
|
||||||
endInsertRows();
|
endInsertRows();
|
||||||
|
|
||||||
if ( item->hasCustomDelegate() )
|
if ( item->hasCustomDelegate() )
|
||||||
{
|
{
|
||||||
tDebug( LOGVERBOSE ) << Q_FUNC_INFO << "job has custom delegate";
|
tDebug( LOGVERBOSE ) << Q_FUNC_INFO << "job has custom delegate";
|
||||||
@@ -228,5 +228,4 @@ JobStatusModel::itemUpdated()
|
|||||||
|
|
||||||
const QModelIndex idx = index( m_items.indexOf( item ), 0, QModelIndex() );
|
const QModelIndex idx = index( m_items.indexOf( item ), 0, QModelIndex() );
|
||||||
emit dataChanged( idx, idx );
|
emit dataChanged( idx, idx );
|
||||||
return;
|
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user