feat: Move over the contacts API

This commit is contained in:
2023-09-08 19:40:03 +02:00
parent 809ddfaf80
commit 6e6b50d0c2
16 changed files with 249 additions and 0 deletions

29
pigeon/contacts.dart Normal file
View File

@@ -0,0 +1,29 @@
import 'package:pigeon/pigeon.dart';
@ConfigurePigeon(
PigeonOptions(
dartOut: 'lib/pigeon/contacts.g.dart',
kotlinOut:
'android/src/main/kotlin/org/moxxy/moxxy_native/contacts/ContactsApi.kt',
kotlinOptions: KotlinOptions(
package: 'org.moxxy.moxxy_native.contacts',
),
),
)
/// The type of icon to use when no avatar path is provided.
enum FallbackIconType {
none,
person,
notes;
}
@HostApi()
abstract class MoxxyContactsApi {
void recordSentMessage(
String name,
String jid,
String? avatarPath,
FallbackIconType fallbackIcon,
);
}