diff options
author | George Hazan <ghazan@miranda.im> | 2021-12-26 20:31:39 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2021-12-26 20:31:39 +0300 |
commit | cddcd7483a7c472598af098e759e5d309024f606 (patch) | |
tree | b0a227d6e087c41958cc84d27bc323353248aae5 /protocols/Weather | |
parent | 1039b2829a264280493ba0fa979214fe024dc70c (diff) |
DWORD -> uint32_t
Diffstat (limited to 'protocols/Weather')
-rw-r--r-- | protocols/Weather/src/stdafx.h | 6 | ||||
-rw-r--r-- | protocols/Weather/src/weather_conv.cpp | 4 | ||||
-rw-r--r-- | protocols/Weather/src/weather_mwin.cpp | 4 | ||||
-rw-r--r-- | protocols/Weather/src/weather_popup.cpp | 8 | ||||
-rw-r--r-- | protocols/Weather/src/weather_update.cpp | 6 |
5 files changed, 14 insertions, 14 deletions
diff --git a/protocols/Weather/src/stdafx.h b/protocols/Weather/src/stdafx.h index 5d8597247e..27eee87f95 100644 --- a/protocols/Weather/src/stdafx.h +++ b/protocols/Weather/src/stdafx.h @@ -217,11 +217,11 @@ struct MYOPTIONS COLORREF TextColour; // popup actions - DWORD LeftClickAction; - DWORD RightClickAction; + uint32_t LeftClickAction; + uint32_t RightClickAction; // popup delay - DWORD pDelay; + uint32_t pDelay; // other misc stuff wchar_t Default[64]; diff --git a/protocols/Weather/src/weather_conv.cpp b/protocols/Weather/src/weather_conv.cpp index dc1dfa4f03..649ca37a91 100644 --- a/protocols/Weather/src/weather_conv.cpp +++ b/protocols/Weather/src/weather_conv.cpp @@ -363,7 +363,7 @@ uint16_t GetIcon(const wchar_t *cond, WIDATA *Data) // using the format _T("# Weather <condition name> <counter> #" mir_snwprintf(LangPackStr, L"# Weather %s %i #", statusStr[i], j); wcsncpy_s(LangPackStr1, TranslateW(LangPackStr), _TRUNCATE); - CharLowerBuff(LangPackStr1, (DWORD)mir_wstrlen(LangPackStr1)); + CharLowerBuff(LangPackStr1, (uint32_t)mir_wstrlen(LangPackStr1)); if (wcsstr(cond, LangPackStr1) != nullptr) return statusValue[i]; // loop until the translation string exists (ie, the translated string is differ from original) @@ -380,7 +380,7 @@ void CaseConv(wchar_t *str) { bool nextUp = true; - CharLowerBuffW(str, (DWORD)mir_wstrlen(str)); + CharLowerBuffW(str, (uint32_t)mir_wstrlen(str)); for (wchar_t *pstr = str; *pstr; pstr++) { if (*pstr == ' ' || *pstr == '-') nextUp = true; diff --git a/protocols/Weather/src/weather_mwin.cpp b/protocols/Weather/src/weather_mwin.cpp index 3ba118d646..0ef9991cff 100644 --- a/protocols/Weather/src/weather_mwin.cpp +++ b/protocols/Weather/src/weather_mwin.cpp @@ -248,7 +248,7 @@ static void addWindow(MCONTACT hContact) void removeWindow(MCONTACT hContact) { - DWORD frameId = g_plugin.getDword(hContact, "mwin"); + uint32_t frameId = g_plugin.getDword(hContact, "mwin"); WindowList_Remove(hMwinWindowList, WindowList_Find(hMwinWindowList, hContact)); CallService(MS_CLIST_FRAMES_REMOVEFRAME, frameId, 0); @@ -347,7 +347,7 @@ void InitMwin(void) void DestroyMwin(void) { for (auto &hContact : Contacts(MODULENAME)) { - DWORD frameId = g_plugin.getDword(hContact, "mwin"); + uint32_t frameId = g_plugin.getDword(hContact, "mwin"); if (frameId) CallService(MS_CLIST_FRAMES_REMOVEFRAME, frameId, 0); } diff --git a/protocols/Weather/src/weather_popup.cpp b/protocols/Weather/src/weather_popup.cpp index f0be40f798..e6276167f7 100644 --- a/protocols/Weather/src/weather_popup.cpp +++ b/protocols/Weather/src/weather_popup.cpp @@ -42,11 +42,11 @@ int WeatherError(WPARAM wParam, LPARAM lParam) wchar_t* tszMsg = (wchar_t*)wParam; - if ((DWORD)lParam == SM_WARNING) + if ((uint32_t)lParam == SM_WARNING) PUShowMessageW(tszMsg, SM_WARNING); - else if ((DWORD)lParam == SM_NOTIFY) + else if ((uint32_t)lParam == SM_NOTIFY) PUShowMessageW(tszMsg, SM_NOTIFY); - else if ((DWORD)lParam == SM_WEATHERALERT) { + else if ((uint32_t)lParam == SM_WEATHERALERT) { POPUPDATAW ppd; wchar_t str1[512], str2[512]; @@ -94,7 +94,7 @@ int WPShowMessage(const wchar_t* lpzText, uint16_t kind) // use for displaying contact menu static LRESULT CALLBACK PopupDlgProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam) { - DWORD ID = 0; + uint32_t ID = 0; MCONTACT hContact; hContact = PUGetContact(hWnd); diff --git a/protocols/Weather/src/weather_update.cpp b/protocols/Weather/src/weather_update.cpp index 37d75a01f8..e647a93128 100644 --- a/protocols/Weather/src/weather_update.cpp +++ b/protocols/Weather/src/weather_update.cpp @@ -189,11 +189,11 @@ int UpdateWeather(MCONTACT hContact) DBEVENTINFO dbei = {}; dbei.szModule = MODULENAME; - dbei.timestamp = (DWORD)time(0); + dbei.timestamp = (uint32_t)time(0); dbei.flags = DBEF_READ | DBEF_UTF; dbei.eventType = EVENTTYPE_MESSAGE; dbei.pBlob = szMessage; - dbei.cbBlob = (DWORD)mir_strlen(szMessage) + 1; + dbei.cbBlob = (uint32_t)mir_strlen(szMessage) + 1; db_event_add(hContact, &dbei); } @@ -554,7 +554,7 @@ int GetWeatherData(MCONTACT hContact) if (cbuf[0] == '#') cbuf = TranslateW(DataValue); db_set_ws(hContact, WEATHERCONDITION, _T2A(Item->Item.Name), cbuf); - CharLowerBuff(DataValue, (DWORD)mir_wstrlen(DataValue)); + CharLowerBuff(DataValue, (uint32_t)mir_wstrlen(DataValue)); cond = GetIcon(DataValue, Data); } else if (mir_wstrcmpi(Item->Item.Unit, L"Cond") == 0) { |