1
0
mirror of https://codeberg.org/Freeyourgadget/Gadgetbridge synced 2024-11-27 12:26:48 +01:00

correct changelog (pebble health is also affected by userid and deviceid swapping)

This commit is contained in:
Andreas Shimokawa 2016-09-11 00:36:04 +02:00
parent 57a9a7ab0b
commit 053b9553bc
3 changed files with 5 additions and 7 deletions

View File

@ -1,7 +1,7 @@
###Changelog ###Changelog
####Version 0.12.1 ####Version 0.12.1
* Pebble: fix Morpheuz and Misfit data being associated with the wrong device and/or user in some cases causing them to invisible in charts * Pebble: Fix activity data being associated with the wrong device and/or user in some cases causing them to invisible in charts
* Remove special handling for Conversations notfications since upstream dropped special pebble support * Remove special handling for Conversations notfications since upstream dropped special pebble support
####Version 0.12.0 ####Version 0.12.0

View File

@ -56,7 +56,6 @@ public class NotificationListener extends NotificationListenerService {
private LimitedQueue mActionLookup = new LimitedQueue(16); private LimitedQueue mActionLookup = new LimitedQueue(16);
private final BroadcastReceiver mReceiver = new BroadcastReceiver() { private final BroadcastReceiver mReceiver = new BroadcastReceiver() {
@SuppressLint("NewApi")
@Override @Override
public void onReceive(Context context, Intent intent) { public void onReceive(Context context, Intent intent) {
String action = intent.getAction(); String action = intent.getAction();
@ -69,7 +68,7 @@ public class NotificationListener extends NotificationListenerService {
StatusBarNotification[] sbns = NotificationListener.this.getActiveNotifications(); StatusBarNotification[] sbns = NotificationListener.this.getActiveNotifications();
int handle = intent.getIntExtra("handle", -1); int handle = intent.getIntExtra("handle", -1);
for (StatusBarNotification sbn : sbns) { for (StatusBarNotification sbn : sbns) {
if ((int) sbn.getPostTime() == handle) { if (sbn.getId() == handle) {
if (action.equals(ACTION_OPEN)) { if (action.equals(ACTION_OPEN)) {
try { try {
PendingIntent pi = sbn.getNotification().contentIntent; PendingIntent pi = sbn.getNotification().contentIntent;
@ -92,7 +91,7 @@ public class NotificationListener extends NotificationListenerService {
StatusBarNotification[] sbns = NotificationListener.this.getActiveNotifications(); StatusBarNotification[] sbns = NotificationListener.this.getActiveNotifications();
int handle = intent.getIntExtra("handle", -1); int handle = intent.getIntExtra("handle", -1);
for (StatusBarNotification sbn : sbns) { for (StatusBarNotification sbn : sbns) {
if ((int) sbn.getPostTime() == handle) { if (sbn.getId() == handle) {
if (GBApplication.isRunningLollipopOrLater()) { if (GBApplication.isRunningLollipopOrLater()) {
String key = sbn.getKey(); String key = sbn.getKey();
NotificationListener.this.cancelNotification(key); NotificationListener.this.cancelNotification(key);
@ -276,8 +275,7 @@ public class NotificationListener extends NotificationListenerService {
LOG.info("Processing notification from source " + source); LOG.info("Processing notification from source " + source);
dissectNotificationTo(notification, notificationSpec); dissectNotificationTo(notification, notificationSpec);
notificationSpec.id = (int) sbn.getPostTime(); //FIMXE: a truly unique id would be better notificationSpec.id = sbn.getId();
NotificationCompat.WearableExtender wearableExtender = new NotificationCompat.WearableExtender(notification); NotificationCompat.WearableExtender wearableExtender = new NotificationCompat.WearableExtender(notification);
List<NotificationCompat.Action> actions = wearableExtender.getActions(); List<NotificationCompat.Action> actions = wearableExtender.getActions();
for (NotificationCompat.Action act : actions) { for (NotificationCompat.Action act : actions) {

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<changelog> <changelog>
<release version="0.12.1" versioncode="60"> <release version="0.12.1" versioncode="60">
<change>Pebble: fix Morpheuz and Misfit data being associated with the wrong device and/or user in some cases causing them to invisible in charts</change> <change>Pebble: fix activity data being associated with the wrong device and/or user in some cases causing them to invisible in charts</change>
<change>Remove special handling for Conversations notfications since upstream dropped special pebble support</change> <change>Remove special handling for Conversations notfications since upstream dropped special pebble support</change>
</release> </release>
<release version="0.12.0" versioncode="59"> <release version="0.12.0" versioncode="59">