mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-03-20 15:59:42 +01:00
Added description support to Collection, and fixed header text.
This commit is contained in:
parent
74432a8712
commit
55d8896ab9
@ -64,6 +64,13 @@ Collection::prettyName() const
|
||||
}
|
||||
|
||||
|
||||
QString
|
||||
Collection::description() const
|
||||
{
|
||||
return QString();
|
||||
}
|
||||
|
||||
|
||||
QString
|
||||
Collection::itemName() const
|
||||
{
|
||||
|
@ -62,6 +62,7 @@ public:
|
||||
|
||||
virtual QString name() const;
|
||||
virtual QString prettyName() const;
|
||||
virtual QString description() const;
|
||||
virtual QString itemName() const;
|
||||
virtual BackendType backendType() const { return NullCollectionType; }
|
||||
virtual QIcon icon() const;
|
||||
|
@ -263,6 +263,7 @@ TreeModel::addCollection( const collection_ptr& collection )
|
||||
setIcon( collection->bigIcon() );
|
||||
|
||||
setTitle( collection->prettyName() );
|
||||
setDescription( collection->description() );
|
||||
}
|
||||
|
||||
|
||||
|
@ -54,14 +54,9 @@ ScriptCollection::~ScriptCollection()
|
||||
QString
|
||||
ScriptCollection::prettyName() const
|
||||
{
|
||||
if ( source()->isLocal() )
|
||||
return tr( "My %1 Collection",
|
||||
"Name of a collection based on a resolver, e.g. My Subsonic Collection" )
|
||||
.arg( m_resolver->name() );
|
||||
return tr( "%1 Collection of %2",
|
||||
"Name of a collection based on a resolver, e.g. Subsonic Collection of Some Dude" )
|
||||
.arg( m_resolver->name() )
|
||||
.arg( source()->friendlyName() );
|
||||
return tr( "%1 Collection",
|
||||
"Name of a collection based on a resolver, e.g. Subsonic Collection" )
|
||||
.arg( m_resolver->name() );
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user