Skip to content

MouseRegion does not update until mouse is moved #76622

@esDotDev

Description

@esDotDev

The mouse-region widget does not correctly update the cursor, until the mouse is moved.

Here's a video showing the issue:
https://user-images.githubusercontent.com/736973/108889501-b1fdab00-75c9-11eb-9116-42023328fd29.mp4

The basic code example is that there is some overlay layer, inside a stack, that turns on to enable this cursor:

if (_isSpaceBarDown) ...{
                      MouseRegion(
                        cursor: SystemMouseCursors.move,
                        child: Container(color: Colors.transparent),
                      )
                    }

In this case _isSpaceBarDown is obtained using RawKeyboard.instance.addListener and a setState is called when it changes.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Important issues not at the top of the work lista: desktopRunning on desktopa: mouseIssues related to using a mouse or mouse supportcustomer: chilliengineflutter/engine related. See also e: labels.found in release: 2.10Found to occur in 2.10found in release: 2.13Found to occur in 2.13has reproducible stepsThe issue has been confirmed reproducible and is ready to work onplatform-windowsBuilding on or for Windows specificallyr: fixedIssue is closed as already fixed in a newer versionteam-windowsOwned by the Windows platform team

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions