[0.4.9][COMCTL32] Updown Suppress the NM_RELEASEDCAPTURE notification CORE-14365

This fixes a strange toggle-back-effect in 'Zeckensacks Glide Wrapper 0.84c'
by importing Wine commit
9dbe886e3f
Thanks to patches author Akihiro Sagawa <sagawa.aki@gmail.com>

Fix picked from 0.4.13-dev-1169-g 841732e45c

This was no regression, but I could not resist porting it back, because it's just
too tempting to fix a bug by deleting code. Win-win!
This commit is contained in:
Joachim Henze 2020-12-18 01:42:08 +01:00
parent d3a79fe2e6
commit 959f2dd103

View file

@ -781,14 +781,8 @@ static BOOL UPDOWN_CancelMode (UPDOWN_INFO *infoPtr)
KillTimer (infoPtr->Self, TIMER_ACCEL);
KillTimer (infoPtr->Self, TIMER_AUTOPRESS);
if (GetCapture() == infoPtr->Self) {
NMHDR hdr;
hdr.hwndFrom = infoPtr->Self;
hdr.idFrom = GetWindowLongPtrW (infoPtr->Self, GWLP_ID);
hdr.code = NM_RELEASEDCAPTURE;
SendMessageW(infoPtr->Notify, WM_NOTIFY, hdr.idFrom, (LPARAM)&hdr);
ReleaseCapture();
}
if (GetCapture() == infoPtr->Self)
ReleaseCapture();
infoPtr->Flags &= ~FLAG_PRESSED;
InvalidateRect (infoPtr->Self, NULL, FALSE);