Cleanup: Else after return
This commit is contained in:
parent
411261fb32
commit
3baaab15fc
|
@ -929,7 +929,7 @@ static int armature_parent_set_invoke(bContext *C,
|
|||
enable_connect = true;
|
||||
break;
|
||||
}
|
||||
else if (!(ebone->flag & BONE_CONNECTED)) {
|
||||
if (!(ebone->flag & BONE_CONNECTED)) {
|
||||
enable_connect = true;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -144,7 +144,7 @@ static void *t_view_get(TransInfo *t)
|
|||
View3D *v3d = t->area->spacedata.first;
|
||||
return (void *)v3d;
|
||||
}
|
||||
else if (t->region) {
|
||||
if (t->region) {
|
||||
return (void *)&t->region->v2d;
|
||||
}
|
||||
return NULL;
|
||||
|
@ -163,23 +163,21 @@ static int t_around_get(TransInfo *t)
|
|||
if (t->mode == TFM_BEND) {
|
||||
return V3D_AROUND_CURSOR;
|
||||
}
|
||||
else {
|
||||
return t->settings->transform_pivot_point;
|
||||
}
|
||||
return t->settings->transform_pivot_point;
|
||||
}
|
||||
else if (t->spacetype == SPACE_IMAGE) {
|
||||
if (t->spacetype == SPACE_IMAGE) {
|
||||
SpaceImage *sima = area->spacedata.first;
|
||||
return sima->around;
|
||||
}
|
||||
else if (t->spacetype == SPACE_GRAPH) {
|
||||
if (t->spacetype == SPACE_GRAPH) {
|
||||
SpaceGraph *sipo = area->spacedata.first;
|
||||
return sipo->around;
|
||||
}
|
||||
else if (t->spacetype == SPACE_CLIP) {
|
||||
if (t->spacetype == SPACE_CLIP) {
|
||||
SpaceClip *sclip = area->spacedata.first;
|
||||
return sclip->around;
|
||||
}
|
||||
else if (t->spacetype == SPACE_SEQ && t->region->regiontype == RGN_TYPE_PREVIEW) {
|
||||
if (t->spacetype == SPACE_SEQ && t->region->regiontype == RGN_TYPE_PREVIEW) {
|
||||
return SEQ_tool_settings_pivot_point_get(t->scene);
|
||||
}
|
||||
|
||||
|
|
|
@ -579,9 +579,7 @@ static int lineart_point_on_line_segment(double v[2], double v0[2], double v1[2]
|
|||
c2 = ratiod(v0[1], v1[1], v[1]);
|
||||
return (c2 >= -DBL_TRIANGLE_LIM && c2 <= 1 + DBL_TRIANGLE_LIM);
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!LRT_DOUBLE_CLOSE_ENOUGH(v1[1], v0[1])) {
|
||||
|
@ -592,9 +590,7 @@ static int lineart_point_on_line_segment(double v[2], double v0[2], double v1[2]
|
|||
c1 = ratiod(v0[0], v1[0], v[0]);
|
||||
return (c1 >= -DBL_TRIANGLE_LIM && c1 <= 1 + DBL_TRIANGLE_LIM);
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
if (LRT_DOUBLE_CLOSE_ENOUGH(c1, c2) && c1 >= 0 && c1 <= 1) {
|
||||
|
|
Loading…
Reference in New Issue