diff options
Diffstat (limited to 'plugins/HistoryStats')
-rw-r--r-- | plugins/HistoryStats/src/mu_common.cpp | 8 | ||||
-rw-r--r-- | plugins/HistoryStats/src/mu_common.h | 9 | ||||
-rw-r--r-- | plugins/HistoryStats/src/statistic.cpp | 4 | ||||
-rw-r--r-- | plugins/HistoryStats/src/stdafx.h | 1 | ||||
-rw-r--r-- | plugins/HistoryStats/src/utils.h | 3 |
5 files changed, 3 insertions, 22 deletions
diff --git a/plugins/HistoryStats/src/mu_common.cpp b/plugins/HistoryStats/src/mu_common.cpp index 971a525ae3..5e435604ac 100644 --- a/plugins/HistoryStats/src/mu_common.cpp +++ b/plugins/HistoryStats/src/mu_common.cpp @@ -104,14 +104,6 @@ namespace mu }
}
- namespace db_time
- {
- DWORD timestampToLocal(DWORD timestamp)
- {
- return static_cast<DWORD>(CallService(MS_DB_TIME_TIMESTAMPTOLOCAL, static_cast<WPARAM>(timestamp), 0));
- }
- }
-
/*
* icolib
*/
diff --git a/plugins/HistoryStats/src/mu_common.h b/plugins/HistoryStats/src/mu_common.h index 6786201805..99f4c6985b 100644 --- a/plugins/HistoryStats/src/mu_common.h +++ b/plugins/HistoryStats/src/mu_common.h @@ -42,15 +42,6 @@ namespace mu }
/*
- * db_time
- */
-
- namespace db_time
- {
- DWORD timestampToLocal(DWORD timestamp);
- }
-
- /*
* icolib
*/
diff --git a/plugins/HistoryStats/src/statistic.cpp b/plugins/HistoryStats/src/statistic.cpp index f2a5fceaf3..c0207baac8 100644 --- a/plugins/HistoryStats/src/statistic.cpp +++ b/plugins/HistoryStats/src/statistic.cpp @@ -434,7 +434,7 @@ bool Statistic::stepReadDB() // filter logged status messages from tabSRMM
if (dbei.eventType == etMessage) {
// convert to local time (everything in this plugin is done in local time)
- DWORD localTimestamp = utils::toLocalTime(dbei.timestamp);
+ DWORD localTimestamp = TimeZone_ToLocal(dbei.timestamp);
if (localTimestamp >= m_TimeMin && localTimestamp <= m_TimeMax) {
if (dbei.flags & DBEF_UTF) {
@@ -1235,7 +1235,7 @@ Statistic::Statistic(const Settings& settings, InvocationSource invokedFrom, HIN m_nFirstTime(0),
m_nLastTime(0)
{
- m_TimeStarted = utils::toLocalTime(time(NULL));
+ m_TimeStarted = TimeZone_ToLocal(time(NULL));
m_MSecStarted = GetTickCount();
m_AverageMinTime = settings.m_AverageMinTime * 24 * 60 * 60; // calculate seconds from days
}
diff --git a/plugins/HistoryStats/src/stdafx.h b/plugins/HistoryStats/src/stdafx.h index 0b8e3d16c6..4b623bc649 100644 --- a/plugins/HistoryStats/src/stdafx.h +++ b/plugins/HistoryStats/src/stdafx.h @@ -66,6 +66,7 @@ #include <m_userinfo.h> // not used
#include <m_utils.h>
#include <m_imgsrvc.h>
+#include <m_timezones.h>
#include <m_addcontact.h> // not used, depends on m_protosvc.h
#include <m_icq.h> // depends on m_protosvc.h
diff --git a/plugins/HistoryStats/src/utils.h b/plugins/HistoryStats/src/utils.h index 8c2160dee6..cbd42f240b 100644 --- a/plugins/HistoryStats/src/utils.h +++ b/plugins/HistoryStats/src/utils.h @@ -38,9 +38,6 @@ namespace utils ext::string toLowerCase(const ext::string& text);
ext::string toUpperCase(const ext::string& text);
- // time conversion
- inline DWORD toLocalTime(DWORD gmtTimestamp) { return mu::db_time::timestampToLocal(gmtTimestamp); }
-
// version conversion
DWORD dottedToVersion(ext::string version);
ext::string versionToDotted(DWORD version);
|