Merge pull request #1077 from nebbishhacker/android

android: Send notification id when handling notifications
pull/1080/head^2
Gordon Williams 2021-12-14 09:11:51 +00:00 committed by GitHub
commit 86df140ff5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 3 additions and 2 deletions

View File

@ -98,7 +98,7 @@
"id": "android",
"name": "Android Integration",
"shortName": "Android",
"version": "0.04",
"version": "0.05",
"description": "Display notifications/music/etc from Gadgetbridge on Android. This replaces the old Gadgetbridge widget.",
"icon": "app.png",
"tags": "tool,system,messages,notifications",

View File

@ -3,3 +3,4 @@
Fix music control
0.03: Handling of message actions (ok/clear)
0.04: Android icon now goes to settings page with 'find phone'
0.05: Fix handling of message actions

View File

@ -65,7 +65,7 @@
// Message response
Bangle.messageResponse = (msg,response) => {
if (msg.id=="call") return gbSend({ t: "call", n:response?"ACCEPT":"REJECT" });
if (isFinite(msg.id)) return gbSend({ t: "notify", n:response?"OPEN":"DISMISS" });
if (isFinite(msg.id)) return gbSend({ t: "notify", n:response?"OPEN":"DISMISS", id: msg.id });
// error/warn here?
};
})();