Fix for inset when accessed from spacebar search
authorCampbell Barton <ideasman42@gmail.com>
Mon, 11 Dec 2017 14:38:33 +0000 (01:38 +1100)
committerCampbell Barton <ideasman42@gmail.com>
Mon, 11 Dec 2017 14:38:33 +0000 (01:38 +1100)
source/blender/editors/mesh/editmesh_inset.c

index afe52ec69f4be3726e293c76c89e343c84fa24e2..6fd4203e085770e082e2f938525ac5d205b64286 100644 (file)
@@ -373,10 +373,12 @@ static int edbm_inset_modal(bContext *C, wmOperator *op, const wmEvent *event)
                        case LEFTMOUSE:
                        case PADENTER:
                        case RETKEY:
                        case LEFTMOUSE:
                        case PADENTER:
                        case RETKEY:
-                               edbm_inset_calc(op);
-                               edbm_inset_exit(C, op);
-                               return OPERATOR_FINISHED;
-
+                               if (event->val == KM_PRESS) {
+                                       edbm_inset_calc(op);
+                                       edbm_inset_exit(C, op);
+                                       return OPERATOR_FINISHED;
+                               }
+                               break;
                        case LEFTSHIFTKEY:
                        case RIGHTSHIFTKEY:
                                if (event->val == KM_PRESS) {
                        case LEFTSHIFTKEY:
                        case RIGHTSHIFTKEY:
                                if (event->val == KM_PRESS) {