diff options
Diffstat (limited to 'source/blender/editors/util/numinput.c')
-rw-r--r-- | source/blender/editors/util/numinput.c | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/source/blender/editors/util/numinput.c b/source/blender/editors/util/numinput.c index 8bd5c9640a5..f64182d2ad6 100644 --- a/source/blender/editors/util/numinput.c +++ b/source/blender/editors/util/numinput.c @@ -276,17 +276,20 @@ bool handleNumInput(bContext *C, NumInput *n, const wmEvent *event) short dir = STRCUR_DIR_NEXT, mode = STRCUR_JUMP_NONE; int cur; -#ifndef USE_FAKE_EDIT - if ((event->ctrl == 0) && (event->alt == 0) && (event->ascii != '\0') && - strchr("01234567890@%^&*-+/{}()[]<>.|", event->ascii)) +#ifdef USE_FAKE_EDIT + if (U.flag & USER_FLAG_NUMINPUT_ADVANCED) +#endif { - if (!(n->flag & NUM_EDIT_FULL)) { - n->flag |= NUM_EDITED; - n->flag |= NUM_EDIT_FULL; - n->val_flag[idx] |= NUM_EDITED; + if ((event->ctrl == 0) && (event->alt == 0) && (event->ascii != '\0') && + strchr("01234567890@%^&*-+/{}()[]<>.|", event->ascii)) + { + if (!(n->flag & NUM_EDIT_FULL)) { + n->flag |= NUM_EDITED; + n->flag |= NUM_EDIT_FULL; + n->val_flag[idx] |= NUM_EDITED; + } } } -#endif switch (event->type) { case EVT_MODAL_MAP: |