36 #include <tqdatetime.h>
56 dt.setTime_t( epoch, TQt::UTC );
67 int offset = TQDateTime::currentDateTime( TQt::UTC ).toTime_t()
68 - TQDateTime::currentDateTime( TQt::LocalTime ).toTime_t();
69 return( dt.toTime_t() - offset );
82 cout <<
"NOTE: Some tests may be off by 1 hour (3600 secs) "
83 <<
"due to daylight savings time"
89 cout <<
"TEST 1:" << endl;
93 << dt.toString( TQt::TextDate )
98 << dt.toString( TQt::TextDate )
107 cout <<
"TEST 2:" << endl;
111 << dt.toString( TQt::TextDate )
116 << dt.toString( TQt::TextDate )
125 cout <<
"TEST 3:" << endl;
129 << dt.toString( TQt::TextDate )
134 << dt.toString( TQt::TextDate )
143 cout <<
"TEST 4:" << endl;
147 << dt.toString( TQt::TextDate )
152 << dt.toString( TQt::TextDate )
161 cout <<
"TEST 5:" << endl;
165 << dt.toString( TQt::TextDate )
170 << dt.toString( TQt::TextDate )
KonsoleKalendarEpoch()
Constructor.
~KonsoleKalendarEpoch()
Destructor.
static uint TQDateTime2epoch(TQDateTime dt)
Converts QT DateTime to epoch format.
static TQDateTime epoch2TQDateTime(uint epoch)
Converts epoch time to TQDateTime format.
Provides the KonsoleKalendarEpoch class definition.