kalarm
sounddlg.h00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 #ifndef SOUNDDLG_H
00022 #define SOUNDDLG_H
00023
00024 #include <qframe.h>
00025 #include <qstring.h>
00026 #include <kdialogbase.h>
00027
00028 class QHBox;
00029 class PushButton;
00030 class CheckBox;
00031 class SpinBox;
00032 class Slider;
00033 class LineEdit;
00034
00035
00036 class SoundDlg : public KDialogBase
00037 {
00038 Q_OBJECT
00039 public:
00040 SoundDlg(const QString& file, float volume, float fadeVolume, int fadeSeconds, bool repeat,
00041 const QString& caption, QWidget* parent, const char* name = 0);
00042 void setReadOnly(bool);
00043 bool isReadOnly() const { return mReadOnly; }
00044 QString getFile() const;
00045 bool getSettings(float& volume, float& fadeVolume, int& fadeSeconds) const;
00046 QString defaultDir() const { return mDefaultDir; }
00047
00048 static QString i18n_SetVolume();
00049 static QString i18n_v_SetVolume();
00050 static QString i18n_Repeat();
00051 static QString i18n_p_Repeat();
00052
00053 protected:
00054 virtual void showEvent(QShowEvent*);
00055 virtual void resizeEvent(QResizeEvent*);
00056
00057 protected slots:
00058 virtual void slotOk();
00059
00060 private slots:
00061 void slotPickFile();
00062 void slotVolumeToggled(bool on);
00063 void slotFadeToggled(bool on);
00064
00065 private:
00066 LineEdit* mFileEdit;
00067 PushButton* mFileBrowseButton;
00068 CheckBox* mRepeatCheckbox;
00069 CheckBox* mVolumeCheckbox;
00070 Slider* mVolumeSlider;
00071 CheckBox* mFadeCheckbox;
00072 QHBox* mFadeBox;
00073 SpinBox* mFadeTime;
00074 QHBox* mFadeVolumeBox;
00075 Slider* mFadeSlider;
00076 QString mDefaultDir;
00077 bool mReadOnly;
00078 };
00079
00080 #endif
|