desktop_lifecycle 0.1.0
desktop_lifecycle: ^0.1.0 copied to clipboard

Allow your flutter desktop application to perceive whether the window is activated.

desktop_lifecycle #

Pub

Allow your flutter desktop application to perceive whether the window is activated.

Getting Started #

  1. Add desktop_lifecycle to your pubspec.yaml.
  desktop_lifecycle: $latest_version
  1. Then you can use DesktopLifecycle.instance.isActive to listen window active event.
final ValueListenable<bool> event = DesktopLifecycle.instance.isActive;

final bool active = event.value;

event.addListener(() {
  debugPrint("window activate: ${event.value}");
});

LICENSE #

see LICENSE file

3
likes
100
pub points
68%
popularity

Publisher

mixin.dev

Allow your flutter desktop application to perceive whether the window is activated.

Homepage
Repository (GitHub)
View/report issues

Documentation

API reference

License

Apache-2.0 (LICENSE)

Dependencies

flutter

More

Packages that depend on desktop_lifecycle