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>2021-02-04 13:53:58 +0300
committerCampbell Barton <ideasman42@gmail.com>2021-02-04 14:21:10 +0300
commit3be5859b21950ed5f5949fce803cf8cbe68dcf99 (patch)
treed17c63c3db09b6e6c6e4574e3b24de51172172a2 /source/blender/editors/transform/transform_mode_shrink_fatten.c
parentdff51d418a6499a9e90adc97ab2bb599de36a860 (diff)
Cleanup: pass keymap items as const where possible
Diffstat (limited to 'source/blender/editors/transform/transform_mode_shrink_fatten.c')
-rw-r--r--source/blender/editors/transform/transform_mode_shrink_fatten.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/editors/transform/transform_mode_shrink_fatten.c b/source/blender/editors/transform/transform_mode_shrink_fatten.c
index 2a5c631df41..bccf4db66af 100644
--- a/source/blender/editors/transform/transform_mode_shrink_fatten.c
+++ b/source/blender/editors/transform/transform_mode_shrink_fatten.c
@@ -49,7 +49,7 @@
static eRedrawFlag shrinkfatten_handleEvent(struct TransInfo *t, const wmEvent *event)
{
BLI_assert(t->mode == TFM_SHRINKFATTEN);
- wmKeyMapItem *kmi = t->custom.mode.data;
+ const wmKeyMapItem *kmi = t->custom.mode.data;
if (kmi && event->type == kmi->type && event->val == kmi->val) {
/* Allows the 'Even Thickness' effect to be enabled as a toogle. */
t->flag ^= T_ALT_TRANSFORM;
@@ -90,7 +90,7 @@ static void applyShrinkFatten(TransInfo *t, const int UNUSED(mval[2]))
}
ofs += BLI_strncpy_rlen(str + ofs, ", (", sizeof(str) - ofs);
- wmKeyMapItem *kmi = t->custom.mode.data;
+ const wmKeyMapItem *kmi = t->custom.mode.data;
if (kmi) {
ofs += WM_keymap_item_to_string(kmi, false, str + ofs, sizeof(str) - ofs);
}
@@ -150,7 +150,7 @@ void initShrinkFatten(TransInfo *t)
if (t->keymap) {
/* Workaround to use the same key as the modal keymap. */
- t->custom.mode.data = WM_modalkeymap_find_propvalue(t->keymap, TFM_MODAL_RESIZE);
+ t->custom.mode.data = (void *)WM_modalkeymap_find_propvalue(t->keymap, TFM_MODAL_RESIZE);
}
}
}