comctl32/tooltips: Set current tool before sending TTN_NEEDTEXT.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
5312cc6dc2
commit
6bbea5d074
|
@ -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;
|
||||
|
|
Loading…
Reference in New Issue