Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/mesh/editmesh_loopcut.c
| Show First 20 Lines • Show All 734 Lines • ▼ Show 20 Lines | switch (event->type) { | ||||
| cuts = max_ff(cuts - 1, 1); | cuts = max_ff(cuts - 1, 1); | ||||
| } | } | ||||
| else { | else { | ||||
| smoothness -= 0.05f; | smoothness -= 0.05f; | ||||
| } | } | ||||
| handled = true; | handled = true; | ||||
| break; | break; | ||||
| case MOUSEMOVE: /* mouse moved somewhere to select another loop */ | case MOUSEMOVE: /* mouse moved somewhere to select another loop */ | ||||
| if (!has_numinput) { | |||||
| lcd->vc.mval[0] = event->mval[0]; | lcd->vc.mval[0] = event->mval[0]; | ||||
| lcd->vc.mval[1] = event->mval[1]; | lcd->vc.mval[1] = event->mval[1]; | ||||
| loopcut_mouse_move(lcd, (int)lcd->cuts); | loopcut_mouse_move(lcd, (int)lcd->cuts); | ||||
| ED_region_tag_redraw(lcd->ar); | ED_region_tag_redraw(lcd->ar); | ||||
| handled = true; | handled = true; | ||||
| } | |||||
| break; | break; | ||||
| } | } | ||||
| /* Modal numinput inactive, try to handle numeric inputs last... */ | /* Modal numinput inactive, try to handle numeric inputs last... */ | ||||
| if (!handled && event->val == KM_PRESS && handleNumInput(C, &lcd->num, event)) { | if (!handled && event->val == KM_PRESS && handleNumInput(C, &lcd->num, event)) { | ||||
| float values[2] = {cuts, smoothness}; | float values[2] = {cuts, smoothness}; | ||||
| applyNumInput(&lcd->num, values); | applyNumInput(&lcd->num, values); | ||||
| cuts = values[0]; | cuts = values[0]; | ||||
| smoothness = values[1]; | smoothness = values[1]; | ||||
| ▲ Show 20 Lines • Show All 104 Lines • Show Last 20 Lines | |||||