00001 /*************************************************************************** 00002 radiostation-config.h - description 00003 ------------------- 00004 begin : Sa Aug 16 2003 00005 copyright : (C) 2003 by Martin Witte 00006 email : witte@kawo1.rwth-aachen.de 00007 ***************************************************************************/ 00008 00009 /*************************************************************************** 00010 * * 00011 * This program is free software; you can redistribute it and/or modify * 00012 * it under the terms of the GNU General Public License as published by * 00013 * the Free Software Foundation; either version 2 of the License, or * 00014 * (at your option) any later version. * 00015 * * 00016 ***************************************************************************/ 00017 00018 #ifndef KRADIO_RADIOSTATION_CONFIG_H 00019 #define KRADIO_RADIOSTATION_CONFIG_H 00020 00021 #ifdef HAVE_CONFIG_H 00022 #include <config.h> 00023 #endif 00024 00025 #include <qwidget.h> 00026 00027 class RadioStation; 00028 00029 class RadioStationConfig : public QWidget 00030 { 00031 Q_OBJECT 00032 public: 00033 RadioStationConfig(QWidget *parent); 00034 ~RadioStationConfig(); 00035 00036 virtual void setStationData (const RadioStation &rs) = 0; 00037 virtual void storeStationData (RadioStation &rs) = 0; 00038 00039 signals: 00040 virtual void changed(RadioStationConfig *); 00041 }; 00042 00043 00044 class UndefinedRadioStationConfig : public RadioStationConfig 00045 { 00046 Q_OBJECT 00047 public: 00048 UndefinedRadioStationConfig (QWidget *parent); 00049 ~UndefinedRadioStationConfig(); 00050 00051 virtual void setStationData (const RadioStation &rs); 00052 virtual void storeStationData (RadioStation &rs); 00053 }; 00054 00055 00056 00057 class QSpinBox; 00058 00059 class FrequencyRadioStationConfig : public RadioStationConfig 00060 { 00061 Q_OBJECT 00062 public: 00063 FrequencyRadioStationConfig (QWidget *parent); 00064 ~FrequencyRadioStationConfig(); 00065 00066 virtual void setStationData (const RadioStation &rs); 00067 virtual void storeStationData (RadioStation &rs); 00068 00069 protected slots: 00070 virtual void slotValueChanged(int); 00071 00072 protected: 00073 00074 QSpinBox *m_editFrequency; 00075 }; 00076 00077 00078 00079 #endif