View Issue Details

IDProjectCategoryView StatusLast Update
0001511NoesisGUIC++ SDKpublic2019-07-05 17:30
ReporternikobarliAssigned Tosfernandez 
PrioritynormalSeveritymajorReproducibilityalways
Status resolvedResolutionfixed 
Product Version2.2.3 
Target VersionFixed in Version2.2.4 
Summary0001511: Tooltips shown without activating the hosting window, doesn't disappears when the mouse cursor leave the hosting window
DescriptionRelated to issue https://www.noesisengine.com/bugs/view.php?id=1438

STR

1. Create a Noesis window with the following XAML

        <Button FontSize="40" Content="Button 3">
            <ToolTipService.ToolTip>
                <TextBlock FontSize="20" Text="Hey"/>
            </ToolTipService.ToolTip>
        </Button>

2. Make sure the window is not active
3. Move the mouse to hover on top of the button -> Tool tip is shown
4. Move the mouse out-of-the window (then activate other window)
-> tooltip is still shown
-> expected: tooltip disappears when the mouse move out of the window
TagsNo tags attached.
PlatformAny

Activities

sfernandez

sfernandez

2019-07-02 12:11

manager   ~0005797

Hi, the problem is that our Win32Display implementation is not tracking mouse position when mouse leaves the window, so the latest WM_MOUSEMOVE received is inside the window and over the Button that shows the ToolTip, keeping the tooltip visible.

I made a simple test using TrackMouseEvent to generate a last MouseMove event when WM_MOUSELEAVE is received and then it works as expected:
case WM_MOUSEMOVE:
{
    if (!mTrackingMouse)
    {
        TRACKMOUSEEVENT e =
        {
            sizeof(TRACKMOUSEEVENT),
            TME_LEAVE,
            mWindowHandle,
            HOVER_DEFAULT
        };
        TrackMouseEvent(&e);
        mTrackingMouse = true;
    }

    mMouseMove(this, GET_X_LPARAM(lParam), GET_Y_LPARAM(lParam));
    return false;
}

case WM_MOUSELEAVE:
{
    mTrackingMouse = false;
    POINT mousePos;
    GetCursorPos(&mousePos);
    ScreenToClient(mWindowHandle, &mousePos);

    // make sure it is outside right-bottom border of client area
    if (mousePos.x > 0) mousePos.x += 1;
    if (mousePos.y > 0) mousePos.y += 1;

    mMouseMove(this, mousePos.x, mousePos.y);
    return true;
}

We will include this in the next release.
nikobarli

nikobarli

2019-07-03 08:29

reporter   ~0005799

Hi Sergio,

Thanks. I confirmed that fixed the issue.

Issue History

Date Modified Username Field Change
2019-07-02 04:01 nikobarli New Issue
2019-07-02 12:11 sfernandez Assigned To => sfernandez
2019-07-02 12:11 sfernandez Status new => feedback
2019-07-02 12:11 sfernandez Note Added: 0005797
2019-07-03 08:29 nikobarli Note Added: 0005799
2019-07-03 08:29 nikobarli Status feedback => assigned
2019-07-05 17:30 sfernandez Status assigned => resolved
2019-07-05 17:30 sfernandez Resolution open => fixed
2019-07-05 17:30 sfernandez Fixed in Version => 2.2.4