Is it possible somehow to display Android homescreen widget as a Flutter widget?
I've read about PlatformView widget that can embed any Android view inside Flutter app. How is it possible to do the same with homescreen widgets?
I found a github project which is only for android in flutter but
initially has much to solve the problem
This flutter_home_screen_widget_example
github repo
Also found a similar github issue26134 requesting for the same
Got two more related stackoverflow questions
questions/44120149/android-lock-screen-widget-in-flutter
questions/47870740/flutter-is-it-somehow-possible-to-create-app-widgets-android-and-today-extens#47887388
There is no official support from flutter but you can take a look at this video explaining how to create a home widget using flutter unfortunately the speak he didn't post the code. It looks like the only solution to add the app widget android code in the generated code which means you should know android development in kotlin/java.
Related
I want to automatically create a widget in android studio for my react native app. The android studio documentation shows that this can be done by going to new>widget>app widget. But my widget function is not displayed. How can I fix this? Thanks in advance for your reply.This is what I have
This is what is in the documentation
Xml-> design-> Left -> Palette
: https://i.stack.imgur.com/SY7HT.png
I have a very complex flutter app with story book and everything, and I'd like to reuse the code inside my native Kotlin app, but it's a lot of screens, login and everything, and it has flutter_storybook
I've tried following the flutter docs tutorial for integrating as a module (considering just my main.dart as entry point), but I ended stuck with a black screen everytime I try to launch de FlutterActivity, is there anything more I need to do????
I have a native Android App and I want to try Flutter to display all my Android layouts.
I tried the MethodChannel but I feel like I'm missing something.
Can someone explain to me please how can I display a simple view (that exist already in Android xml layout) on Flutter?
Message channels are for passing data and events between Flutter and native app.
What you need is a platform view and AndroidView class in your particular case.
The steps to add the Android view are following:
Create Flutter Plugin (you can do this in Android Studio directly)
Register your view in the Android app
Add your AndroidView your Widget in Flutter app
More information on how to add Flutter to existing app can be found here.
Here, I am adding the image for more clarification of my problem statement.
You're looking to create a share activity for your Android app.
react-native-share-extension should provide you with a good starting point (as well as providing support for iOS if you're working on a Mac).
I am a bit new to android development so excuse me about that.
There is an Android Studio project on github: https://github.com/codeka/advbatterygraph
I compiled and installed it on my Nexus 5 and it worked fine. It's a widget which shows a graph with details about battery properties.
I'm trying to show this graph in a Activity class.
I searched a lot and tried to show it using ImageView but couldn't figured it out how to achieve it.
Any help/idea would be much appreciated!
Thanks.