[Bf-blender-cvs] [17d66fe79ed] master: GPencil: 'Delete Duplicate Keyframes' in GPENCIL_MT_cleanup Menu

Kevin C. Burke noreply at git.blender.org
Sat Dec 31 16:25:37 CET 2022


Commit: 17d66fe79ed20abef12000b79de20013e749569c
Author: Kevin C. Burke
Date:   Sat Dec 31 16:24:44 2022 +0100
Branches: master
https://developer.blender.org/rB17d66fe79ed20abef12000b79de20013e749569c

GPencil: 'Delete Duplicate Keyframes' in GPENCIL_MT_cleanup Menu

The command text 'Delete Duplicated Frames' used in the `GPENCIL_MT_cleanup` menu is not correct grammar for what the command does. Keyframes removed by this command may be duplicate keys without having been duplicated. It also does not match the name of the command in `DOPESHEET_MT_context_menu`.
[[ https://developer.blender.org/diffusion/B/browse/master/release/scripts/startup/bl_ui/space_dopesheet.py$676 | space_dopesheet.py ]]

This patch fixes the grammar, gets the command's text to match the `DOPESHEET_MT_context_menu`, and corrects the description in the [[ https://docs.blender.org/api/current/bpy.ops.gpencil.html#bpy.ops.gpencil.frame_clean_duplicate | Python API documentation ]].

Reviewed By: antoniov

Differential Revision: https://developer.blender.org/D16887

===================================================================

M	release/scripts/startup/bl_ui/properties_grease_pencil_common.py
M	source/blender/editors/gpencil/gpencil_data.c

===================================================================

diff --git a/release/scripts/startup/bl_ui/properties_grease_pencil_common.py b/release/scripts/startup/bl_ui/properties_grease_pencil_common.py
index e70c75a53ca..e0f5d65db16 100644
--- a/release/scripts/startup/bl_ui/properties_grease_pencil_common.py
+++ b/release/scripts/startup/bl_ui/properties_grease_pencil_common.py
@@ -326,7 +326,7 @@ class GPENCIL_MT_cleanup(Menu):
 
         layout.separator()
 
-        layout.operator("gpencil.frame_clean_duplicate", text="Delete Duplicated Frames")
+        layout.operator("gpencil.frame_clean_duplicate", text="Delete Duplicate Frames")
         layout.operator("gpencil.recalc_geometry", text="Recalculate Geometry")
         if ob.mode != 'PAINT_GPENCIL':
             layout.operator("gpencil.reproject")
diff --git a/source/blender/editors/gpencil/gpencil_data.c b/source/blender/editors/gpencil/gpencil_data.c
index 5f21ca69baf..4f61016215a 100644
--- a/source/blender/editors/gpencil/gpencil_data.c
+++ b/source/blender/editors/gpencil/gpencil_data.c
@@ -881,7 +881,7 @@ void GPENCIL_OT_frame_clean_loose(wmOperatorType *ot)
               INT_MAX);
 }
 
-/* ********************* Clean Duplicated Frames ************************** */
+/* ********************* Clean Duplicate Frames ************************** */
 static bool gpencil_frame_is_equal(const bGPDframe *gpf_a, const bGPDframe *gpf_b)
 {
   if ((gpf_a == NULL) || (gpf_b == NULL)) {
@@ -1015,9 +1015,9 @@ void GPENCIL_OT_frame_clean_duplicate(wmOperatorType *ot)
   };
 
   /* identifiers */
-  ot->name = "Clean Duplicated Frames";
+  ot->name = "Clean Duplicate Frames";
   ot->idname = "GPENCIL_OT_frame_clean_duplicate";
-  ot->description = "Remove any duplicated frame";
+  ot->description = "Remove duplicate keyframes";
 
   /* callbacks */
   ot->exec = gpencil_frame_clean_duplicate_exec;



More information about the Bf-blender-cvs mailing list