mirror of
https://github.com/BlueBubblesApp/bluebubbles-app.git
synced 2025-08-06 19:44:08 +08:00
adds answer facetime as methodchannel handler
This commit is contained in:
@ -122,16 +122,6 @@ class MethodChannelService extends GetxService {
|
||||
notif.createFailedToSend(chat, scheduled: true);
|
||||
}
|
||||
return true;
|
||||
case "incoming-facetime":
|
||||
await storeStartup.future;
|
||||
Logger.info("Received incoming facetime from FCM");
|
||||
final replaced = call.arguments.toString().replaceAll("\\", "");
|
||||
Map<String, dynamic> data = jsonDecode(replaced.substring(1, replaced.length - 1)) ?? {};
|
||||
String? caller = data["caller"];
|
||||
if (caller != null) {
|
||||
notif.createFacetimeNotif(Handle(address: caller));
|
||||
}
|
||||
return true;
|
||||
case "reply":
|
||||
await storeStartup.future;
|
||||
Logger.info("Received reply to message from FCM");
|
||||
@ -210,6 +200,13 @@ class MethodChannelService extends GetxService {
|
||||
Map<String, dynamic> data = jsonDecode(call.arguments);
|
||||
await ActionHandler().handleFaceTimeStatusChange(data);
|
||||
return true;
|
||||
case "answer-facetime":
|
||||
Logger.info("Answering FaceTime call");
|
||||
Map<String, dynamic> data = jsonDecode(call.arguments);
|
||||
print(data["callUuid"]);
|
||||
print("FACETIME");
|
||||
// await intents.answerFaceTime(data["callUuid"]);
|
||||
return true;
|
||||
default:
|
||||
return true;
|
||||
}
|
||||
|
Reference in New Issue
Block a user