File indexing completed on 2024-05-05 04:48:30

0001 /****************************************************************************************
0002  * Copyright (c) 2008 Daniel Jones <danielcjones@gmail.com>                             *
0003  * Copyright (c) 2010 Ralf Engels <ralf-engels@gmx.de>                                  *
0004  *                                                                                      *
0005  * This program is free software; you can redistribute it and/or modify it under        *
0006  * the terms of the GNU General Public License as published by the Free Software        *
0007  * Foundation; either version 2 of the License, or (at your option) version 3 or        *
0008  * any later version accepted by the membership of KDE e.V. (or its successor approved  *
0009  * by the membership of KDE e.V.), which shall act as a proxy defined in Section 14 of  *
0010  * version 3 of the license.                                                            *
0011  *                                                                                      *
0012  * This program is distributed in the hope that it will be useful, but WITHOUT ANY      *
0013  * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A      *
0014  * PARTICULAR PURPOSE. See the GNU General Public License for more details.             *
0015  *                                                                                      *
0016  * You should have received a copy of the GNU General Public License along with         *
0017  * this program.  If not, see <http://www.gnu.org/licenses/>.                           *
0018  ****************************************************************************************/
0019 
0020 #include "DynamicPlaylist.h"
0021 #include "DynamicModel.h"
0022 
0023 Dynamic::DynamicPlaylist::DynamicPlaylist( QObject *parent )
0024     : QObject( parent )
0025 {
0026 }
0027 
0028 Dynamic::DynamicPlaylist::~DynamicPlaylist()
0029 {
0030 }
0031 
0032 /*
0033 void
0034 Dynamic::DynamicPlaylist::repopulate()
0035 {
0036     // do nothing by default
0037 }
0038 */
0039 
0040 QString Dynamic::DynamicPlaylist::title() const
0041 { return m_title; }
0042 
0043 void Dynamic::DynamicPlaylist::setTitle( const QString &title )
0044 {
0045     m_title = title;
0046     bool inModel = DynamicModel::instance()->index( this ).isValid();
0047     if( inModel )
0048         DynamicModel::instance()->playlistChanged( this );
0049 }
0050 
0051