|
|
|
|
@ -61,6 +61,7 @@ static gui_radio_talk_fn g_radio_talk_cb = nullptr;
|
|
|
|
|
static gui_dm_msg_received_fn g_dm_msg_received_cb = nullptr; |
|
|
|
|
static gui_dm_conv_updated_fn g_dm_conv_updated_cb = nullptr; |
|
|
|
|
static gui_dm_messages_fn g_dm_messages_cb = nullptr; |
|
|
|
|
static gui_dm_messages_fn g_attachment_preparation_cb = nullptr; |
|
|
|
|
static struct UASYNC* g_ua = nullptr; |
|
|
|
|
static struct UTUN_INSTANCE* g_inst = nullptr; |
|
|
|
|
|
|
|
|
|
@ -270,6 +271,9 @@ void GuiBridgeReceiver::processPost(int eventType, QByteArray data) {
|
|
|
|
|
case GUI_EVT_DM_MESSAGES: |
|
|
|
|
if (g_dm_messages_cb) g_dm_messages_cb(d, dlen); |
|
|
|
|
break; |
|
|
|
|
case CHAT_EVT_ATTACHMENT_PREPARATION: |
|
|
|
|
if (g_attachment_preparation_cb) g_attachment_preparation_cb(d, dlen); |
|
|
|
|
break; |
|
|
|
|
case GUI_EVT_CALL_INCOMING: |
|
|
|
|
if (dlen >= 1 + 8 + 8) { |
|
|
|
|
uint8_t chLen = d[0]; |
|
|
|
|
@ -542,6 +546,10 @@ void gui_bridge_set_dm_messages_cb(gui_dm_messages_fn cb) {
|
|
|
|
|
g_dm_messages_cb = cb; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
void gui_bridge_set_attachment_preparation_cb(gui_dm_messages_fn cb) { |
|
|
|
|
g_attachment_preparation_cb = cb; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
} /* extern "C" */ |
|
|
|
|
|
|
|
|
|
/* ── uTun nodeinfo callback (called from uasync thread) ── */ |
|
|
|
|
|