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:
authorPhilipp Oeser <info@graphics-engineer.com>2021-09-29 18:06:45 +0300
committerPhilipp Oeser <info@graphics-engineer.com>2021-09-29 22:39:56 +0300
commitcd03f5b6e572640f6e182c4989fe20ced156effa (patch)
tree2cf2a9c036939548873fc9465e04a290f394decf
parent0cddbcf1d7054c10c483061d9eaf92eedca3d976 (diff)
Add RNA path funcs for VolumeRender & VolumeDisplay
Without proper RNA paths, Alt-click editing properties on multiple selected objects doesn not work (as well as the 'Copy To Selected' operator). Fixes T91806. Maniphest Tasks: T91806 Differential Revision: https://developer.blender.org/D12700
-rw-r--r--source/blender/makesrna/intern/rna_volume.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/source/blender/makesrna/intern/rna_volume.c b/source/blender/makesrna/intern/rna_volume.c
index 8ed53c9f70f..f6b8b55688c 100644
--- a/source/blender/makesrna/intern/rna_volume.c
+++ b/source/blender/makesrna/intern/rna_volume.c
@@ -41,6 +41,16 @@
# include "WM_api.h"
# include "WM_types.h"
+static char *rna_VolumeRender_path(PointerRNA *UNUSED(ptr))
+{
+ return BLI_strdup("render");
+}
+
+static char *rna_VolumeDisplay_path(PointerRNA *UNUSED(ptr))
+{
+ return BLI_strdup("display");
+}
+
/* Updates */
static void rna_Volume_update_display(Main *UNUSED(bmain), Scene *UNUSED(scene), PointerRNA *ptr)
@@ -371,6 +381,7 @@ static void rna_def_volume_display(BlenderRNA *brna)
srna = RNA_def_struct(brna, "VolumeDisplay", NULL);
RNA_def_struct_ui_text(srna, "Volume Display", "Volume object display settings for 3D viewport");
RNA_def_struct_sdna(srna, "VolumeDisplay");
+ RNA_def_struct_path_func(srna, "rna_VolumeDisplay_path");
prop = RNA_def_property(srna, "density", PROP_FLOAT, PROP_NONE);
RNA_def_property_clear_flag(prop, PROP_ANIMATABLE);
@@ -477,6 +488,7 @@ static void rna_def_volume_render(BlenderRNA *brna)
srna = RNA_def_struct(brna, "VolumeRender", NULL);
RNA_def_struct_ui_text(srna, "Volume Render", "Volume object render settings");
RNA_def_struct_sdna(srna, "VolumeRender");
+ RNA_def_struct_path_func(srna, "rna_VolumeRender_path");
static const EnumPropertyItem space_items[] = {
{VOLUME_SPACE_OBJECT,