diff options
Diffstat (limited to 'source/blender/windowmanager/message_bus')
4 files changed, 22 insertions, 16 deletions
diff --git a/source/blender/windowmanager/message_bus/intern/wm_message_bus.c b/source/blender/windowmanager/message_bus/intern/wm_message_bus.c index 86a106462c3..81ef8c881f5 100644 --- a/source/blender/windowmanager/message_bus/intern/wm_message_bus.c +++ b/source/blender/windowmanager/message_bus/intern/wm_message_bus.c @@ -147,16 +147,6 @@ void WM_msgbus_handle(struct wmMsgBus *mbus, struct bContext *C) // printf("msgbus: keys=%u values=%u\n", a, b); } -/** - * \param msg_key_test: Needs following #wmMsgSubscribeKey fields filled in: - * - msg.params - * - msg.head.type - * - msg.head.id - * .. other values should be zeroed. - * - * \return The key for this subscription. - * note that this is only needed in rare cases when the key needs further manipulation. - */ wmMsgSubscribeKey *WM_msg_subscribe_with_key(struct wmMsgBus *mbus, const wmMsgSubscribeKey *msg_key_test, const wmMsgSubscribeValue *msg_val_params) @@ -239,9 +229,6 @@ void WM_msg_id_remove(struct wmMsgBus *mbus, const struct ID *id) * \note While we could have a separate type for ID's, use RNA since there is enough overlap. * \{ */ -/** - * \note #wmMsgBus.messages_tag_count isn't updated, caller must handle. - */ void wm_msg_subscribe_value_free(wmMsgSubscribeKey *msg_key, wmMsgSubscribeValueLink *msg_lnk) { if (msg_lnk->params.free_data) { diff --git a/source/blender/windowmanager/message_bus/intern/wm_message_bus_intern.h b/source/blender/windowmanager/message_bus/intern/wm_message_bus_intern.h index 24c0192fe14..18df17c3d1c 100644 --- a/source/blender/windowmanager/message_bus/intern/wm_message_bus_intern.h +++ b/source/blender/windowmanager/message_bus/intern/wm_message_bus_intern.h @@ -30,6 +30,9 @@ struct wmMsgBus { uint messages_tag_count; }; +/** + * \note #wmMsgBus.messages_tag_count isn't updated, caller must handle. + */ void wm_msg_subscribe_value_free(struct wmMsgSubscribeKey *msg_key, struct wmMsgSubscribeValueLink *msg_lnk); diff --git a/source/blender/windowmanager/message_bus/intern/wm_message_bus_rna.c b/source/blender/windowmanager/message_bus/intern/wm_message_bus_rna.c index 460dca57e4f..bc083793395 100644 --- a/source/blender/windowmanager/message_bus/intern/wm_message_bus_rna.c +++ b/source/blender/windowmanager/message_bus/intern/wm_message_bus_rna.c @@ -35,7 +35,9 @@ #include "RNA_access.h" -/* -------------------------------------------------------------------------- */ +/* -------------------------------------------------------------------- */ +/** \name Internal Utilities + * \{ */ BLI_INLINE uint void_hash_uint(const void *key) { @@ -208,7 +210,11 @@ void WM_msgtypeinfo_init_rna(wmMsgTypeInfo *msgtype_info) msgtype_info->msg_key_size = sizeof(wmMsgSubscribeKey_RNA); } -/* -------------------------------------------------------------------------- */ +/** \} */ + +/* -------------------------------------------------------------------- */ +/** \name RNA API + * \{ */ wmMsgSubscribeKey_RNA *WM_msg_lookup_rna(struct wmMsgBus *mbus, const wmMsgParams_RNA *msg_key_params) diff --git a/source/blender/windowmanager/message_bus/wm_message_bus.h b/source/blender/windowmanager/message_bus/wm_message_bus.h index 7ae356cf806..7ee2e5b6ee6 100644 --- a/source/blender/windowmanager/message_bus/wm_message_bus.h +++ b/source/blender/windowmanager/message_bus/wm_message_bus.h @@ -79,7 +79,7 @@ typedef struct wmMsg { } wmMsg; typedef struct wmMsgSubscribeKey { - /** Linked list for predicable ordering, otherwise we would depend on ghash bucketing. */ + /** Linked list for predicable ordering, otherwise we would depend on #GHash bucketing. */ struct wmMsgSubscribeKey *next, *prev; ListBase values; /* over-alloc, eg: wmMsgSubscribeKey_RNA */ @@ -124,6 +124,16 @@ void WM_msg_dump(struct wmMsgBus *mbus, const char *info); void WM_msgbus_handle(struct wmMsgBus *mbus, struct bContext *C); void WM_msg_publish_with_key(struct wmMsgBus *mbus, wmMsgSubscribeKey *msg_key); +/** + * \param msg_key_test: Needs following #wmMsgSubscribeKey fields filled in: + * - `msg.params` + * - `msg.head.type` + * - `msg.head.id` + * .. other values should be zeroed. + * + * \return The key for this subscription. + * note that this is only needed in rare cases when the key needs further manipulation. + */ wmMsgSubscribeKey *WM_msg_subscribe_with_key(struct wmMsgBus *mbus, const wmMsgSubscribeKey *msg_key_test, const wmMsgSubscribeValue *msg_val_params); |