1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-07-30 19:00:12 +02:00

Use less Closure arguments.

This commit is contained in:
Christian Muehlhaeuser
2015-03-19 09:21:52 +01:00
parent 3394deea46
commit 8fb9ddcc27
2 changed files with 6 additions and 3 deletions

View File

@@ -147,7 +147,7 @@ PlaylistItemDelegate::createEditor( QWidget* parent, const QStyleOptionViewItem&
editor->addItems( formats );
_detail::Closure* closure = NewClosure( editor, SIGNAL( activated( int ) ),
const_cast<PlaylistItemDelegate*>(this), SLOT( closeEditor( const QModelIndex&, PlayableItem*, QComboBox* ) ), index, item, editor );
const_cast<PlaylistItemDelegate*>(this), SLOT( closeEditor( const QModelIndex&, QWidget* ) ), index, editor );
return editor;
}
@@ -156,8 +156,11 @@ PlaylistItemDelegate::createEditor( QWidget* parent, const QStyleOptionViewItem&
void
PlaylistItemDelegate::closeEditor( const QModelIndex& index, PlayableItem* item, QComboBox* editor )
PlaylistItemDelegate::closeEditor( const QModelIndex& index, QWidget* editor )
{
PlayableItem* item = m_model->itemFromIndex( m_model->mapToSource( index ) );
Q_ASSERT( item );
m_view->closePersistentEditor( index );
QComboBox* cb = static_cast< QComboBox* >(editor);

View File

@@ -57,7 +57,7 @@ signals:
private slots:
void doUpdateIndex( const QPersistentModelIndex& index );
void closeEditor( const QModelIndex& index, PlayableItem* item, QComboBox* editor );
void closeEditor( const QModelIndex& index, QWidget* editor );
protected:
void prepareStyleOption( QStyleOptionViewItemV4* option, const QModelIndex& index, PlayableItem* item ) const;