diff options
author | Jacques Lucke <jacques@blender.org> | 2021-04-24 18:00:19 +0300 |
---|---|---|
committer | Jacques Lucke <jacques@blender.org> | 2021-04-24 18:00:37 +0300 |
commit | 9cce18a5858cb93da626f5f0fd7e09cd66637e05 (patch) | |
tree | f8f14810168405e984c263e05381e77afac869ef /source/blender/windowmanager | |
parent | 82328797cfcb5bbe543e4eeec4623504bfd9ff0c (diff) |
Info Editor: move to c++
I'm currently doing some experiments in the info editor and
for that it is easier if the info editor is in c++ already.
Diffstat (limited to 'source/blender/windowmanager')
-rw-r--r-- | source/blender/windowmanager/message_bus/wm_message_bus.h | 28 |
1 files changed, 8 insertions, 20 deletions
diff --git a/source/blender/windowmanager/message_bus/wm_message_bus.h b/source/blender/windowmanager/message_bus/wm_message_bus.h index 7ae356cf806..8c8caaf104b 100644 --- a/source/blender/windowmanager/message_bus/wm_message_bus.h +++ b/source/blender/windowmanager/message_bus/wm_message_bus.h @@ -260,16 +260,10 @@ void WM_msg_publish_ID(struct wmMsgBus *mbus, struct ID *id); /* Anonymous variants (for convenience) */ #define WM_msg_subscribe_rna_anon_type(mbus, type_, value) \ { \ - WM_msg_subscribe_rna_params(mbus, \ - &(const wmMsgParams_RNA){ \ - .ptr = \ - (PointerRNA){ \ - .type = &RNA_##type_, \ - }, \ - .prop = NULL, \ - }, \ - value, \ - __func__); \ + wmMsgParams_RNA msg_params = {0}; \ + msg_params.ptr.type = &RNA_##type_; \ + msg_params.prop = NULL; \ + WM_msg_subscribe_rna_params(mbus, &msg_params, value, __func__); \ } \ ((void)0) #define WM_msg_subscribe_rna_anon_prop(mbus, type_, prop_, value) \ @@ -277,16 +271,10 @@ void WM_msg_publish_ID(struct wmMsgBus *mbus, struct ID *id); _WM_MESSAGE_EXTERN_BEGIN; \ extern PropertyRNA rna_##type_##_##prop_; \ _WM_MESSAGE_EXTERN_END; \ - WM_msg_subscribe_rna_params(mbus, \ - &(const wmMsgParams_RNA){ \ - .ptr = \ - (PointerRNA){ \ - .type = &RNA_##type_, \ - }, \ - .prop = &rna_##type_##_##prop_, \ - }, \ - value, \ - __func__); \ + wmMsgParams_RNA msg_params = {0}; \ + msg_params.ptr.type = &RNA_##type_; \ + msg_params.prop = &rna_##type_##_##prop_; \ + WM_msg_subscribe_rna_params(mbus, &msg_params, value, __func__); \ } \ ((void)0) |