]> git.saurik.com Git - wxWidgets.git/blame - include/wx/os2/timer.h
Removed unused code
[wxWidgets.git] / include / wx / os2 / timer.h
CommitLineData
0e320a79
DW
1/////////////////////////////////////////////////////////////////////////////
2// Name: timer.h
3// Purpose: wxTimer class
4// Author: AUTHOR
5// Modified by:
6// Created: ??/??/98
7// RCS-ID: $Id$
8// Copyright: (c) AUTHOR
9// Licence: wxWindows licence
10/////////////////////////////////////////////////////////////////////////////
11
12#ifndef _WX_TIMER_H_
13#define _WX_TIMER_H_
14
15#ifdef __GNUG__
16#pragma interface "timer.h"
17#endif
18
19#include "wx/object.h"
20
21class WXDLLEXPORT wxTimer: public wxObject
22{
23public:
24 wxTimer();
25 ~wxTimer();
26
27 virtual bool Start(int milliseconds = -1,
28 bool one_shot = FALSE); // Start timer
29 virtual void Stop(); // Stop timer
30
31 virtual void Notify() = 0; // Override this member
32
33 // Returns the current interval time (0 if stop)
f1415824 34 int Interval() const { return m_milli; };
0e320a79
DW
35 bool OneShot() const { return m_oneShot; }
36
37protected:
38 bool m_oneShot ;
39 int m_milli ;
40 int m_lastMilli ;
41
42 long m_id;
43
44private:
45 DECLARE_ABSTRACT_CLASS(wxTimer)
46};
47
48/* Note: these are implemented in common/timercmn.cpp, so need to implement them separately.
49 * But you may need to modify timercmn.cpp.
50 */
51
52// Timer functions (milliseconds)
53void WXDLLEXPORT wxStartTimer();
0e320a79
DW
54
55// EXPERIMENTAL: comment this out if it doesn't compile.
56bool WXDLLEXPORT wxGetLocalTime(long *timeZone, int *dstObserved);
57
58// Get number of seconds since 00:00:00 GMT, Jan 1st 1970.
59long WXDLLEXPORT wxGetCurrentTime();
60
61#endif
62 // _WX_TIMER_H_