mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge
synced 2025-01-28 02:27:32 +01:00
Skip long notification text if blank
This commit is contained in:
parent
a89b6f0006
commit
8a6171962b
@ -628,8 +628,9 @@ public class NotificationListener extends NotificationListenerService {
|
|||||||
}
|
}
|
||||||
|
|
||||||
CharSequence contentCS = null;
|
CharSequence contentCS = null;
|
||||||
if (preferBigText && extras.containsKey(Notification.EXTRA_BIG_TEXT)) {
|
final CharSequence bigText = extras.getCharSequence(NotificationCompat.EXTRA_BIG_TEXT);
|
||||||
contentCS = extras.getCharSequence(NotificationCompat.EXTRA_BIG_TEXT);
|
if (preferBigText && !StringUtils.isBlank(bigText)) {
|
||||||
|
contentCS = bigText;
|
||||||
} else if (extras.containsKey(Notification.EXTRA_TEXT)) {
|
} else if (extras.containsKey(Notification.EXTRA_TEXT)) {
|
||||||
contentCS = extras.getCharSequence(NotificationCompat.EXTRA_TEXT);
|
contentCS = extras.getCharSequence(NotificationCompat.EXTRA_TEXT);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user