mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-15 18:44:30 +02:00
Set GenericItem type depenending on if a page is deletable
This commit is contained in:
@@ -116,6 +116,20 @@ GenericPageItem::isBeingPlayed() const
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void
|
||||||
|
GenericPageItem::setDeletable( bool deletable )
|
||||||
|
{
|
||||||
|
if ( deletable )
|
||||||
|
{
|
||||||
|
setRowType( SourcesModel::TemporaryPage );
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
setRowType( SourcesModel::GenericPage );
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
int
|
int
|
||||||
GenericPageItem::peerSortValue() const
|
GenericPageItem::peerSortValue() const
|
||||||
{
|
{
|
||||||
|
@@ -41,6 +41,7 @@ public:
|
|||||||
virtual int peerSortValue() const; // How to sort relative to peers in the tree.
|
virtual int peerSortValue() const; // How to sort relative to peers in the tree.
|
||||||
virtual bool isBeingPlayed() const;
|
virtual bool isBeingPlayed() const;
|
||||||
|
|
||||||
|
void setDeletable( bool deletable );
|
||||||
void setText( const QString& text );
|
void setText( const QString& text );
|
||||||
void setSortValue( int value );
|
void setSortValue( int value );
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user