2010-03-24 00:11:46 +01:00
|
|
|
/* This file is part of Clementine.
|
|
|
|
|
|
|
|
Clementine is free software: you can redistribute it and/or modify
|
|
|
|
it under the terms of the GNU General Public License as published by
|
|
|
|
the Free Software Foundation, either version 3 of the License, or
|
|
|
|
(at your option) any later version.
|
|
|
|
|
|
|
|
Clementine is distributed in the hope that it will be useful,
|
|
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
GNU General Public License for more details.
|
|
|
|
|
|
|
|
You should have received a copy of the GNU General Public License
|
|
|
|
along with Clementine. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
*/
|
|
|
|
|
2009-12-26 16:13:38 +01:00
|
|
|
#ifndef RADIOITEM_H
|
|
|
|
#define RADIOITEM_H
|
|
|
|
|
|
|
|
#include <QIcon>
|
2009-12-26 23:15:57 +01:00
|
|
|
#include <QUrl>
|
2009-12-26 16:13:38 +01:00
|
|
|
|
|
|
|
#include "simpletreeitem.h"
|
|
|
|
|
|
|
|
class RadioService;
|
|
|
|
|
|
|
|
class RadioItem : public SimpleTreeItem<RadioItem> {
|
|
|
|
public:
|
|
|
|
enum Type {
|
|
|
|
Type_Root = 1,
|
|
|
|
Type_Service,
|
|
|
|
};
|
|
|
|
|
2009-12-30 01:31:00 +01:00
|
|
|
RadioItem(SimpleTreeModel<RadioItem>* model);
|
2009-12-26 16:13:38 +01:00
|
|
|
RadioItem(RadioService* _service, int type, const QString& key = QString::null,
|
|
|
|
RadioItem* parent = NULL);
|
|
|
|
|
2009-12-30 00:17:54 +01:00
|
|
|
QUrl Url() const;
|
|
|
|
QString Title() const;
|
2010-01-18 03:23:55 +01:00
|
|
|
QString Artist() const;
|
2009-12-30 00:17:54 +01:00
|
|
|
|
2009-12-26 16:13:38 +01:00
|
|
|
QIcon icon;
|
2010-01-18 03:23:55 +01:00
|
|
|
QString artist;
|
2009-12-26 16:13:38 +01:00
|
|
|
RadioService* service;
|
2009-12-26 22:35:45 +01:00
|
|
|
bool playable;
|
2009-12-26 16:13:38 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif // RADIOITEM_H
|