summaryrefslogtreecommitdiff
path: root/protocols/Steam/src
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2021-12-26 20:31:39 +0300
committerGeorge Hazan <ghazan@miranda.im>2021-12-26 20:31:39 +0300
commitcddcd7483a7c472598af098e759e5d309024f606 (patch)
treeb0a227d6e087c41958cc84d27bc323353248aae5 /protocols/Steam/src
parent1039b2829a264280493ba0fa979214fe024dc70c (diff)
DWORD -> uint32_t
Diffstat (limited to 'protocols/Steam/src')
-rw-r--r--protocols/Steam/src/steam_contacts.cpp8
-rw-r--r--protocols/Steam/src/steam_crypt.cpp4
-rw-r--r--protocols/Steam/src/steam_dialogs.cpp2
-rw-r--r--protocols/Steam/src/steam_menus.cpp4
-rw-r--r--protocols/Steam/src/steam_proto.cpp2
5 files changed, 10 insertions, 10 deletions
diff --git a/protocols/Steam/src/steam_contacts.cpp b/protocols/Steam/src/steam_contacts.cpp
index 987ad50528..2793d61482 100644
--- a/protocols/Steam/src/steam_contacts.cpp
+++ b/protocols/Steam/src/steam_contacts.cpp
@@ -45,9 +45,9 @@ void CSteamProto::SetContactStatus(MCONTACT hContact, uint16_t status)
MCONTACT CSteamProto::GetContactFromAuthEvent(MEVENT hEvent)
{
- DWORD body[3];
+ uint32_t body[3];
DBEVENTINFO dbei = {};
- dbei.cbBlob = sizeof(DWORD) * 2;
+ dbei.cbBlob = sizeof(uint32_t) * 2;
dbei.pBlob = (uint8_t*)& body;
if (db_event_get(hEvent, &dbei))
@@ -198,7 +198,7 @@ void CSteamProto::UpdateContactDetails(MCONTACT hContact, const JSONNode &data)
json_string appId = data["gameid"].as_string();
CMStringW gameInfo = data["gameextrainfo"].as_mstring();
if (!appId.empty() || !gameInfo.IsEmpty()) {
- DWORD gameId = atol(appId.c_str());
+ uint32_t gameId = atol(appId.c_str());
json_string serverIP = data["gameserverip"].as_string();
json_string serverID = data["gameserversteamid"].as_string();
@@ -371,7 +371,7 @@ void CSteamProto::OnGotAppInfo(const JSONNode &root, void *arg)
MCONTACT hContact = (UINT_PTR)arg;
for (auto &app : root["apps"]) {
- DWORD gameId = app["appid"].as_int();
+ uint32_t gameId = app["appid"].as_int();
CMStringW message = app["name"].as_mstring();
setDword(hContact, "XStatusId", gameId);
diff --git a/protocols/Steam/src/steam_crypt.cpp b/protocols/Steam/src/steam_crypt.cpp
index dd07cb7e32..042e979cc5 100644
--- a/protocols/Steam/src/steam_crypt.cpp
+++ b/protocols/Steam/src/steam_crypt.cpp
@@ -4,7 +4,7 @@
int CSteamProto::RsaEncrypt(const char *pszModulus, DWORD &exponent, const char *data, uint8_t *encryptedData, DWORD &encryptedSize)
{
- DWORD cchModulus = (DWORD)mir_strlen(pszModulus);
+ uint32_t cchModulus = (uint32_t)mir_strlen(pszModulus);
int result;
HCRYPTKEY phKey = 0;
HCRYPTPROV hCSP = 0;
@@ -38,7 +38,7 @@ int CSteamProto::RsaEncrypt(const char *pszModulus, DWORD &exponent, const char
}
// Move the key into the key container.
- DWORD cbKeyBlob = sizeof(PUBLICKEYSTRUC) + sizeof(RSAPUBKEY) + cbLen;
+ uint32_t cbKeyBlob = sizeof(PUBLICKEYSTRUC) + sizeof(RSAPUBKEY) + cbLen;
mir_ptr<uint8_t> pKeyBlob((uint8_t *)mir_alloc(cbKeyBlob));
// Fill in the data.
diff --git a/protocols/Steam/src/steam_dialogs.cpp b/protocols/Steam/src/steam_dialogs.cpp
index 1a8fcf474b..c8599784e9 100644
--- a/protocols/Steam/src/steam_dialogs.cpp
+++ b/protocols/Steam/src/steam_dialogs.cpp
@@ -150,7 +150,7 @@ void CSteamCaptchaDialog::OnDestroy()
INT_PTR CSteamCaptchaDialog::DlgProc(UINT msg, WPARAM wParam, LPARAM lParam)
{
if (msg == WM_PAINT) {
- FIMEMORY *stream = FreeImage_OpenMemory(m_captchaImage, (DWORD)m_captchaImageSize);
+ FIMEMORY *stream = FreeImage_OpenMemory(m_captchaImage, (uint32_t)m_captchaImageSize);
FREE_IMAGE_FORMAT fif = FreeImage_GetFileTypeFromMemory(stream, 0);
FIBITMAP *bitmap = FreeImage_LoadFromMemory(fif, stream, 0);
FreeImage_CloseMemory(stream);
diff --git a/protocols/Steam/src/steam_menus.cpp b/protocols/Steam/src/steam_menus.cpp
index b421cdc120..42b169a312 100644
--- a/protocols/Steam/src/steam_menus.cpp
+++ b/protocols/Steam/src/steam_menus.cpp
@@ -49,7 +49,7 @@ int CSteamProto::UnblockCommand(WPARAM hContact, LPARAM)
int CSteamProto::JoinToGameCommand(WPARAM hContact, LPARAM)
{
char url[MAX_PATH];
- DWORD gameId = getDword(hContact, "GameID", 0);
+ uint32_t gameId = getDword(hContact, "GameID", 0);
mir_snprintf(url, "steam://rungameid/%lu", gameId);
Utils_OpenUrl(url);
return 0;
@@ -81,7 +81,7 @@ int CSteamProto::OnPrebuildContactMenu(WPARAM hContact, LPARAM)
Menu_ShowItem(contactMenuItems[CMI_BLOCK], !isBlocked || ctrlPressed);
Menu_ShowItem(contactMenuItems[CMI_UNBLOCK], isBlocked || ctrlPressed);
- DWORD gameId = getDword(hContact, "GameID", 0);
+ uint32_t gameId = getDword(hContact, "GameID", 0);
Menu_ShowItem(contactMenuItems[CMI_JOIN_GAME], gameId || ctrlPressed);
return 0;
}
diff --git a/protocols/Steam/src/steam_proto.cpp b/protocols/Steam/src/steam_proto.cpp
index 4b05b6c32d..801c6cf49c 100644
--- a/protocols/Steam/src/steam_proto.cpp
+++ b/protocols/Steam/src/steam_proto.cpp
@@ -80,7 +80,7 @@ CSteamProto::CSteamProto(const char *protoName, const wchar_t *userName) :
debugLogA(__FUNCTION__":Setting protocol / module name to '%s'", m_szModuleName);
- if (DWORD iGlobalValue = getDword(DB_KEY_LASTMSGTS)) {
+ if (uint32_t iGlobalValue = getDword(DB_KEY_LASTMSGTS)) {
for (auto &cc : AccContacts())
setDword(cc, DB_KEY_LASTMSGTS, iGlobalValue);
delSetting(DB_KEY_LASTMSGTS);