Deliver radio invitation events to desktop UI
This commit is contained in:
1 parent
849f1c8618
commit
310d997af3
2 files changed
+7
No files matched your search
@@ -261,6 +261,8 @@ void gui_bridge_set_attachment_keys_cb(gui_dm_messages_fn cb);
|
||||
void gui_bridge_set_feedback_result_cb(gui_dm_messages_fn cb);
|
||||
void gui_bridge_set_msg_submitted_cb(gui_dm_messages_fn cb);
|
||||
void gui_bridge_set_radio_mute_result_cb(gui_dm_messages_fn cb);
|
||||
/* CHAT_EVT_RADIO_CALL: id/group/peer:8LE,state/reason/incoming:1, GUI-поток. */
|
||||
void gui_bridge_set_radio_call_cb(gui_dm_messages_fn cb);
|
||||
void gui_bridge_set_stream_sources_cb(gui_dm_messages_fn cb);
|
||||
int gui_bridge_toggle_member_radio_mute(const char* channel_id, uint64_t node_id);
|
||||
/* CHAT_EVT_ATTACHMENT_PREPARATION: target + job UUID + state. */
|
||||
|
||||
@@ -81,6 +81,7 @@ static gui_dm_messages_fn g_attachment_keys_cb = nullptr;
|
||||
static gui_dm_messages_fn g_feedback_result_cb = nullptr;
|
||||
static gui_dm_messages_fn g_msg_submitted_cb = nullptr;
|
||||
static gui_dm_messages_fn g_radio_mute_result_cb = nullptr;
|
||||
static gui_dm_messages_fn g_radio_call_cb = nullptr;
|
||||
static gui_dm_messages_fn g_stream_sources_cb = nullptr;
|
||||
static gui_network_changed_fn g_network_changed_cb = nullptr;
|
||||
static struct UASYNC* g_ua = nullptr;
|
||||
@@ -96,6 +97,9 @@ void GuiBridgeReceiver::processPost(int eventType, QByteArray data) {
|
||||
eventType == 16 || eventType == 17 || eventType == 24 || eventType == 25 || eventType == 31 || eventType == 33))
|
||||
g_network_changed_cb(eventType);
|
||||
switch (eventType) {
|
||||
case CHAT_EVT_RADIO_CALL:
|
||||
if (g_radio_call_cb) g_radio_call_cb(d, dlen);
|
||||
break;
|
||||
case CHAT_EVT_LOCAL_DEVICES:
|
||||
if (g_local_devices_cb) g_local_devices_cb(d, dlen);
|
||||
break;
|
||||
@@ -646,6 +650,7 @@ void gui_bridge_set_attachment_keys_cb(gui_dm_messages_fn cb) { g_attachment_key
|
||||
void gui_bridge_set_feedback_result_cb(gui_dm_messages_fn cb) { g_feedback_result_cb = cb; }
|
||||
void gui_bridge_set_msg_submitted_cb(gui_dm_messages_fn cb) { g_msg_submitted_cb = cb; }
|
||||
void gui_bridge_set_radio_mute_result_cb(gui_dm_messages_fn cb) { g_radio_mute_result_cb = cb; }
|
||||
void gui_bridge_set_radio_call_cb(gui_dm_messages_fn cb) { g_radio_call_cb = cb; }
|
||||
|
||||
int gui_bridge_toggle_member_radio_mute(const char* channel_id, uint64_t node_id) {
|
||||
const int running = g_inst && g_ua ? uasync_is_running(g_ua) : 0;
|
||||
|
||||
Reference in new issue
Block a user