flutter_downloader
flutter_downloader copied to clipboard
No way to change notification icon on android. Always show a grey circle.
If you want to use a custom notification icon add the code below to the AndroidManifest.xml in your project.
<meta-data
android:name="vn.hunghd.flutterdownloader.NOTIFICATION_ICON"
android:resource="@drawable/ic_stat_logo" />
You can also use icons-launcher to create your drawables.
According to the official example, you should add NOTIFICATION_ICON https://github.com/fluttercommunity/flutter_downloader/blob/master/example/android/app/src/main/AndroidManifest.xml
<!-- Begin FlutterDownloader customization -->
<!-- disable default Initializer -->
<provider
android:name="androidx.startup.InitializationProvider"
android:authorities="${applicationId}.androidx-startup"
android:exported="false"
tools:node="merge">
<meta-data
android:name="androidx.work.WorkManagerInitializer"
android:value="androidx.startup"
tools:node="remove" />
</provider>
<!-- declare customized Initializer -->
<provider
android:name="vn.hunghd.flutterdownloader.FlutterDownloaderInitializer"
android:authorities="${applicationId}.flutter-downloader-init"
android:exported="false">
<meta-data
android:name="vn.hunghd.flutterdownloader.MAX_CONCURRENT_TASKS"
android:value="5" />
</provider>
<!-- End FlutterDownloader customization -->
<meta-data
android:name="vn.hunghd.flutterdownloader.NOTIFICATION_ICON"
android:resource="@drawable/ic_stat_logo" />