21 #ifndef ALARMTIMEWIDGET_H
22 #define ALARMTIMEWIDGET_H
24 #include "buttongroup.h"
34 class AlarmTimeWidget : public ButtonGroup
44 AlarmTimeWidget( const TQString& groupBoxTitle, int mode, TQWidget* parent = 0, const char* name = 0);
45 AlarmTimeWidget( int mode, TQWidget* parent = 0, const char* name = 0);
46 DateTime getDateTime( int* minsFromNow = 0, bool checkExpired = true, bool showErrorMessage = true, TQWidget** errorWidget = 0) const;
47 void setDateTime( const DateTime&);
48 void setMinDateTimeIsCurrent();
49 void setMinDateTime( const TQDateTime& = TQDateTime());
50 void setMaxDateTime( const DateTime& = DateTime());
51 const TQDateTime& maxDateTime() const { return mMaxDateTime; }
52 void setReadOnly( bool);
53 bool anyTime() const { return mAnyTime; }
54 void enableAnyTime( bool enable);
55 void selectTimeFromNow( int minutes = 0);
56 TQSize sizeHint() const { return minimumSizeHint(); }
58 static TQString i18n_w_TimeFromNow();
59 static TQString i18n_TimeAfterPeriod();
60 static const int maxDelayTime;
63 void anyTimeToggled( bool anyTime);
68 void slotButtonSet( int id);
69 void dateTimeChanged();
70 void delayTimeChanged( int);
71 void slotAnyTimeToggled( bool);
76 void setMaxDelayTime( const TQDateTime& now);
77 void setMaxMinTimeIf( const TQDateTime& now);
79 RadioButton* mAtTimeRadio;
80 RadioButton* mAfterTimeRadio;
83 TimeSpinBox* mDelayTimeEdit;
84 CheckBox* mAnyTimeCheckBox;
85 TQDateTime mMinDateTime;
86 TQDateTime mMaxDateTime;
89 bool mMinDateTimeIsNow;
|