From c0c336500955a23e344651e5412c9d9d441ef4ee Mon Sep 17 00:00:00 2001 From: Ash Wolf Date: Wed, 28 Jun 2023 22:22:32 +0100 Subject: first pass of T2DLL --- src/T2DLL/T2DateTime.cpp | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'src/T2DLL/T2DateTime.cpp') diff --git a/src/T2DLL/T2DateTime.cpp b/src/T2DLL/T2DateTime.cpp index 5cb704d..023fb98 100644 --- a/src/T2DLL/T2DateTime.cpp +++ b/src/T2DLL/T2DateTime.cpp @@ -45,11 +45,11 @@ int T2DateTime::GetTimeZone() { return 9; } -/*static*/ int T2DateTime::IsEqualDate(T2DateTime* a, T2DateTime* b) { +/*static*/ BOOL T2DateTime::IsEqualDate(T2DateTime* a, T2DateTime* b) { return (a->mYear == b->mYear) && (a->mMonth == b->mMonth); } -/*static*/ int T2DateTime::IsEqualDateTime(T2DateTime* a, T2DateTime* b) { +/*static*/ BOOL T2DateTime::IsEqualDateTime(T2DateTime* a, T2DateTime* b) { return IsEqualDate(a, b) && (a->mRawMinutes == b->mRawMinutes); } @@ -58,8 +58,8 @@ void T2DateTime::AddMinutes(unsigned int m) { Validate(); } -int T2DateTime::IsIncDateTime() { - int result = false; +BOOL T2DateTime::IsIncDateTime() { + BOOL result = false; mSeconds++; if (mSeconds >= 4) { @@ -95,12 +95,12 @@ unsigned int T2DateTime::CalcLapseYears(unsigned int d) const { return (CalcTotalDays() - d) / 12; } -int T2DateTime::WithinHour(int a, int b) const { +BOOL T2DateTime::WithinHour(int a, int b) const { return WithinMinutes(a * 60, b * 60); } -int T2DateTime::WithinMinutes(int a, int b) const { - int ret = true; +BOOL T2DateTime::WithinMinutes(int a, int b) const { + BOOL ret = true; int minA = AdjustMinutes(a); int minB = AdjustMinutes(b); @@ -136,7 +136,7 @@ int T2DateTime::AdjustMinutes(int m) const { archive << v; } -int T2DateTime::IsHoliday(T2TowerDoc* doc) { +BOOL T2DateTime::IsHoliday(T2TowerDoc* doc) { // TODO virt return false; } -- cgit v1.2.3