Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2020-01-20 18:52:20 +0300
committerCampbell Barton <ideasman42@gmail.com>2020-01-20 19:09:56 +0300
commit661d363e13ff3c86b30d09333e5334146e5da79f (patch)
tree9819fb8cf5224f0b8aa76a216217cbfb4f8089db /source/blender/editors/sculpt_paint/paint_ops.c
parenta5f19e3f7270b335d324c4fa5a9ca33e59376ef0 (diff)
Fix T73162: Modal tools cant be mapped to MMB
Also rename struct members to 'launch_event', since it's more descriptive and was called this in some places.
Diffstat (limited to 'source/blender/editors/sculpt_paint/paint_ops.c')
-rw-r--r--source/blender/editors/sculpt_paint/paint_ops.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/editors/sculpt_paint/paint_ops.c b/source/blender/editors/sculpt_paint/paint_ops.c
index 6252741799a..7863e18394c 100644
--- a/source/blender/editors/sculpt_paint/paint_ops.c
+++ b/source/blender/editors/sculpt_paint/paint_ops.c
@@ -562,7 +562,7 @@ typedef struct {
float *dim_target;
float *rot_target;
float *pos_target;
- short event_type;
+ short launch_event;
} StencilControlData;
static void stencil_set_target(StencilControlData *scd)
@@ -626,7 +626,7 @@ static int stencil_control_invoke(bContext *C, wmOperator *op, const wmEvent *ev
stencil_set_target(scd);
scd->mode = RNA_enum_get(op->ptr, "mode");
- scd->event_type = event->type;
+ scd->launch_event = WM_userdef_event_type_from_keymap_type(event->type);
scd->area_size[0] = ar->winx;
scd->area_size[1] = ar->winy;
@@ -709,7 +709,7 @@ static int stencil_control_modal(bContext *C, wmOperator *op, const wmEvent *eve
{
StencilControlData *scd = op->customdata;
- if (event->type == scd->event_type && event->val == KM_RELEASE) {
+ if (event->type == scd->launch_event && event->val == KM_RELEASE) {
MEM_freeN(op->customdata);
WM_event_add_notifier(C, NC_WINDOW, NULL);
return OPERATOR_FINISHED;