CrossGeeks/AzurePushNotificationPlugin

Notification Icon problems when android app is stopped

Opened this issue · 1 comments

Hi. We have recently started using your plugin on our mobile app.

We are setting the notification icon in MainActivity.cs with the following:

        AzurePushNotificationManager.NotificationContentTitleKey = "Some Title";
        **AzurePushNotificationManager.IconResource = Resource.Drawable.notifications;**
        AzurePushNotificationManager.ProcessIntent(this, Intent);

The notifications are being received correctly. The icon displays fine when the notification is received when the app is in the foreground or background. The problem we are experiencing is as follows:

When the app is killed / stopped and a notification is received, our samsung devices, will display a white box rather than the icon.
When the app is killed / stopped and a notification is received, our Huawei device displays the app icon rather than the notification icon (which is an improvement to the samsung, but still confusing).

In androidmanifest we have:

<application android:label="Test App" android:icon="@drawable/icon" android:largeHeap="true" android:allowBackup="false" android:theme="@style/Light" android:usesCleartextTraffic="true">

At the top of MainActivity.cs we also have:

[Activity(Label = nameof(OurApp), Icon = "@drawable/icon", Theme = "@style/Light", MainLauncher = false, ConfigurationChanges = ConfigChanges.ScreenSize, ScreenOrientation = ScreenOrientation.Portrait)]

which also refers to the app icon. I'm not sure which of these 2 places, the app icon is being picked up from on the Huawei.

Do you have any ideas why we have the inconsistencies and how to can get the Samsung devices to display an icon please?

Thank you for a great plugin.

Sarah