diff options
author | George Hazan <george.hazan@gmail.com> | 2023-12-04 17:53:49 +0300 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2023-12-04 17:53:49 +0300 |
commit | 03b94ae84e786dac1eff683f03f8849bc589df93 (patch) | |
tree | 4cdf9381816031db426326b1eedc45a805c45478 /plugins | |
parent | 20a428faac18282f5c15546e0c375922f712d7cb (diff) |
fixes #4008 (tabSRMM: панель ответа пересекается с панелью кнопок)
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/TabSRMM/src/msgdialog.cpp | 11 | ||||
-rw-r--r-- | plugins/TabSRMM/src/sendqueue.cpp | 37 |
2 files changed, 27 insertions, 21 deletions
diff --git a/plugins/TabSRMM/src/msgdialog.cpp b/plugins/TabSRMM/src/msgdialog.cpp index 16f6b9f61c..767d297df5 100644 --- a/plugins/TabSRMM/src/msgdialog.cpp +++ b/plugins/TabSRMM/src/msgdialog.cpp @@ -1246,6 +1246,9 @@ int CMsgDialog::Resizer(UTILRESIZECONTROL *urc) if (m_bIsAutosizingInput)
urc->rcItem.top -= DPISCALEY_S(1);
+ if (m_hQuoteEvent)
+ urc->rcItem.top += 22;
+
m_rcMessage = urc->rcItem;
if (CSkin::m_skinEnabled) {
@@ -1261,16 +1264,16 @@ int CMsgDialog::Resizer(UTILRESIZECONTROL *urc) case IDC_SRMM_QUOTE:
urc->rcItem = m_rcMessage;
- urc->rcItem.top -= 22;
+ urc->rcItem.top -= DPISCALEY_S(22);
urc->rcItem.bottom = m_rcMessage.top;
- urc->rcItem.right -= 22;
+ urc->rcItem.right -= DPISCALEY_S(22);
return RD_ANCHORX_CUSTOM | RD_ANCHORY_CUSTOM;
case IDC_SRMM_CLOSEQUOTE:
urc->rcItem = m_rcMessage;
- urc->rcItem.top -= 22;
+ urc->rcItem.top -= DPISCALEY_S(22);
urc->rcItem.bottom = m_rcMessage.top;
- urc->rcItem.left = m_rcMessage.right - 22;
+ urc->rcItem.left = m_rcMessage.right - DPISCALEY_S(22);
return RD_ANCHORX_CUSTOM | RD_ANCHORY_CUSTOM;
case IDC_MULTISPLITTER:
diff --git a/plugins/TabSRMM/src/sendqueue.cpp b/plugins/TabSRMM/src/sendqueue.cpp index 6028357c3c..4a2f85e618 100644 --- a/plugins/TabSRMM/src/sendqueue.cpp +++ b/plugins/TabSRMM/src/sendqueue.cpp @@ -191,14 +191,16 @@ int SendQueue::sendQueued(CMsgDialog *dat, const int iEntry) {
HWND hwndDlg = dat->GetHwnd();
CContactCache *ccActive = CContactCache::getContactCache(dat->m_hContact);
+ auto &J = m_jobs[iEntry];
if (dat->m_sendMode & SMODE_MULTIPLE) {
int iJobs = 0;
size_t iMinLength = 0;
- m_jobs[iEntry].iStatus = SQ_INPROGRESS;
- m_jobs[iEntry].hContact = ccActive->getActiveContact();
- m_jobs[iEntry].hOwnerWnd = hwndDlg;
+ J.iStatus = SQ_INPROGRESS;
+ J.hContact = ccActive->getActiveContact();
+ J.hEvent = dat->m_hQuoteEvent;
+ J.hOwnerWnd = hwndDlg;
size_t iSendLength = getSendLength(iEntry);
@@ -243,23 +245,24 @@ int SendQueue::sendQueued(CMsgDialog *dat, const int iEntry) if (!fSplit)
goto send_unsplitted;
- m_jobs[iEntry].hContact = ccActive->getActiveContact();
- m_jobs[iEntry].hEvent = dat->m_hQuoteEvent;
- m_jobs[iEntry].hOwnerWnd = hwndDlg;
- m_jobs[iEntry].iStatus = SQ_INPROGRESS;
- m_jobs[iEntry].iAcksNeeded = 1;
- m_jobs[iEntry].chunkSize = (int)iMaxSize;
+ J.hContact = ccActive->getActiveContact();
+ J.hEvent = dat->m_hQuoteEvent;
+ J.hOwnerWnd = hwndDlg;
+ J.iStatus = SQ_INPROGRESS;
+ J.iAcksNeeded = 1;
+ J.chunkSize = (int)iMaxSize;
- uint32_t dwOldFlags = m_jobs[iEntry].dwFlags;
+ uint32_t dwOldFlags = J.dwFlags;
mir_forkthread(DoSplitSendA, (LPVOID)iEntry);
- m_jobs[iEntry].dwFlags = dwOldFlags;
+ J.dwFlags = dwOldFlags;
}
else {
send_unsplitted:
- m_jobs[iEntry].hContact = ccActive->getActiveContact();
- m_jobs[iEntry].hOwnerWnd = hwndDlg;
- m_jobs[iEntry].iStatus = SQ_INPROGRESS;
- m_jobs[iEntry].iAcksNeeded = 1;
+ J.hContact = ccActive->getActiveContact();
+ J.hEvent = dat->m_hQuoteEvent;
+ J.hOwnerWnd = hwndDlg;
+ J.iStatus = SQ_INPROGRESS;
+ J.iAcksNeeded = 1;
if (dat->m_sendMode & SMODE_SENDLATER) {
wchar_t tszError[256];
@@ -274,12 +277,12 @@ int SendQueue::sendQueued(CMsgDialog *dat, const int iEntry) clearJob(iEntry);
return 0;
}
- m_jobs[iEntry].iSendId = ProtoChainSend(dat->m_hContact, PSS_MESSAGE, m_jobs[iEntry].hEvent, (LPARAM)m_jobs[iEntry].szSendBuffer);
+ J.iSendId = ProtoChainSend(dat->m_hContact, PSS_MESSAGE, J.hEvent, (LPARAM)J.szSendBuffer);
if (dat->m_sendMode & SMODE_NOACK) { // fake the ack if we are not interested in receiving real acks
ACKDATA ack = {};
ack.hContact = dat->m_hContact;
- ack.hProcess = (HANDLE)m_jobs[iEntry].iSendId;
+ ack.hProcess = (HANDLE)J.iSendId;
ack.type = ACKTYPE_MESSAGE;
ack.result = ACKRESULT_SUCCESS;
SendMessage(hwndDlg, HM_EVENTSENT, (WPARAM)MAKELONG(iEntry, 0), (LPARAM)&ack);
|