diff options
author | Roland Hess <me@harkyman.com> | 2009-11-10 22:54:59 +0300 |
---|---|---|
committer | Roland Hess <me@harkyman.com> | 2009-11-10 22:54:59 +0300 |
commit | e29a70e136cbe80b11134d0e6f7a4a022c312e81 (patch) | |
tree | 54ebb0de8f311e6b2ad65ba3d555e13bbb126cee /source/blender/editors/mesh/mesh_data.c | |
parent | 320fb05ebca0cdf9ddaf592993c1d26b98ab5ff0 (diff) |
Add Sticky was essentially a blank operator. Possibly context functions weren't around for this one when it was first looked at. Re-attached so it works now.
Diffstat (limited to 'source/blender/editors/mesh/mesh_data.c')
-rw-r--r-- | source/blender/editors/mesh/mesh_data.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/source/blender/editors/mesh/mesh_data.c b/source/blender/editors/mesh/mesh_data.c index 94a7dbebb9c..f786a4a6c0b 100644 --- a/source/blender/editors/mesh/mesh_data.c +++ b/source/blender/editors/mesh/mesh_data.c @@ -38,6 +38,7 @@ #include "DNA_meshdata_types.h" #include "DNA_object_types.h" #include "DNA_scene_types.h" +#include "DNA_view3d_types.h" #include "DNA_windowmanager_types.h" #include "BKE_context.h" @@ -63,6 +64,8 @@ #include "ED_object.h" #include "ED_view3d.h" +#include "RE_render_ext.h" + #include "mesh_intern.h" static void delete_customdata_layer(bContext *C, Object *ob, CustomDataLayer *layer) @@ -389,13 +392,15 @@ void MESH_OT_vertex_color_remove(wmOperatorType *ot) static int sticky_add_exec(bContext *C, wmOperator *op) { + Scene *scene= CTX_data_scene(C); + View3D *v3d= CTX_wm_view3d(C); Object *ob= CTX_data_pointer_get_type(C, "object", &RNA_Object).data; Mesh *me= ob->data; - if(me->msticky) - return OPERATOR_CANCELLED; + /*if(me->msticky) + return OPERATOR_CANCELLED;*/ - // XXX RE_make_sticky(); + RE_make_sticky(scene, v3d); DAG_id_flush_update(&me->id, OB_RECALC_DATA); WM_event_add_notifier(C, NC_GEOM|ND_DATA, me); |