Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBastien Montagne <bastien@blender.org>2020-06-30 11:52:02 +0300
committerBastien Montagne <bastien@blender.org>2020-06-30 13:19:11 +0300
commit0b3313e53230914e79dd5c8f02b90fbaf6a8874b (patch)
treec9e439e67a8de2f01edbdeb2f73c4b3d057301a7 /source/blender/editors/interface/interface_ops.c
parent4783520bfad43b643f9e88dd2386c89c35c52f5f (diff)
Cleanup: LibOverride: Replace raw pointers checks by proper macros.
This is cleaner, but also crucial to avoid weird issues when behaviors of those checks are modified...
Diffstat (limited to 'source/blender/editors/interface/interface_ops.c')
-rw-r--r--source/blender/editors/interface/interface_ops.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/editors/interface/interface_ops.c b/source/blender/editors/interface/interface_ops.c
index d7f7f02c535..cb8f8be6361 100644
--- a/source/blender/editors/interface/interface_ops.c
+++ b/source/blender/editors/interface/interface_ops.c
@@ -613,7 +613,7 @@ static bool override_remove_button_poll(bContext *C)
UI_context_active_but_prop_get(C, &ptr, &prop, &index);
- const int override_status = RNA_property_override_library_status(&ptr, prop, index);
+ const uint override_status = RNA_property_override_library_status(&ptr, prop, index);
return (ptr.data && ptr.owner_id && prop && (override_status & RNA_OVERRIDE_STATUS_OVERRIDDEN));
}
@@ -634,7 +634,7 @@ static int override_remove_button_exec(bContext *C, wmOperator *op)
BLI_assert(oprop != NULL);
BLI_assert(id != NULL && id->override_library != NULL);
- const bool is_template = (id->override_library->reference == NULL);
+ const bool is_template = ID_IS_OVERRIDE_LIBRARY_TEMPLATE(id);
/* We need source (i.e. linked data) to restore values of deleted overrides...
* If this is an override template, we obviously do not need to restore anything. */