Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/physics/dynamicpaint_ops.c
| Show First 20 Lines • Show All 242 Lines • ▼ Show 20 Lines | if (surface->type == MOD_DPAINT_SURFACE_T_PAINT) { | ||||
| ED_mesh_color_add(ob->data, name, true, true); | ED_mesh_color_add(ob->data, name, true, true); | ||||
| else | else | ||||
| ED_mesh_color_remove_named(ob->data, name); | ED_mesh_color_remove_named(ob->data, name); | ||||
| } | } | ||||
| /* Vertex Weight Layer */ | /* Vertex Weight Layer */ | ||||
| else if (surface->type == MOD_DPAINT_SURFACE_T_WEIGHT) { | else if (surface->type == MOD_DPAINT_SURFACE_T_WEIGHT) { | ||||
| if (!exists) { | if (!exists) { | ||||
| BKE_object_defgroup_add_name(ob, name); | BKE_object_defgroup_add_name(ob, name); | ||||
| DEG_relations_tag_update(CTX_data_main(C)); | |||||
| } | } | ||||
| else { | else { | ||||
| bDeformGroup *defgroup = defgroup_find_name(ob, name); | bDeformGroup *defgroup = defgroup_find_name(ob, name); | ||||
| if (defgroup) | if (defgroup) { | ||||
| BKE_object_defgroup_remove(ob, defgroup); | BKE_object_defgroup_remove(ob, defgroup); | ||||
| DEG_relations_tag_update(CTX_data_main(C)); | |||||
| } | |||||
| } | } | ||||
| } | } | ||||
| } | } | ||||
| return OPERATOR_FINISHED; | return OPERATOR_FINISHED; | ||||
| } | } | ||||
| void DPAINT_OT_output_toggle(wmOperatorType *ot) | void DPAINT_OT_output_toggle(wmOperatorType *ot) | ||||
| ▲ Show 20 Lines • Show All 265 Lines • Show Last 20 Lines | |||||