summaryrefslogtreecommitdiff
path: root/noncore/tools/clock/clock.h
Side-by-side diff
Diffstat (limited to 'noncore/tools/clock/clock.h') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/tools/clock/clock.h15
1 files changed, 11 insertions, 4 deletions
diff --git a/noncore/tools/clock/clock.h b/noncore/tools/clock/clock.h
index 23cc143..9b00e28 100644
--- a/noncore/tools/clock/clock.h
+++ b/noncore/tools/clock/clock.h
@@ -37,30 +37,32 @@ class AnalogClock : public QFrame
public:
AnalogClock( QWidget * parent = 0, const char * name = 0 )
: QFrame( parent, name ), clear(true) {}
QSizePolicy sizePolicy() const;
void display( const QTime& time );
protected:
void drawContents( QPainter *p );
private:
- QPoint rotate( QPoint center, QPoint p, int angle );
- void drawPointers ( QPainter *, const QRect &r, const QColor &c, const QTime &t, const QTime *t2 = 0 );
QTime currTime;
QTime prevTime;
bool clear;
+
+ QPoint rotate( QPoint center, QPoint p, int angle );
+ void drawPointers ( QPainter *, const QRect &r, const QColor &c, const QTime &t, const QTime *t2 = 0 );
+
};
class Clock : public QVBox
{
Q_OBJECT
public:
Clock( QWidget * parent = 0, const char * name = 0, WFlags f=0 );
~Clock();
QDateTime when;
bool bSound;
int hour, minute, snoozeTime;
@@ -69,31 +71,36 @@ private slots:
void slotReset();
void modeSelect(int);
void updateClock();
void changeClock( bool );
void slotSetAlarm();
void slotSnooze();
void slotToggleAlarm();
void alarmOn();
void alarmOff();
void appMessage(const QCString& msg, const QByteArray& data);
void timerEvent( QTimerEvent *e );
void slotAdjustTime();
+
+ void slotStartTimer();
+ void slotStopTimer();
+ void slotResetTimer();
+ void setSwatchMode( int );
private:
- void clearClock();
- void clearTimer();
bool alarmBool;
QTimer *t;
QLCDNumber *lcd;
QLabel *date;
QLabel *ampmLabel;
QPushButton *set, *reset, *alarmBtn, *snoozeBtn, *alarmOffBtn;
QRadioButton *clockRB, *swatchRB;
AnalogClock *aclock;
QTime swatch_start;
int swatch_totalms;
bool swatch_running;
bool ampm;
+ void clearClock();
+ void clearTimer();
};
#endif