Merge branch 'master' into blender2.8
authorCampbell Barton <ideasman42@gmail.com>
Sat, 20 Jan 2018 13:55:08 +0000 (00:55 +1100)
committerCampbell Barton <ideasman42@gmail.com>
Sat, 20 Jan 2018 13:55:08 +0000 (00:55 +1100)
1  2 
source/blender/editors/screen/screen_ops.c

index 3f52d232a39db43907d1b2438a63e0b6f3ab7ef6,e43f95f788b48407337f5ea413c85b19aa569cef..d0cdf77d3cc63dd3e6b9f9d158c9ef0911d2b86f
@@@ -1764,39 -1751,17 +1772,16 @@@ static int area_split_modal(bContext *C
                                }
                                /* area context not set */
                                sd->sarea = BKE_screen_find_area_xy(CTX_wm_screen(C), SPACE_TYPE_ANY, event->x, event->y);
-                               
                                if (sd->sarea) {
                                        ED_area_tag_redraw(sd->sarea);
-                                       if (dir == 'v') {
-                                               sd->origsize = sd->sarea->winx;
-                                               sd->origmin = sd->sarea->totrct.xmin;
-                                       }
-                                       else {
-                                               sd->origsize = sd->sarea->winy;
-                                               sd->origmin = sd->sarea->totrct.ymin;
-                                       }
-                                       if (sd->do_snap) {
-                                               ScrArea *sa = sd->sarea;
-                                               sa->v1->editflag = sa->v2->editflag = sa->v3->editflag = sa->v4->editflag = 1;
-                                               int snap_loc = area_snap_calc_location(
-                                                       CTX_wm_screen(C), sd->delta, sd->origval, dir, sd->origmin + sd->origsize, -sd->origmin);
-                                               sa->v1->editflag = sa->v2->editflag = sa->v3->editflag = sa->v4->editflag = 0;
-                                               fac = snap_loc - sd->origmin;
-                                       }
-                                       else {
-                                               fac = (dir == 'v') ? event->x - sd->origmin : event->y - sd->origmin;
-                                       }
-                                       RNA_float_set(op->ptr, "factor", fac / (float)sd->origsize);
+                                       update_factor = true;
                                }
  
 -                              CTX_wm_window(C)->screen->do_draw = true;
 -
 +                              CTX_wm_screen(C)->do_draw = true;
                        }
                        break;
-                       
+               }
                case LEFTMOUSE:
                        if (sd->previewmode) {
                                area_split_apply(C, op);