Dropsource / monarch

Monarch is a tool for building Flutter widgets in isolation. It makes it easy to build, test and debug complex UIs.
https://monarchapp.io
MIT License
433 stars 22 forks source link

On Windows, closing one Monarch window should close the other one #58

Open fertrig opened 1 year ago

fertrig commented 1 year ago

Closing any Monarch window should close the other one. Otherwise Monarch remains running with one window which may cause further errors.

fertrig commented 1 year ago

Due to a Dart bug on Windows, we are not able to kill Windows processes using Process.kill.

See Github issues:

To close the Monarch windows we would have to do it by its window title. We can use WindowsTerminator here: https://github.com/Dropsource/monarch/blob/main/cli/lib/src/task_runner/terminator.dart

The Preview window title changes based on user selection, that one may be tricky to reliably close.