![]() |
Mixxx
|
00001 /*************************************************************************** 00002 wstatuslight.h - A general purpose status light 00003 for indicating boolean events 00004 ------------------- 00005 begin : Fri Jul 22 2007 00006 copyright : (C) 2003 by Tue & Ken Haste Andersen 00007 (C) 2007 by John Sully (derived from WVumeter) 00008 email : jsully@scs.ryerson.ca 00009 ***************************************************************************/ 00010 00011 /*************************************************************************** 00012 * * 00013 * This program is free software; you can redistribute it and/or modify * 00014 * it under the terms of the GNU General Public License as published by * 00015 * the Free Software Foundation; either version 2 of the License, or * 00016 * (at your option) any later version. * 00017 * * 00018 ***************************************************************************/ 00019 00020 #ifndef WSTATUSLIGHT_H 00021 #define WSTATUSLIGHT_H 00022 00023 #include "wwidget.h" 00024 #include <qpixmap.h> 00025 #include <qstring.h> 00026 //Added by qt3to4: 00027 #include <QPaintEvent> 00028 00033 class WStatusLight : public WWidget { 00034 Q_OBJECT 00035 public: 00036 WStatusLight(QWidget *parent=0); 00037 ~WStatusLight(); 00038 void setup(QDomNode node); 00039 void setPixmap(int iState, const QString &filename); 00040 void setNoPos(int iNoPos); 00041 public slots: 00042 void setValue(double v); 00043 private: 00044 void paintEvent(QPaintEvent *); 00045 00047 int m_iPos; 00049 int m_iNoPos; 00051 QPixmap **m_pPixmapSLs; 00052 }; 00053 00054 #endif