mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-03-22 15:05:03 +01:00
daylight saving time date calculation fix
This commit is contained in:
@@ -35,9 +35,6 @@ public:
|
||||
int
|
||||
year_day() const {
|
||||
return m_yearday; }
|
||||
// helper, calculates day of year from given date
|
||||
int
|
||||
year_day( int Day, int const Month, int const Year ) const;
|
||||
int
|
||||
julian_day() const;
|
||||
inline
|
||||
@@ -46,9 +43,24 @@ public:
|
||||
return m_timezonebias; }
|
||||
|
||||
private:
|
||||
// converts provided time transition date to regular date
|
||||
void
|
||||
convert_transition_time( SYSTEMTIME &Time ) const;
|
||||
// calculates day and month from given day of year
|
||||
void
|
||||
daymonth( WORD &Day, WORD &Month, WORD const Year, WORD const Yearday );
|
||||
// calculates day of year from given date
|
||||
int
|
||||
year_day( int Day, int const Month, int const Year ) const;
|
||||
// calculates day of week for provided date
|
||||
int
|
||||
day_of_week( int const Day, int const Month, int const Year ) const;
|
||||
// calculates day of month for specified weekday of specified month of the year
|
||||
int
|
||||
day_of_month( int const Week, int const Weekday, int const Month, int const Year ) const;
|
||||
// returns number of days between specified days of week
|
||||
int
|
||||
weekdays( int const First, int const Second ) const;
|
||||
|
||||
SYSTEMTIME m_time;
|
||||
double m_milliseconds{ 0.0 };
|
||||
|
||||
Reference in New Issue
Block a user