Rivendellaudio/lib/rdlog_icons.h
Fred Gleason c27e953186 2020-12-26 Fred Gleason <fredg@paravelsystems.com>
* Added a 'RDLogListModel' class.
	* Added a 'RDLogIcons::listIcon()' method.
	* Refactored rdlogedit(1) to use 'RDLogListModel'.

Signed-off-by: Fred Gleason <fredg@paravelsystems.com>
2020-12-26 20:02:44 -05:00

47 lines
1.3 KiB
C++

// rdlog_icons.h
//
// Icons for Rivendell log events.
//
// (C) Copyright 2020 Fred Gleason <fredg@paravelsystems.com>
//
// This program is free software; you can redistribute it and/or modify
// it under the terms of the GNU General Public License version 2 as
// published by the Free Software Foundation.
//
// This program 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 this program; if not, write to the Free Software
// Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
//
#ifndef RDLOG_ICONS_H
#define RDLOG_ICONS_H
#include <QMap>
#include <QPixmap>
#include <rdlog_line.h>
class RDLogIcons
{
public:
enum IconType {GreenCheck=0,RedX=1,GreenBall=2,RedBall=3,WhiteBall=4,
BlueBall=5};
RDLogIcons();
QPixmap listIcon(IconType type) const;
QPixmap typeIcon(RDLogLine::Type type,
RDLogLine::Source src=RDLogLine::Manual) const;
private:
QList<QPixmap> d_list_icons;
QMap<RDLogLine::Type,QPixmap> log_type_icons;
QPixmap log_track_cart_icon;
};
#endif // RDLOG_ICONS