<p>You need to Wrap your widget inside a Listner. Listener helps to track Mouse Touch and Trackpad events. Here is the example, color: rgb(212, 212, 212); background-color: rgb(30, 30, 30); font-family: Consolas, "Courier New", monospace; font-size: 14px; line-height: 19px; white-space: pre;](color: #569cd6;](bool _animiplaying = color: #569cd6;](false; color: #569cd6;](void _startanime(PointerEnterEvent _) => setState(() => _animiplaying = color: #569cd6;](true);color: #569cd6;](void _stopanime(PointerExitEvent _) => setState(() => _animiplaying = color: #569cd6;](false); Listner( onPointerEnter: _startanime(), onPointerExit: _stopanime(), child: ... color: #6a9955;](//assign the _animiplaying to the widget to get the action color: #6a9955;](//AnimiWidget is a user defined widged used for example here, and it should accept animeplaying property. AnimeWidget(animeplaying: _animiplaying) ...)</p>
How to do mouse hover in Flutter?
This Article is posted by seven.srikanth at 5/23/2019 6:22:51 PM
Check out our other latest articles
Safearea widget - How to avoid visual overlap with Notch on flutter mobile app?How to convert row of widgets into column of widgets in flutter based on screen size?
How to run Flutter programs from GitHub?
How to get screen orientation in flutter?
NavigationRail example in flutter
Tags: mouse hover; mouse events;
Check out our other latest articles
Safearea widget - How to avoid visual overlap with Notch on flutter mobile app?How to convert row of widgets into column of widgets in flutter based on screen size?
How to run Flutter programs from GitHub?
How to get screen orientation in flutter?
NavigationRail example in flutter