diff options
author | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2012-02-24 00:31:51 +0400 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2012-02-24 00:31:51 +0400 |
commit | d7155295bbcfd4606d2fead0d700820d8dc1ffeb (patch) | |
tree | fca59650e912b39addd40f63fccfd35ff4c29ca9 | |
parent | 0cf38faea42c69d58f16ad7fd47c60ecf9b92308 (diff) |
Fix #30326: calling e.g. bpy.ops.object.proxy_make(object = 'Lamp') would
not pick the right object. This operator had two properties "object" and
"type", but the latter was used while the former had the right description.
Now changed it to have only an "object" property, so that the above code works.
-rw-r--r-- | source/blender/editors/object/object_relations.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/source/blender/editors/object/object_relations.c b/source/blender/editors/object/object_relations.c index c1c85eb2a10..1e075fd4d43 100644 --- a/source/blender/editors/object/object_relations.c +++ b/source/blender/editors/object/object_relations.c @@ -321,7 +321,7 @@ static int make_proxy_exec (bContext *C, wmOperator *op) if (gob->dup_group != NULL) { - go= BLI_findlink(&gob->dup_group->gobject, RNA_enum_get(op->ptr, "type")); + go= BLI_findlink(&gob->dup_group->gobject, RNA_enum_get(op->ptr, "object")); ob= go->ob; } else @@ -411,8 +411,7 @@ void OBJECT_OT_proxy_make (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_string(ot->srna, "object", "", MAX_ID_NAME-2, "Proxy Object", "Name of lib-linked/grouped object to make a proxy for"); - prop= RNA_def_enum(ot->srna, "type", DummyRNA_DEFAULT_items, 0, "Type", "Group object"); /* XXX, relies on hard coded ID at the moment */ + prop= RNA_def_enum(ot->srna, "object", DummyRNA_DEFAULT_items, 0, "Proxy Object", "Name of lib-linked/grouped object to make a proxy for"); /* XXX, relies on hard coded ID at the moment */ RNA_def_enum_funcs(prop, proxy_group_object_itemf); ot->prop= prop; } |