diff options
Diffstat (limited to 'source/blender/editors')
12 files changed, 26 insertions, 25 deletions
diff --git a/source/blender/editors/armature/armature_utils.c b/source/blender/editors/armature/armature_utils.c index 09174aa5e47..0465606e694 100644 --- a/source/blender/editors/armature/armature_utils.c +++ b/source/blender/editors/armature/armature_utils.c @@ -703,11 +703,11 @@ void ED_armature_from_edit(Main *bmain, bArmature *arm) newBone->inherit_scale_mode = eBone->inherit_scale_mode; if (eBone == arm->act_edbone) { - /* don't change active selection, this messes up separate which uses - * editmode toggle and can separate active bone which is de-selected originally */ + /* Don't change active selection, this messes up separate which uses + * edit-mode toggle and can separate active bone which is de-selected originally. */ - /* important, editbones can be active with only 1 point selected */ - /* newBone->flag |= BONE_SELECTED; */ + /* important, edit-bones can be active with only 1 point selected */ + /* `newBone->flag |= BONE_SELECTED;` */ arm->act_bone = newBone; } newBone->roll = 0.0f; diff --git a/source/blender/editors/armature/pose_transform.c b/source/blender/editors/armature/pose_transform.c index 9ed963f0c66..f92b72bbb66 100644 --- a/source/blender/editors/armature/pose_transform.c +++ b/source/blender/editors/armature/pose_transform.c @@ -361,7 +361,7 @@ static void applyarmature_reset_constraints(bPose *pose, const bool use_selected } } -/* set the current pose as the restpose */ +/* Set the current pose as the rest-pose. */ static int apply_armature_pose2bones_exec(bContext *C, wmOperator *op) { Main *bmain = CTX_data_main(C); @@ -404,10 +404,10 @@ static int apply_armature_pose2bones_exec(bContext *C, wmOperator *op) } } - /* Get editbones of active armature to alter */ + /* Get edit-bones of active armature to alter. */ ED_armature_to_edit(arm); - /* get pose of active object and move it out of posemode */ + /* Get pose of active object and move it out of pose-mode. */ pose = ob->pose; if (use_selected) { @@ -429,11 +429,11 @@ static int apply_armature_pose2bones_exec(bContext *C, wmOperator *op) } } - /* convert editbones back to bones, and then free the edit-data */ + /* Convert edit-bones back to bones, and then free the edit-data. */ ED_armature_from_edit(bmain, arm); ED_armature_edit_free(arm); - /* flush positions of posebones */ + /* Flush positions of pose-bones. */ BKE_pose_where_is(depsgraph, scene, ob); /* fix parenting of objects which are bone-parented */ diff --git a/source/blender/editors/interface/interface_handlers.c b/source/blender/editors/interface/interface_handlers.c index 7b6a623f53e..ac16d41dabe 100644 --- a/source/blender/editors/interface/interface_handlers.c +++ b/source/blender/editors/interface/interface_handlers.c @@ -3519,7 +3519,7 @@ static void ui_textedit_end(bContext *C, uiBut *but, uiHandleButtonData *data) static void ui_textedit_next_but(uiBlock *block, uiBut *actbut, uiHandleButtonData *data) { - /* label and roundbox can overlap real buttons (backdrops...) */ + /* Label and round-box can overlap real buttons (backdrops...). */ if (ELEM(actbut->type, UI_BTYPE_LABEL, UI_BTYPE_SEPR, @@ -3551,7 +3551,7 @@ static void ui_textedit_next_but(uiBlock *block, uiBut *actbut, uiHandleButtonDa static void ui_textedit_prev_but(uiBlock *block, uiBut *actbut, uiHandleButtonData *data) { - /* label and roundbox can overlap real buttons (backdrops...) */ + /* Label and round-box can overlap real buttons (backdrops...). */ if (ELEM(actbut->type, UI_BTYPE_LABEL, UI_BTYPE_SEPR, diff --git a/source/blender/editors/mesh/mesh_data.cc b/source/blender/editors/mesh/mesh_data.cc index 122b8fa7d89..b468360ff9b 100644 --- a/source/blender/editors/mesh/mesh_data.cc +++ b/source/blender/editors/mesh/mesh_data.cc @@ -787,7 +787,7 @@ static int mesh_customdata_custom_splitnormals_add_exec(bContext *C, wmOperator if (me->edit_mesh) { /* Tag edges as sharp according to smooth threshold if needed, - * to preserve autosmooth shading. */ + * to preserve auto-smooth shading. */ if (me->flag & ME_AUTOSMOOTH) { BM_edges_sharp_from_angle_set(me->edit_mesh->bm, me->smoothresh); } @@ -796,7 +796,7 @@ static int mesh_customdata_custom_splitnormals_add_exec(bContext *C, wmOperator } else { /* Tag edges as sharp according to smooth threshold if needed, - * to preserve autosmooth shading. */ + * to preserve auto-smooth shading. */ if (me->flag & ME_AUTOSMOOTH) { const Span<MVert> verts = me->verts(); MutableSpan<MEdge> edges = me->edges_for_write(); diff --git a/source/blender/editors/space_action/action_draw.c b/source/blender/editors/space_action/action_draw.c index eb56c6c4b54..343975919e2 100644 --- a/source/blender/editors/space_action/action_draw.c +++ b/source/blender/editors/space_action/action_draw.c @@ -104,7 +104,7 @@ void draw_channel_names(bContext *C, bAnimContext *ac, ARegion *region) UI_block_draw(C, block); } - /* free tempolary channels */ + /* Free temporary channels. */ ANIM_animdata_freelist(&anim_data); } diff --git a/source/blender/editors/space_buttons/buttons_ops.c b/source/blender/editors/space_buttons/buttons_ops.c index 4013288b13b..9c8d46a41f9 100644 --- a/source/blender/editors/space_buttons/buttons_ops.c +++ b/source/blender/editors/space_buttons/buttons_ops.c @@ -41,7 +41,7 @@ /* -------------------------------------------------------------------- */ /** \name Start / Clear Search Filter Operators * - * \note Almost a duplicate of the file browser operator #FILE_OT_start_filter. + * \note Almost a duplicate of the file browser operator #FILE_OT_start_filter. * \{ */ static int buttons_start_filter_exec(bContext *C, wmOperator *UNUSED(op)) diff --git a/source/blender/editors/space_graph/graph_draw.c b/source/blender/editors/space_graph/graph_draw.c index 41a8368152d..f8a0dff3a41 100644 --- a/source/blender/editors/space_graph/graph_draw.c +++ b/source/blender/editors/space_graph/graph_draw.c @@ -1446,7 +1446,7 @@ void graph_draw_channel_names(bContext *C, bAnimContext *ac, ARegion *region) GPU_blend(GPU_BLEND_NONE); } - /* free tempolary channels */ + /* Free temporary channels. */ ANIM_animdata_freelist(&anim_data); } diff --git a/source/blender/editors/space_nla/nla_draw.c b/source/blender/editors/space_nla/nla_draw.c index f57c9fead56..45bbe50eedd 100644 --- a/source/blender/editors/space_nla/nla_draw.c +++ b/source/blender/editors/space_nla/nla_draw.c @@ -905,7 +905,7 @@ void draw_nla_main_data(bAnimContext *ac, SpaceNla *snla, ARegion *region) } } - /* free tempolary channels */ + /* Free temporary channels. */ ANIM_animdata_freelist(&anim_data); } diff --git a/source/blender/editors/transform/transform.c b/source/blender/editors/transform/transform.c index 5b194ae7237..ad6ab625438 100644 --- a/source/blender/editors/transform/transform.c +++ b/source/blender/editors/transform/transform.c @@ -1725,7 +1725,7 @@ static void initSnapSpatial(TransInfo *t, float r_snap[3], float *r_snap_precisi { /* Default values. */ r_snap[0] = r_snap[1] = 1.0f; - r_snap[1] = 0.0f; + r_snap[2] = 0.0f; *r_snap_precision = 0.1f; if (t->spacetype == SPACE_VIEW3D) { diff --git a/source/blender/editors/transform/transform_convert_armature.c b/source/blender/editors/transform/transform_convert_armature.c index 4b79625fa66..6fd25d26c31 100644 --- a/source/blender/editors/transform/transform_convert_armature.c +++ b/source/blender/editors/transform/transform_convert_armature.c @@ -306,8 +306,9 @@ static short pose_grab_with_ik_add(bPoseChannel *pchan) * just make things obey standard rotation locks too */ if (data->rootbone == 0) { for (bPoseChannel *pchan_iter = pchan; pchan_iter; pchan_iter = pchan_iter->parent) { - /* here, we set ik-settings for bone from pchan->protectflag */ - /* XXX: careful with quats/axis-angle rotations where we're locking 4d components. */ + /* Here, we set IK-settings for bone from `pchan->protectflag`. */ + /* XXX: careful with quaternion/axis-angle rotations + * where we're locking 4d components. */ if (pchan_iter->protectflag & OB_LOCK_ROTX) { pchan_iter->ikflag |= BONE_IK_NO_XDOF_TEMP; } diff --git a/source/blender/editors/transform/transform_convert_nla.c b/source/blender/editors/transform/transform_convert_nla.c index af5a51cbff6..830094ebe83 100644 --- a/source/blender/editors/transform/transform_convert_nla.c +++ b/source/blender/editors/transform/transform_convert_nla.c @@ -60,9 +60,9 @@ typedef struct TransDataNla { * \{ */ /** - * \brief Applies a translation to the given NlaStrip. - * \param strip_rna_ptr The RNA pointer of the NLA strip to modify. - * \param transdata The transformation info structure. + * \brief Applies a translation to the given #NlaStrip. + * \param strip_rna_ptr: The RNA pointer of the NLA strip to modify. + * \param transdata: The transformation info structure. */ static void applyTransformNLA_translation(PointerRNA *strip_rna_ptr, const TransDataNla *transdata) { diff --git a/source/blender/editors/uvedit/uvedit_unwrap_ops.c b/source/blender/editors/uvedit/uvedit_unwrap_ops.c index ecaba3234a7..92efaf79de7 100644 --- a/source/blender/editors/uvedit/uvedit_unwrap_ops.c +++ b/source/blender/editors/uvedit/uvedit_unwrap_ops.c @@ -1774,8 +1774,8 @@ static void uv_map_clip_correct(const Scene *scene, dy = 1.0f / dy; } - if (dx == 1.0f && dy == 1.0f) { - /* Scaling by 1.0 has no effect. */ + if (dx == 1.0f && dy == 1.0f && min[0] == 0.0f && min[1] == 0.0f) { + /* Scaling by 1.0, without translating, has no effect. */ return; } |