Q:

Execute Intellij Idea action when Editor window looses focus

Is there a way to run an action in Intellij Idea when I switch to the Emulator (Intellij Idea Editor looses focus).
What I want to archive: when I switch to Android Emulator I want to see the code changes without pressing the Keyboard shortcut each time:

In case this is not possible, is there a way to listen to Editor window focus  changed event to write a small plugin ?
These are my current IDE settings:

Output of Flutter doctor:
flutter doctor -v
[√] Flutter (Channel dev, v1.2.2, on Microsoft Windows [Version 10.0.17134.590], locale en-US)
    • Flutter version 1.2.2 at C:\dev\flutter\sdks\flutter-sdk
    • Framework revision 007a415c2a (3 days ago), 2019-02-21 20:22:47 -0800
    • Engine revision f1f19bba8f
    • Dart version 2.2.0 (build 2.2.0-dev.2.1 c92d5ca288)

[√] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
    • Android SDK at C:\dev\android\sdk
    • Android NDK location not configured (optional; useful for native profiling support)
    • Platform android-28, build-tools 28.0.3
    • Java binary at: C:\Program Files\Android\Android Studio\jre\bin\java
    • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1248-b01)
    • All Android licenses accepted.

[!] Android Studio (version 3.3)
    • Android Studio at C:\Program Files\Android\Android Studio
    X Flutter plugin not installed; this adds Flutter specific functionality.
    X Dart plugin not installed; this adds Dart specific functionality.
    • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1248-b01)

[√] IntelliJ IDEA Community Edition (version 2018.3)
    • IntelliJ at C:\Program Files\JetBrains\IntelliJ IDEA Community Edition 2018.3.4
    • Flutter plugin version 33.2.2
    • Dart plugin version 183.5901

[!] VS Code, 64-bit edition (version 1.25.1)
    • VS Code at C:\Program Files\Microsoft VS Code
    X Flutter extension not installed; install from
      https://marketplace.visualstudio.com/items?itemName=Dart-Code.flutter

[√] Connected device (1 available)
    • Android SDK built for x86 • emulator-5554 • android-x86 • Android 8.1.0 (API 27) (emulator)

! Doctor found issues in 2 categories.

A:

Enable "Perform hot reload on save"

