diff options
author | Aaron Carlisle <carlisle.b3d@gmail.com> | 2021-12-25 07:59:33 +0300 |
---|---|---|
committer | Aaron Carlisle <carlisle.b3d@gmail.com> | 2021-12-25 07:59:33 +0300 |
commit | 67525b88d2e51db7ea5e6209b3589ce1c56f4959 (patch) | |
tree | 595211dd6c14c77cebb3b255c465e31896928393 /source/blender/editors/gpencil | |
parent | 95c7e8aa1384b28a91d65950898d36b0d5a69b59 (diff) |
Cleanup: Use array for BKE cursor functions
Differential Revision: https://developer.blender.org/D12962
Diffstat (limited to 'source/blender/editors/gpencil')
-rw-r--r-- | source/blender/editors/gpencil/annotate_paint.c | 3 | ||||
-rw-r--r-- | source/blender/editors/gpencil/gpencil_fill.c | 3 | ||||
-rw-r--r-- | source/blender/editors/gpencil/gpencil_paint.c | 3 |
3 files changed, 3 insertions, 6 deletions
diff --git a/source/blender/editors/gpencil/annotate_paint.c b/source/blender/editors/gpencil/annotate_paint.c index fbc44ed58d8..8d7fd295c8d 100644 --- a/source/blender/editors/gpencil/annotate_paint.c +++ b/source/blender/editors/gpencil/annotate_paint.c @@ -2575,8 +2575,7 @@ static int annotation_draw_modal(bContext *C, wmOperator *op, const wmEvent *eve */ if ((p->region) && (p->region->regiontype == RGN_TYPE_TOOLS)) { /* Change to whatever region is now under the mouse */ - ARegion *current_region = BKE_area_find_region_xy( - p->area, RGN_TYPE_ANY, event->xy[0], event->xy[1]); + ARegion *current_region = BKE_area_find_region_xy(p->area, RGN_TYPE_ANY, event->xy); if (current_region) { /* Assume that since we found the cursor in here, it is in bounds diff --git a/source/blender/editors/gpencil/gpencil_fill.c b/source/blender/editors/gpencil/gpencil_fill.c index c3af28d4382..f0adb901f88 100644 --- a/source/blender/editors/gpencil/gpencil_fill.c +++ b/source/blender/editors/gpencil/gpencil_fill.c @@ -2108,8 +2108,7 @@ static int gpencil_fill_modal(bContext *C, wmOperator *op, const wmEvent *event) /* first time the event is not enabled to show help lines. */ if ((tgpf->oldkey != -1) || (!help_lines)) { - ARegion *region = BKE_area_find_region_xy( - CTX_wm_area(C), RGN_TYPE_ANY, event->xy[0], event->xy[1]); + ARegion *region = BKE_area_find_region_xy(CTX_wm_area(C), RGN_TYPE_ANY, event->xy); if (region) { bool in_bounds = false; /* Perform bounds check */ diff --git a/source/blender/editors/gpencil/gpencil_paint.c b/source/blender/editors/gpencil/gpencil_paint.c index d1fbd3bc507..5b70da80a5e 100644 --- a/source/blender/editors/gpencil/gpencil_paint.c +++ b/source/blender/editors/gpencil/gpencil_paint.c @@ -3681,8 +3681,7 @@ static int gpencil_draw_modal(bContext *C, wmOperator *op, const wmEvent *event) */ if ((p->region) && (p->region->regiontype == RGN_TYPE_TOOLS)) { /* Change to whatever region is now under the mouse */ - ARegion *current_region = BKE_area_find_region_xy( - p->area, RGN_TYPE_ANY, event->xy[0], event->xy[1]); + ARegion *current_region = BKE_area_find_region_xy(p->area, RGN_TYPE_ANY, event->xy); if (current_region) { /* Assume that since we found the cursor in here, it is in bounds |