title: How to detect user inactivity in Flutter
body: <p>I developed my app for Android using Java and now want to migrate to <a href="https://flutter.dev" rel="nofollow noreferrer">Flutter</a>.<br>
  <br>
  For <a href="https://stackoverflow.com/questions/4208730">detecting user inactivity</a> I override this method in my Activity: <code>onUserInteraction</code> and reset a <code>Timer</code>, if there is no user interaction, I show a Screen Saver like Animation.</p>
  <p>Is there Any clean way in Flutter to do this? I don't want to use <a href="https://flutter.dev/docs/development/platform-integration/platform-channels" rel="nofollow noreferrer">platform channels</a>. I want it pure Dart and flutter. I know I can set timer and reset it on user touch, but like in Android I want system to inform me about the user interaction.</p>