Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBastien Montagne <montagne29@wanadoo.fr>2013-03-10 21:42:08 +0400
committerBastien Montagne <montagne29@wanadoo.fr>2013-03-10 21:42:08 +0400
commit6da449b86c5debb0be1f203090a3b75903a50a54 (patch)
tree7cb79a5c0ed467a286b26e62c0321f91292259bf
parent4760e002ddc3e93ecbf0861f535fe82d76dfa95b (diff)
More UI message i18n fixes and improvements...
Fix for keyingsets tips, and make them (and a few others) findable by i18n messages extracting code (for some reasons, their bl_rna.description are void???).
-rw-r--r--release/scripts/modules/bl_i18n_utils/bl_extract_messages.py2
-rw-r--r--release/scripts/startup/bl_ui/space_view3d_toolbar.py2
-rw-r--r--release/scripts/startup/keyingsets_builtins.py61
-rw-r--r--source/blender/editors/animation/keyframing.c2
4 files changed, 24 insertions, 43 deletions
diff --git a/release/scripts/modules/bl_i18n_utils/bl_extract_messages.py b/release/scripts/modules/bl_i18n_utils/bl_extract_messages.py
index bda2a15f44a..f29dfb6a789 100644
--- a/release/scripts/modules/bl_i18n_utils/bl_extract_messages.py
+++ b/release/scripts/modules/bl_i18n_utils/bl_extract_messages.py
@@ -356,6 +356,8 @@ def dump_messages_rna(msgs, reports, settings):
if bl_rna.description:
process_msg(msgs, default_context, bl_rna.description, msgsrc, reports, check_ctxt_rna_tip, settings)
+ elif cls.__doc__: # XXX Some classes (like KeyingSetInfo subclasses) have void description... :(
+ process_msg(msgs, default_context, cls.__doc__, msgsrc, reports, check_ctxt_rna_tip, settings)
if hasattr(bl_rna, 'bl_label') and bl_rna.bl_label:
process_msg(msgs, msgctxt, bl_rna.bl_label, msgsrc, reports, check_ctxt_rna, settings)
diff --git a/release/scripts/startup/bl_ui/space_view3d_toolbar.py b/release/scripts/startup/bl_ui/space_view3d_toolbar.py
index e5e2b3ad8a7..56ed53c4e12 100644
--- a/release/scripts/startup/bl_ui/space_view3d_toolbar.py
+++ b/release/scripts/startup/bl_ui/space_view3d_toolbar.py
@@ -1209,7 +1209,7 @@ class VIEW3D_MT_tools_projectpaint_stencil(Menu):
class VIEW3D_PT_tools_particlemode(View3DPanel, Panel):
- """default tools for particle mode"""
+ """Default tools for particle mode"""
bl_context = "particlemode"
bl_label = "Options"
diff --git a/release/scripts/startup/keyingsets_builtins.py b/release/scripts/startup/keyingsets_builtins.py
index 4f06f8a7be3..6d52a81456b 100644
--- a/release/scripts/startup/keyingsets_builtins.py
+++ b/release/scripts/startup/keyingsets_builtins.py
@@ -20,14 +20,11 @@
"""
Built-In Keying Sets
-None of these Keying Sets should be removed, as these
-are needed by various parts of Blender in order for them
+None of these Keying Sets should be removed, as these are needed by various parts of Blender in order for them
to work correctly.
-Beware also about changing the order that these are defined
-here, since this can result in old files referring to the
-wrong Keying Set as the active one, potentially resulting
-in lost (i.e. unkeyed) animation.
+Beware also about changing the order that these are defined here, since this can result in old files referring to the
+wrong Keying Set as the active one, potentially resulting in lost (i.e. unkeyed) animation.
"""
import bpy
@@ -138,9 +135,7 @@ class BUILTIN_KSI_LocScale(KeyingSetInfo):
# LocRotScale
class BUILTIN_KSI_LocRotScale(KeyingSetInfo):
- """
- Insert a keyframe on each of the location, rotation, and scale channels
- """
+ """Insert a keyframe on each of the location, rotation, and scale channels"""
bl_idname = ANIM_KS_LOC_ROT_SCALE_ID
bl_label = "LocRotScale"
@@ -183,10 +178,8 @@ class BUILTIN_KSI_RotScale(KeyingSetInfo):
# VisualLocation
class BUILTIN_KSI_VisualLoc(KeyingSetInfo):
- """
- Insert a keyframe on each of the location channels, taking into account
- effects of constraints and relationships
- """
+ """Insert a keyframe on each of the location channels, taking into account effects of constraints """
+ """and relationships"""
bl_label = "Visual Location"
bl_options = {'INSERTKEY_VISUAL'}
@@ -203,10 +196,8 @@ class BUILTIN_KSI_VisualLoc(KeyingSetInfo):
# VisualRotation
class BUILTIN_KSI_VisualRot(KeyingSetInfo):
- """
- Insert a keyframe on each of the rotation channels, taking into account
- effects of constraints and relationships
- """
+ """Insert a keyframe on each of the rotation channels, taking into account effects of constraints """
+ """and relationships"""
bl_label = "Visual Rotation"
bl_options = {'INSERTKEY_VISUAL'}
@@ -223,10 +214,8 @@ class BUILTIN_KSI_VisualRot(KeyingSetInfo):
# VisualScaling
class BUILTIN_KSI_VisualScaling(KeyingSetInfo):
- """
- Insert a keyframe on each of the scale channels, taking into account
- effects of constraints and relationships
- """
+ """Insert a keyframe on each of the scale channels, taking into account effects of constraints """
+ """and relationships"""
bl_label = "Visual Scaling"
bl_options = {'INSERTKEY_VISUAL'}
@@ -243,10 +232,8 @@ class BUILTIN_KSI_VisualScaling(KeyingSetInfo):
# VisualLocRot
class BUILTIN_KSI_VisualLocRot(KeyingSetInfo):
- """
- Insert a keyframe on each of the location and rotation channels,
- taking into account effects of constraints and relationships
- """
+ """Insert a keyframe on each of the location and rotation channels, taking into account effects of constraints """
+ """and relationships"""
bl_label = "Visual LocRot"
bl_options = {'INSERTKEY_VISUAL'}
@@ -267,10 +254,8 @@ class BUILTIN_KSI_VisualLocRot(KeyingSetInfo):
# VisualLocScale
class BUILTIN_KSI_VisualLocScale(KeyingSetInfo):
- """
- Insert a keyframe on each of the location and scaling channels,
- taking into account effects of constraints and relationships
- """
+ """Insert a keyframe on each of the location and scaling channels, taking into account effects of constraints """
+ """and relationships"""
bl_label = "Visual LocScale"
bl_options = {'INSERTKEY_VISUAL'}
@@ -291,10 +276,8 @@ class BUILTIN_KSI_VisualLocScale(KeyingSetInfo):
# VisualLocRotScale
class BUILTIN_KSI_VisualLocRotScale(KeyingSetInfo):
- """
- Insert a keyframe on each of the location, rotation and scaling channels,
- taking into account effects of constraints and relationships
- """
+ """Insert a keyframe on each of the location, rotation and scaling channels, taking into account effects """
+ """of constraints and relationships"""
bl_label = "Visual LocRotScale"
bl_options = {'INSERTKEY_VISUAL'}
@@ -317,10 +300,8 @@ class BUILTIN_KSI_VisualLocRotScale(KeyingSetInfo):
# VisualRotScale
class BUILTIN_KSI_VisualRotScale(KeyingSetInfo):
- """
- Insert a keyframe on each of the rotation and scaling channels,
- taking into account effects of constraints and relationships
- """
+ """Insert a keyframe on each of the rotation and scaling channels, taking into account effects of constraints """
+ """and relationships"""
bl_label = "Visual RotScale"
bl_options = {'INSERTKEY_VISUAL'}
@@ -367,10 +348,8 @@ class BUILTIN_KSI_Available(KeyingSetInfo):
# All properties that are likely to get animated in a character rig
class BUILTIN_KSI_WholeCharacter(KeyingSetInfo):
- """
- Insert a keyframe for all properties that are likely to get animated in a
- character rig (useful when blocking out a shot)
- """
+ """Insert a keyframe for all properties that are likely to get animated in a character rig """
+ """(useful when blocking out a shot)"""
bl_idname = ANIM_KS_WHOLE_CHARACTER_ID
bl_label = "Whole Character"
diff --git a/source/blender/editors/animation/keyframing.c b/source/blender/editors/animation/keyframing.c
index f68ff90105d..0867f7f76ff 100644
--- a/source/blender/editors/animation/keyframing.c
+++ b/source/blender/editors/animation/keyframing.c
@@ -1307,7 +1307,7 @@ static int insert_key_menu_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(e
uiLayout *layout;
/* call the menu, which will call this operator again, hence the canceled */
- pup = uiPupMenuBegin(C, op->type->name, ICON_NONE);
+ pup = uiPupMenuBegin(C, RNA_struct_ui_name(op->type->srna), ICON_NONE);
layout = uiPupMenuLayout(pup);
uiItemsEnumO(layout, "ANIM_OT_keyframe_insert_menu", "type");
uiPupMenuEnd(C, pup);