feat: add "pinned messages" API

This commit is contained in:
B. Petersen
2026-08-04 15:30:57 +02:00
committed by biørn
parent 1247d5da36
commit bd0c0b6b4b
14 changed files with 477 additions and 1 deletions

View File

@@ -3904,6 +3904,16 @@ pub unsafe extern "C" fn dc_msg_get_saved_msg_id(msg: *const dc_msg_t) -> u32 {
.unwrap_or(0)
}
#[unsafe(no_mangle)]
pub unsafe extern "C" fn dc_msg_is_pinned(msg: *mut dc_msg_t) -> libc::c_int {
if msg.is_null() {
eprintln!("ignoring careless call to dc_msg_is_pinned()");
return 0;
}
let ffi_msg = unsafe { &*msg };
ffi_msg.message.is_pinned().into()
}
// dc_contact_t
/// FFI struct for [dc_contact_t]