Flutter: Floating Button in Front of Other Apps

3,231

Solution 1

You can perform the similar action using Draggable widget but that will work only inside the app and inside same Stateful/Stateless widget.

The reason why "drawing over other apps" is not possible in Flutter till yet is because iOS does not support this functionality. You can always log an issue at Flutter's GitHub repository

Solution 2

Apart from restriction that it won't work on IOS, there is a plugin in flutter which does the trick System Alert Window

It shows Truecaller like overlay window, over all other apps along with callback events

Share:
3,231
Constantine
Author by

Constantine

Updated on December 08, 2022

Comments

  • Constantine
    Constantine over 1 year

    how can i achive a floating action button in front of all other apps?

    A java example could be: https://www.journaldev.com/14673/android-floating-widget.

    What flutter widget can i use for that. Maybe there are some examples with flutter (didn't found any).

    Thanks

  • Constantine
    Constantine over 5 years
    I am a beginner on mobile development and with flutter even more. And this is an interesting point, which i have not thought about before. By using a single framework for both android and ios (flutter) I can be limited in functions because i can use only those things that are usable for both operating systems. The "floating button in front of all apps" is just one little thing. There could be many more things that won't work with flutter.
  • Daksh Gargas
    Daksh Gargas over 5 years
    Everything has its caveats too :)
  • Undefitied
    Undefitied almost 5 years
    Doesn't Facebook Messanger has this functionality on iOS?
  • Daksh Gargas
    Daksh Gargas almost 5 years
    @Undefitied nope, it's called "App Overlay" and is available only on Android.