Blender
V3.3
|
#include <string.h>
#include "CLG_log.h"
#include "MEM_guardedalloc.h"
#include "BLI_listbase.h"
#include "BLI_utildefines.h"
#include "BLI_ghash.h"
#include "WM_types.h"
#include "message_bus/intern/wm_message_bus_intern.h"
#include "message_bus/wm_message_bus.h"
Go to the source code of this file.
Functions | |
Internal API | |
| |
void | wm_msg_subscribe_value_free (wmMsgSubscribeKey *msg_key, wmMsgSubscribeValueLink *msg_lnk) |
Public API | |
typedef void(* | wmMsgTypeInitFn) (wmMsgTypeInfo *) |
static wmMsgTypeInfo | wm_msg_types [WM_MSG_TYPE_NUM] = {{{NULL}}} |
static wmMsgTypeInitFn | wm_msg_init_fn [WM_MSG_TYPE_NUM] |
void | WM_msgbus_types_init (void) |
struct wmMsgBus * | WM_msgbus_create (void) |
void | WM_msgbus_destroy (struct wmMsgBus *mbus) |
void | WM_msgbus_clear_by_owner (struct wmMsgBus *mbus, void *owner) |
void | WM_msg_dump (struct wmMsgBus *mbus, const char *info_str) |
void | WM_msgbus_handle (struct wmMsgBus *mbus, struct bContext *C) |
wmMsgSubscribeKey * | WM_msg_subscribe_with_key (struct wmMsgBus *mbus, const wmMsgSubscribeKey *msg_key_test, const wmMsgSubscribeValue *msg_val_params) |
void | WM_msg_publish_with_key (struct wmMsgBus *mbus, wmMsgSubscribeKey *msg_key) |
void | WM_msg_id_update (struct wmMsgBus *mbus, struct ID *id_src, struct ID *id_dst) |
void | WM_msg_id_remove (struct wmMsgBus *mbus, const struct ID *id) |
typedef void(* wmMsgTypeInitFn) (wmMsgTypeInfo *) |
Definition at line 29 of file wm_message_bus.c.
Definition at line 97 of file wm_message_bus.c.
References LISTBASE_FOREACH, wmMsgBus::messages, wmMsgTypeInfo::repr, wmMsg::type, wm_msg_subscribe_value_msg_cast(), and wm_msg_types.
Referenced by bpy_msgbus_subscribe_rna(), and WM_msgbus_handle().
Definition at line 200 of file wm_message_bus.c.
References NULL, wmMsgTypeInfo::remove_by_id, WM_MSG_TYPE_NUM, and wm_msg_types.
Referenced by wm_main_remap_msgbus_notify(), and WM_main_remove_notifier_reference().
Definition at line 190 of file wm_message_bus.c.
References NULL, wmMsgTypeInfo::update_by_id, WM_MSG_TYPE_NUM, and wm_msg_types.
Referenced by wm_main_remap_msgbus_notify().
void WM_msg_publish_with_key | ( | struct wmMsgBus * | mbus, |
wmMsgSubscribeKey * | msg_key | ||
) |
Definition at line 169 of file wm_message_bus.c.
References BLI_listbase_count(), CLOG_INFO, LISTBASE_FOREACH, wmMsgBus::messages_tag_count, NULL, wmMsgSubscribeKey::values, and WM_LOG_MSGBUS_SUB.
Referenced by WM_msg_publish_rna_params(), and WM_msg_publish_static_params().
void wm_msg_subscribe_value_free | ( | struct wmMsgSubscribeKey * | msg_key, |
struct wmMsgSubscribeValueLink * | msg_lnk | ||
) |
Definition at line 218 of file wm_message_bus.c.
References BLI_remlink(), wmMsgSubscribeValue::free_data, MEM_freeN, wmMsgSubscribeValueLink::params, and wmMsgSubscribeKey::values.
Referenced by wm_msg_rna_gset_key_free(), wm_msg_rna_remove_by_id(), and wm_msg_rna_update_by_id().
wmMsgSubscribeKey* WM_msg_subscribe_with_key | ( | struct wmMsgBus * | mbus, |
const wmMsgSubscribeKey * | msg_key_test, | ||
const wmMsgSubscribeValue * | msg_val_params | ||
) |
msg_key_test | Needs following wmMsgSubscribeKey fields filled in:
|
Definition at line 136 of file wm_message_bus.c.
References BLI_addtail(), BLI_assert, BLI_gset_ensure_p_ex(), LISTBASE_FOREACH, MEM_mallocN, wmMsgBus::messages, wmMsgBus::messages_gset, wmMsgTypeInfo::msg_key_size, wmMsgSubscribeValue::notify, NULL, wmMsgSubscribeValue::owner, wmMsgSubscribeValueLink::params, type, wmMsg::type, wmMsgSubscribeValue::user_data, wmMsgSubscribeKey::values, wm_msg_subscribe_value_msg_cast(), and wm_msg_types.
Referenced by WM_msg_subscribe_rna_params(), and WM_msg_subscribe_static_params().
Definition at line 64 of file wm_message_bus.c.
References BLI_assert, BLI_gset_remove(), BLI_listbase_is_empty(), BLI_remlink(), ListBase::first, wmMsgTypeInfo::gset, wmMsgTypeInfo::key_free_fn, MEM_freeN, wmMsgBus::messages, wmMsgBus::messages_gset, wmMsgBus::messages_tag_count, wmMsgSubscribeKey::next, wmMsgSubscribeValueLink::next, wmMsg::type, UNUSED_VARS_NDEBUG, wmMsgSubscribeKey::values, wm_msg_subscribe_value_msg_cast(), and wm_msg_types.
Referenced by area_offscreen_exit(), ED_region_do_draw(), and ED_region_exit().
Definition at line 43 of file wm_message_bus.c.
References BLI_gset_new_ex(), wmMsgTypeInfo::cmp_fn, wmMsgTypeInfo::gset, wmMsgTypeInfo::hash_fn, MEM_callocN, wmMsgBus::messages_gset, WM_MSG_TYPE_NUM, and wm_msg_types.
Referenced by WM_check().
Definition at line 55 of file wm_message_bus.c.
References BLI_gset_free(), wmMsgTypeInfo::gset, wmMsgTypeInfo::key_free_fn, MEM_freeN, wmMsgBus::messages_gset, WM_MSG_TYPE_NUM, and wm_msg_types.
Referenced by wm_close_and_free(), and wm_window_match_init().
Definition at line 108 of file wm_message_bus.c.
References BLI_assert, C, LISTBASE_FOREACH, wmMsgBus::messages, wmMsgBus::messages_tag_count, and WM_msg_dump().
Referenced by wm_event_do_notifiers().
Definition at line 36 of file wm_message_bus.c.
References wm_msg_init_fn, WM_MSG_TYPE_NUM, and wm_msg_types.
Referenced by WM_init().
|
static |
Definition at line 31 of file wm_message_bus.c.
Referenced by WM_msgbus_types_init().
|
static |
Definition at line 27 of file wm_message_bus.c.
Referenced by WM_msg_dump(), WM_msg_id_remove(), WM_msg_id_update(), WM_msg_subscribe_with_key(), WM_msgbus_clear_by_owner(), WM_msgbus_create(), WM_msgbus_destroy(), and WM_msgbus_types_init().