Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/mesh/mesh_data.c
| Context not available. | |||||
| #include "BKE_library.h" | #include "BKE_library.h" | ||||
| #include "BKE_main.h" | #include "BKE_main.h" | ||||
| #include "BKE_mesh.h" | #include "BKE_mesh.h" | ||||
| #include "BKE_paint.h" | |||||
| #include "BKE_report.h" | #include "BKE_report.h" | ||||
| #include "BKE_editmesh.h" | #include "BKE_editmesh.h" | ||||
| Context not available. | |||||
| if (ED_mesh_uv_texture_add(me, NULL, true) == -1) | if (ED_mesh_uv_texture_add(me, NULL, true) == -1) | ||||
| return OPERATOR_CANCELLED; | return OPERATOR_CANCELLED; | ||||
| if (ob->mode & OB_MODE_TEXTURE_PAINT) { | |||||
| Scene *scene = CTX_data_scene(C); | |||||
| BKE_paint_proj_mesh_data_check(scene, ob, NULL, NULL, NULL, NULL); | |||||
| WM_event_add_notifier(C, NC_SCENE | ND_TOOLSETTINGS, NULL); | |||||
| } | |||||
| return OPERATOR_FINISHED; | return OPERATOR_FINISHED; | ||||
| } | } | ||||
| Context not available. | |||||
| if (!ED_mesh_uv_texture_remove_active(me)) | if (!ED_mesh_uv_texture_remove_active(me)) | ||||
| return OPERATOR_CANCELLED; | return OPERATOR_CANCELLED; | ||||
| if (ob->mode & OB_MODE_TEXTURE_PAINT) { | |||||
| Scene *scene = CTX_data_scene(C); | |||||
| BKE_paint_proj_mesh_data_check(scene, ob, NULL, NULL, NULL, NULL); | |||||
| WM_event_add_notifier(C, NC_SCENE | ND_TOOLSETTINGS, NULL); | |||||
| } | |||||
| return OPERATOR_FINISHED; | return OPERATOR_FINISHED; | ||||
| } | } | ||||
| Context not available. | |||||