i am using async_wallpaper package for changing a wallpaper in flutter app Now the problem I am facing right now is that- once I click to change wallpaper function the wallpaper is set successfully. but it deletes my content on the recycler view. I am facing this problem in android 12 and onwards.
E/BLASTBufferQueue(26235): BLASTBufferItemConsumer::onDisconnect()
D/WindowManager(26235): Add to mViews: DecorView@8355323[MainActivity],pkg= com.example.test_app I/Quality (26235): Skipped: false 20 cost 349.11414 refreshRate 0 processName com.example.test_app V/OplusZoomWindowDecorViewHelper(26235): setLastReportedMergedConfiguration mZoomDisplayHeight: 2400 getDecorView.137712419 I/Quality (26235): Skipped: false 2 cost 37.55423 refreshRate 0 processName com.example.test_app D/ViewRootImplMainActivity: debugCancelDraw some OnPreDrawListener onPreDraw return false,cancelDraw=true,count=50,android.view.ViewRootImpl@7e43dd9 D/SurfaceComposerClient(26235): VRR [FRTC] client handle [bufferId:18446744073709551615 framenumber:0] [ffffffff, ffffffff] D/ViewRootImplMainActivity: debugCancelDraw cancelDraw=false,count = 128,android.view.ViewRootImpl@7e43dd9 D/SurfaceComposerClient(26235): VRR [FRTC] client handle [bufferId:18446744073709551615 framenumber:0] [ffffffff, ffffffff]
my problem as same as this question in flutter please help me out .
Setting wallpaper deletes my recyler view content.
It seems it is related to the Material You theming.
I would like to disable the restarting of activity when my app comes to the foreground. Is there a way?
i have tried to use material 3 in my flutter app to resolve this issue but its not help me out.