1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-07-31 11:20:22 +02:00

* Resolved a bunch of hidden overloaded virtual methods in PlayableModel.

This commit is contained in:
Christian Muehlhaeuser
2012-06-29 02:25:35 +02:00
parent fdcd2aa728
commit bbc851fca2
2 changed files with 18 additions and 18 deletions

View File

@@ -633,12 +633,12 @@ PlayableModel::insertInternal( const QList< T >& items, int row )
void
PlayableModel::remove( int row, bool moreToCome )
{
remove( index( row, 0, QModelIndex() ), moreToCome );
removeIndex( index( row, 0, QModelIndex() ), moreToCome );
}
void
PlayableModel::remove( const QModelIndex& index, bool moreToCome )
PlayableModel::removeIndex( const QModelIndex& index, bool moreToCome )
{
if ( QThread::currentThread() != thread() )
{
@@ -666,7 +666,7 @@ PlayableModel::remove( const QModelIndex& index, bool moreToCome )
void
PlayableModel::remove( const QList<QModelIndex>& indexes )
PlayableModel::removeIndexes( const QList<QModelIndex>& indexes )
{
QList<QPersistentModelIndex> pil;
foreach ( const QModelIndex& idx, indexes )
@@ -674,12 +674,12 @@ PlayableModel::remove( const QList<QModelIndex>& indexes )
pil << idx;
}
remove( pil );
removeIndexes( pil );
}
void
PlayableModel::remove( const QList<QPersistentModelIndex>& indexes )
PlayableModel::removeIndexes( const QList<QPersistentModelIndex>& indexes )
{
QList<QPersistentModelIndex> finalIndexes;
foreach ( const QPersistentModelIndex index, indexes )
@@ -691,7 +691,7 @@ PlayableModel::remove( const QList<QPersistentModelIndex>& indexes )
for ( int i = 0; i < finalIndexes.count(); i++ )
{
remove( finalIndexes.at( i ), i + 1 != finalIndexes.count() );
removeIndex( finalIndexes.at( i ), i + 1 != finalIndexes.count() );
}
}

View File

@@ -151,9 +151,9 @@ public slots:
virtual void insert( const Tomahawk::album_ptr& album, int row = 0 );
virtual void remove( int row, bool moreToCome = false );
virtual void remove( const QModelIndex& index, bool moreToCome = false );
virtual void remove( const QList<QModelIndex>& indexes );
virtual void remove( const QList<QPersistentModelIndex>& indexes );
virtual void removeIndex( const QModelIndex& index, bool moreToCome = false );
virtual void removeIndexes( const QList<QModelIndex>& indexes );
virtual void removeIndexes( const QList<QPersistentModelIndex>& indexes );
virtual void setRepeatMode( Tomahawk::PlaylistModes::RepeatMode /*mode*/ ) {}
virtual void setShuffled( bool /*shuffled*/ ) {}