use accent color for notif title

closes sk22#461
This commit is contained in:
sk
2023-03-20 22:19:15 +01:00
parent b650ca85bc
commit f9607a434a

View File

@@ -55,6 +55,7 @@ public class PushNotificationReceiver extends BroadcastReceiver{
@Override @Override
public void onReceive(Context context, Intent intent){ public void onReceive(Context context, Intent intent){
UiUtils.setUserPreferredTheme(context);
if(BuildConfig.DEBUG){ if(BuildConfig.DEBUG){
Log.e(TAG, "received: "+intent); Log.e(TAG, "received: "+intent);
Bundle extras=intent.getExtras(); Bundle extras=intent.getExtras();
@@ -185,7 +186,7 @@ public class PushNotificationReceiver extends BroadcastReceiver{
.setShowWhen(true) .setShowWhen(true)
.setCategory(Notification.CATEGORY_SOCIAL) .setCategory(Notification.CATEGORY_SOCIAL)
.setAutoCancel(true) .setAutoCancel(true)
.setColor(context.getColor(R.color.shortcut_icon_background)); .setColor(UiUtils.getThemeColor(context, android.R.attr.colorAccent));
if (!GlobalUserPreferences.uniformNotificationIcon) { if (!GlobalUserPreferences.uniformNotificationIcon) {
builder.setSmallIcon(switch (pn.notificationType) { builder.setSmallIcon(switch (pn.notificationType) {