Преглед на файлове

Merge pull request #20466 from linbingquan/dev-strings

Editor: Add zh for animations.
Mr.doob преди 4 години
родител
ревизия
b47af3a31d
променени са 2 файла, в които са добавени 16 реда и са изтрити 3 реда
  1. 4 3
      editor/js/Sidebar.Animation.js
  2. 12 0
      editor/js/Strings.js

+ 4 - 3
editor/js/Sidebar.Animation.js

@@ -2,6 +2,7 @@ import { UIPanel, UIDiv, UIBreak, UISelect, UIButton, UIText } from './libs/ui.j
 
 function SidebarAnimation( editor ) {
 
+	var strings = editor.strings;
 	var signals = editor.signals;
 	var mixer = editor.mixer;
 
@@ -65,7 +66,7 @@ function SidebarAnimation( editor ) {
 	var container = new UIPanel();
 	container.setDisplay( 'none' );
 
-	container.add( new UIText( 'Animations' ).setTextTransform( 'uppercase' ) );
+	container.add( new UIText( strings.getKey( 'sidebar/animations' ) ).setTextTransform( 'uppercase' ) );
 	container.add( new UIBreak() );
 	container.add( new UIBreak() );
 
@@ -74,8 +75,8 @@ function SidebarAnimation( editor ) {
 
 	var animationsSelect = new UISelect().setFontSize( '12px' );
 	div.add( animationsSelect );
-	div.add( new UIButton( 'Play' ).setMarginLeft( '4px' ).onClick( playAction ) );
-	div.add( new UIButton( 'Stop' ).setMarginLeft( '4px' ).onClick( stopAction ) );
+	div.add( new UIButton( strings.getKey( 'sidebar/animations/play' ) ).setMarginLeft( '4px' ).onClick( playAction ) );
+	div.add( new UIButton( strings.getKey( 'sidebar/animations/stop' ) ).setMarginLeft( '4px' ).onClick( stopAction ) );
 
 	return container;
 

+ 12 - 0
editor/js/Strings.js

@@ -74,6 +74,10 @@ function Strings( config ) {
 			'menubar/help/icons': 'Icon Pack',
 			'menubar/help/about': 'About',
 
+			'sidebar/animations': 'Animations',
+			'sidebar/animations/play': 'Play',
+			'sidebar/animations/stop': 'Stop',
+
 			'sidebar/scene': 'Scene',
 			'sidebar/scene/background': 'Background',
 			'sidebar/scene/environment': 'Environment',
@@ -393,6 +397,10 @@ function Strings( config ) {
 			'menubar/help/icons': 'Icon Pack',
 			'menubar/help/about': 'A propos',
 
+			'sidebar/animations': 'Animations',
+			'sidebar/animations/play': 'Play',
+			'sidebar/animations/stop': 'Stop',
+
 			'sidebar/scene': 'Scène',
 			'sidebar/scene/background': 'Arrière Plan',
 			'sidebar/scene/environment': 'Environment',
@@ -712,6 +720,10 @@ function Strings( config ) {
 			'menubar/help/icons': '图标组件包',
 			'menubar/help/about': '关于',
 
+			'sidebar/animations': '动画',
+			'sidebar/animations/play': '播放',
+			'sidebar/animations/stop': '暂停',
+
 			'sidebar/scene': '场景',
 			'sidebar/scene/background': '背景',
 			'sidebar/scene/environment': '环境',