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 18:51:41 +0300
committerBastien Montagne <bastien@blender.org>2020-06-30 18:52:36 +0300
commit6add0cc88a0d06e0a60f88b83c4894bd8701ecb5 (patch)
tree7b8a0c6fc98930c759f6cb3d1daaf7d44b6e1a47 /source/blender/editors/object/object_remesh.c
parent438bd823714a24475962ab89ad38b0d7e36349fe (diff)
LibOverride: Fix lots of poll functions for Object operators.
Prevent operators that should not perform on override data to be callable in those cases.
Diffstat (limited to 'source/blender/editors/object/object_remesh.c')
-rw-r--r--source/blender/editors/object/object_remesh.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/source/blender/editors/object/object_remesh.c b/source/blender/editors/object/object_remesh.c
index e28b5d953a5..664d4219686 100644
--- a/source/blender/editors/object/object_remesh.c
+++ b/source/blender/editors/object/object_remesh.c
@@ -100,7 +100,12 @@ static bool object_remesh_poll(bContext *C)
{
Object *ob = CTX_data_active_object(C);
- if (ob == NULL) {
+ if (ob == NULL || ob->data == NULL) {
+ return false;
+ }
+
+ if (ID_IS_LINKED(ob) || ID_IS_LINKED(ob->data) || ID_IS_OVERRIDE_LIBRARY(ob->data)) {
+ CTX_wm_operator_poll_msg_set(C, "The remesher cannot worked on linked or override data");
return false;
}