summaryrefslogtreecommitdiff
path: root/plugins/Scriver/src
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2023-03-22 14:52:05 +0300
committerGeorge Hazan <ghazan@miranda.im>2023-03-22 14:52:05 +0300
commit7c3c13800855033b8d5c5ffe08b3586456fa0b7b (patch)
tree7a96a213eceff8390973a9a943b47aa7c3631426 /plugins/Scriver/src
parent9a2f89927666a7011de901651bb6fd3b29e0cef9 (diff)
this code isn't used either
Diffstat (limited to 'plugins/Scriver/src')
-rw-r--r--plugins/Scriver/src/msgdialog.cpp27
1 files changed, 3 insertions, 24 deletions
diff --git a/plugins/Scriver/src/msgdialog.cpp b/plugins/Scriver/src/msgdialog.cpp
index f0cb3f11fb..90a248965b 100644
--- a/plugins/Scriver/src/msgdialog.cpp
+++ b/plugins/Scriver/src/msgdialog.cpp
@@ -1200,11 +1200,11 @@ INT_PTR CMsgDialog::DlgProc(UINT msg, WPARAM wParam, LPARAM lParam)
{
LPDRAWITEMSTRUCT dis = (LPDRAWITEMSTRUCT)lParam;
if (dis->CtlID == IDC_AVATAR) {
- int avatarWidth = 0, avatarHeight = 0;
int itemWidth = dis->rcItem.right - dis->rcItem.left + 1, itemHeight = dis->rcItem.bottom - dis->rcItem.top + 1;
HDC hdcMem = CreateCompatibleDC(dis->hDC);
HBITMAP hbmMem = CreateCompatibleBitmap(dis->hDC, itemWidth, itemHeight);
hbmMem = (HBITMAP)SelectObject(hdcMem, hbmMem);
+
RECT rect;
rect.top = 0;
rect.left = 0;
@@ -1216,8 +1216,8 @@ INT_PTR CMsgDialog::DlgProc(UINT msg, WPARAM wParam, LPARAM lParam)
BITMAP bminfo;
GetObject(m_hbmpAvatarPic, sizeof(bminfo), &bminfo);
if (bminfo.bmWidth != 0 && bminfo.bmHeight != 0) {
- avatarHeight = itemHeight;
- avatarWidth = bminfo.bmWidth * avatarHeight / bminfo.bmHeight;
+ int avatarHeight = itemHeight;
+ int avatarWidth = bminfo.bmWidth * avatarHeight / bminfo.bmHeight;
if (avatarWidth > itemWidth) {
avatarWidth = itemWidth;
avatarHeight = bminfo.bmHeight * avatarWidth / bminfo.bmWidth;
@@ -1331,27 +1331,6 @@ INT_PTR CMsgDialog::DlgProc(UINT msg, WPARAM wParam, LPARAM lParam)
return TRUE;
}
break;
-
- case IDC_SRMM_NICKLIST:
- if (pNmhdr->code == TTN_NEEDTEXT) {
- LPNMTTDISPINFO lpttd = (LPNMTTDISPINFO)lParam;
- SESSION_INFO *parentdat = (SESSION_INFO *)GetWindowLongPtr(m_hwnd, GWLP_USERDATA);
-
- POINT p;
- GetCursorPos(&p);
- ScreenToClient(m_nickList.GetHwnd(), &p);
- int item = LOWORD(m_nickList.SendMsg(LB_ITEMFROMPOINT, 0, MAKELPARAM(p.x, p.y)));
- USERINFO *ui = g_chatApi.SM_GetUserFromIndex(parentdat->ptszID, parentdat->pszModule, item);
- if (ui != nullptr) {
- static wchar_t ptszBuf[1024];
- mir_snwprintf(ptszBuf, L"%s: %s\r\n%s: %s\r\n%s: %s",
- TranslateT("Nickname"), ui->pszNick,
- TranslateT("Unique ID"), ui->pszUID,
- TranslateT("Status"), g_chatApi.TM_WordToString(parentdat->pStatuses, ui->Status));
- lpttd->lpszText = ptszBuf;
- }
- }
- break;
}
break;