diff options
Diffstat (limited to 'source/blender/editors/physics/particle_edit.c')
-rw-r--r-- | source/blender/editors/physics/particle_edit.c | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/source/blender/editors/physics/particle_edit.c b/source/blender/editors/physics/particle_edit.c index f4f66c17459..8c3a5c46c04 100644 --- a/source/blender/editors/physics/particle_edit.c +++ b/source/blender/editors/physics/particle_edit.c @@ -1505,13 +1505,7 @@ static int select_linked_exec(bContext *C, wmOperator *op) static int select_linked_invoke(bContext *C, wmOperator *op, wmEvent *event) { - ARegion *ar= CTX_wm_region(C); - int location[2]; - - location[0]= event->x - ar->winrct.xmin; - location[1]= event->y - ar->winrct.ymin; - RNA_int_set_array(op->ptr, "location", location); - + RNA_int_set_array(op->ptr, "location", event->mval); return select_linked_exec(C, op); } @@ -3682,12 +3676,10 @@ static int brush_edit_exec(bContext *C, wmOperator *op) static void brush_edit_apply_event(bContext *C, wmOperator *op, wmEvent *event) { - ARegion *ar= CTX_wm_region(C); PointerRNA itemptr; float mouse[2]; - mouse[0]= event->x - ar->winrct.xmin; - mouse[1]= event->y - ar->winrct.ymin; + VECCOPY2D(mouse, event->mval); /* fill in stroke */ RNA_collection_add(op->ptr, "stroke", &itemptr); |