Commit 6bbea5d0 authored by Nikolay Sivov's avatar Nikolay Sivov Committed by Alexandre Julliard

comctl32/tooltips: Set current tool before sending TTN_NEEDTEXT.

parent 5312cc6d
......@@ -588,7 +588,7 @@ TOOLTIPS_Show (TOOLTIPS_INFO *infoPtr, BOOL track_activate)
NMHDR hdr;
int ptfx = 0;
DWORD style = GetWindowLongW(infoPtr->hwndSelf, GWL_STYLE);
INT nTool;
INT nTool, current;
if (track_activate)
{
......@@ -611,16 +611,20 @@ TOOLTIPS_Show (TOOLTIPS_INFO *infoPtr, BOOL track_activate)
TRACE("Show tooltip pre %d! (%p)\n", nTool, infoPtr->hwndSelf);
current = infoPtr->nCurrentTool;
if (!track_activate)
infoPtr->nCurrentTool = infoPtr->nTool;
TOOLTIPS_GetTipText (infoPtr, nTool, infoPtr->szTipText);
if (infoPtr->szTipText[0] == '\0')
{
infoPtr->nCurrentTool = current;
return;
}
toolPtr = &infoPtr->tools[nTool];
if (!track_activate)
infoPtr->nCurrentTool = infoPtr->nTool;
TRACE("Show tooltip %d!\n", nTool);
hdr.hwndFrom = infoPtr->hwndSelf;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment