Is it possible to lock an Android device from a Flutter app? - flutter

Would it be possible to prevent the user from accessing their device for a period of time say 1 minute from a Flutter application?

there are couple of plugins out there
you can check them
One of the plugin to lock Screen
if it doesn't help you can do it your self with native code via Method Channels
Writing custom platform-specific code
Hope that will help you.

Related

I'm using flutter : is there a way with a mobile flutter app to launch another flutter app on another device

I want, with my flutter app installed on my device, to launch an app on another device.
And share information if possible. Thanks.
from what I understood from you I can tell that you can't, the system restricts background possess you can read about it here

Flutter application restart instead of resuming after some time when switch to other applications

Hi i am developing a flutter application and i am using getx statemanagment. The problem is when i put application in background and use some other applications like whatsapp,youtube,play a game or listen music, after some time when i resume my application from recents it restarts and all progress is lost.
I have already tried different solutions like moveTaskToback(true) with native android function call
Please help, I have almost finished my important application.
I'm not sure on why this happens, but some manufacturers have their own restrictions on apps running in the background. Nothing you can really do from a flutter perspective, the app lifecycle is the same on all devices.
Here is a link where they share some tips how to deal with this on Xiaomi from the users perspective.
https://dontkillmyapp.com/xiaomi
From the developers perspective, as you can read on the bottom of the article, the are no common workarounds known yet.

Flutter Detect Notification Tray Pulldown

I'm trying to implement a feature based on the background/foreground status of a Flutter app.
Does anyone know of a way to detect if the notification/system try on a device is pulled down over the app?
Thanks.
Welcome to SOF
You can detect this using special permission in Android (https://developer.android.com/reference/android/Manifest.permission#EXPAND_STATUS_BAR).
But you need native code to run in Flutter.
There is a similar (almost) package out there, you may fork it:
https://pub.dev/packages/notification_shade

Making Apps using flutter

Is it possible to build a fully functioning application for iOS and Android using AndroidStudio + Flutter and FireBase alone? This is my first time trying to make a fully functioning mobile application which I want to use as I am constrained with my finances at the moment. I would appreciate the clarification.
Yes, it is possible to make both Android and IOS app using flutter and dart.
Flutter has many benefits. here some example :
Flutter hot reload helps you to build your app very fast.
User fluent. Can use app with excellent user interface design.
It's easy to use function like other OOP languages.
Update everyday with new features.
Flutter user community is increasing day by day .
Check the flutter docs for more info
Yes, Flutter can produce a fully functioning application for both iOS and Android platforms.
there are some apps built with Flutter. check them here
I am a native Android developer and I did some iOS as well. I started learning Flutter a couple of days ago and it seems promising.

Flutter : Run an app as a background service

I want to show a custom popup message whenever the user disconnects a cellular call. The problem is how to detect when the app is not running. any leads would be helpful.
It's been a while and there have been many developments.
First, there are some answers at How to create a service in Flutter to make an app to run always in background?
Also, flutter/Background processes will basically point you to medium/Executing Dart in the Background with Flutter Plugins and Geofencing (Sept 2018)
which is a Geofencing sample that involves a partnership between isolates, native Android/iOS code via MethodChannel, and PluginUtilities.getCallbackHandle (PluginUtilities)
Alas, there are many plugins available now:
https://pub.dev/packages/background_location
https://pub.dev/packages/android_alarm_manager (Android)
https://pub.dev/packages/background_fetch
https://pub.dev/packages/workmanager
https://pub.dev/packages/audio_service