From cddcd7483a7c472598af098e759e5d309024f606 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Sun, 26 Dec 2021 20:31:39 +0300 Subject: DWORD -> uint32_t --- plugins/DbEditorPP/src/exportimport.cpp | 6 +++--- plugins/DbEditorPP/src/findwindow.cpp | 2 +- plugins/DbEditorPP/src/settinglist.cpp | 4 ++-- plugins/DbEditorPP/src/stdafx.h | 6 +++--- plugins/DbEditorPP/src/utils.cpp | 6 +++--- 5 files changed, 12 insertions(+), 12 deletions(-) (limited to 'plugins/DbEditorPP/src') diff --git a/plugins/DbEditorPP/src/exportimport.cpp b/plugins/DbEditorPP/src/exportimport.cpp index fcd3b9d226..d835bf60de 100644 --- a/plugins/DbEditorPP/src/exportimport.cpp +++ b/plugins/DbEditorPP/src/exportimport.cpp @@ -364,7 +364,7 @@ void importSettings(MCONTACT hContact, char *utf8) case 'd': case 'D': if (sscanf(end + 2, "%u", &value) == 1) - db_set_dw(hContact, module, setting, (DWORD)value); + db_set_dw(hContact, module, setting, (uint32_t)value); break; case 's': case 'S': @@ -477,7 +477,7 @@ void ImportSettingsFromFileMenuItem(MCONTACT hContact, const char *FilePath) wchar_t szPath[MAX_PATH] = {}; wchar_t szFile[MAX_PATH]; - DWORD offset = 0; + uint32_t offset = 0; mir_wstrcpy(szFileNames, L""); @@ -491,7 +491,7 @@ void ImportSettingsFromFileMenuItem(MCONTACT hContact, const char *FilePath) int index = 0; if (mir_wstrcmp(szFileNames, L"")) { - if ((DWORD)mir_wstrlen(szFileNames) < offset) { + if ((uint32_t)mir_wstrlen(szFileNames) < offset) { index += offset; mir_wstrncpy(szPath, szFileNames, offset); mir_wstrcat(szPath, L"\\"); diff --git a/plugins/DbEditorPP/src/findwindow.cpp b/plugins/DbEditorPP/src/findwindow.cpp index 45716efdd2..cf669b3970 100644 --- a/plugins/DbEditorPP/src/findwindow.cpp +++ b/plugins/DbEditorPP/src/findwindow.cpp @@ -136,7 +136,7 @@ class CFindWindowDlg : public CDlgBase int foundCount = 0, replaceCount = 0, deleteCount = 0; - DWORD numsearch = 0, numreplace = 0; + uint32_t numsearch = 0, numreplace = 0; int NULLContactDone = 0; if (!fi->search || !EnumModules(&ModuleList)) { diff --git a/plugins/DbEditorPP/src/settinglist.cpp b/plugins/DbEditorPP/src/settinglist.cpp index 27676f45e7..eca77599a6 100644 --- a/plugins/DbEditorPP/src/settinglist.cpp +++ b/plugins/DbEditorPP/src/settinglist.cpp @@ -13,7 +13,7 @@ int convertSetting(MCONTACT hContact, const char *module, const char *setting, i } int res = 0; - DWORD val = 0; + uint32_t val = 0; wchar_t tmp[16]; ptrW value; @@ -481,7 +481,7 @@ bool CMainDlg::EditLabelWndProc(HWND hwnd, UINT uMsg, WPARAM wParam) break; case 1: // value - DWORD val; + uint32_t val; int i = 0; if (dbv.type == DBVT_BLOB) { diff --git a/plugins/DbEditorPP/src/stdafx.h b/plugins/DbEditorPP/src/stdafx.h index f7c621ce44..0934c31319 100644 --- a/plugins/DbEditorPP/src/stdafx.h +++ b/plugins/DbEditorPP/src/stdafx.h @@ -50,7 +50,7 @@ struct CMPlugin : public PLUGIN { CMOption bExpandSettingsOnOpen, bRestoreOnOpen, bWarnOnDelete; CMOption iPopupDelay; - CMOption iPopupBkColor, iPopupTxtColor; + CMOption iPopupBkColor, iPopupTxtColor; CMPlugin(); @@ -178,8 +178,8 @@ extern bool g_bUsePopups; char *StringFromBlob(uint8_t *blob, uint16_t len); int WriteBlobFromString(MCONTACT hContact, const char *module, const char *setting, const char *value, int len); wchar_t *DBVType(uint8_t type); -DWORD getNumericValue(DBVARIANT *dbv); -int setNumericValue(MCONTACT hContact, const char *module, const char *setting, DWORD value, int type); +uint32_t getNumericValue(DBVARIANT *dbv); +int setNumericValue(MCONTACT hContact, const char *module, const char *setting, uint32_t value, int type); int IsRealUnicode(wchar_t *value); int setTextValue(MCONTACT hContact, const char *module, const char *setting, wchar_t *value, int type); int GetValueA(MCONTACT hContact, const char *module, const char *setting, char *value, int length); diff --git a/plugins/DbEditorPP/src/utils.cpp b/plugins/DbEditorPP/src/utils.cpp index d38a5e873a..fdda3d4fd5 100644 --- a/plugins/DbEditorPP/src/utils.cpp +++ b/plugins/DbEditorPP/src/utils.cpp @@ -92,7 +92,7 @@ wchar_t* DBVType(uint8_t type) switch (type) { case DBVT_BYTE: return L"uint8_t"; case DBVT_WORD: return L"uint16_t"; - case DBVT_DWORD: return L"DWORD"; + case DBVT_DWORD: return L"uint32_t"; case DBVT_ASCIIZ: return L"STRING"; case DBVT_WCHAR: case DBVT_UTF8: return L"UNICODE"; @@ -102,7 +102,7 @@ wchar_t* DBVType(uint8_t type) return L""; } -DWORD getNumericValue(DBVARIANT *dbv) +uint32_t getNumericValue(DBVARIANT *dbv) { switch (dbv->type) { case DBVT_DWORD: @@ -115,7 +115,7 @@ DWORD getNumericValue(DBVARIANT *dbv) return 0; } -int setNumericValue(MCONTACT hContact, const char *module, const char *setting, DWORD value, int type) +int setNumericValue(MCONTACT hContact, const char *module, const char *setting, uint32_t value, int type) { switch (type) { case DBVT_BYTE: -- cgit v1.2.3