diff options
author | Campbell Barton <campbell@blender.org> | 2022-06-07 13:53:17 +0300 |
---|---|---|
committer | Campbell Barton <campbell@blender.org> | 2022-06-07 14:03:08 +0300 |
commit | 3a8a44b3f905850fe82b93b1316e9412f5bb7a8b (patch) | |
tree | 76e28582a1df0ee2671acd66d0ca1976ffc64596 /source | |
parent | 16934c198aab9413b0848c128af3b17a04219f25 (diff) |
Keymap: use both left/right modifier keys
Use both left/right modifier keys for:
- Fly Mode.
- Walk Mode.
- Area Split.
- Sculpt Detail Map.
- Sculpt Expand.
- Standard Modal Map
Resolves T98638.
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/editors/screen/screen_ops.c | 1 | ||||
-rw-r--r-- | source/blender/editors/sculpt_paint/sculpt_detail.c | 12 |
2 files changed, 8 insertions, 5 deletions
diff --git a/source/blender/editors/screen/screen_ops.c b/source/blender/editors/screen/screen_ops.c index 3022bbbd42c..80b0862bbab 100644 --- a/source/blender/editors/screen/screen_ops.c +++ b/source/blender/editors/screen/screen_ops.c @@ -2490,6 +2490,7 @@ static int area_split_modal(bContext *C, wmOperator *op, const wmEvent *event) return OPERATOR_CANCELLED; case EVT_LEFTCTRLKEY: + case EVT_RIGHTCTRLKEY: sd->do_snap = event->val == KM_PRESS; update_factor = true; break; diff --git a/source/blender/editors/sculpt_paint/sculpt_detail.c b/source/blender/editors/sculpt_paint/sculpt_detail.c index fe69cf6b84f..5275c6aac8a 100644 --- a/source/blender/editors/sculpt_paint/sculpt_detail.c +++ b/source/blender/editors/sculpt_paint/sculpt_detail.c @@ -657,11 +657,13 @@ static int dyntopo_detail_size_edit_modal(bContext *C, wmOperator *op, const wmE ED_region_tag_redraw(region); - if (event->type == EVT_LEFTCTRLKEY && event->val == KM_PRESS) { - cd->sample_mode = true; - } - if (event->type == EVT_LEFTCTRLKEY && event->val == KM_RELEASE) { - cd->sample_mode = false; + if (ELEM(event->type, EVT_LEFTCTRLKEY, EVT_RIGHTCTRLKEY)) { + if (event->val == KM_PRESS) { + cd->sample_mode = true; + } + else if (event->val == KM_RELEASE) { + cd->sample_mode = false; + } } /* Sample mode sets the detail size sampling the average edge length under the surface. */ |