소스 검색

[ts][player] Improved check if only one skin/animation should be allowed and display buttons accordingly.

badlogic 6 년 전
부모
커밋
ae6892cdfd
5개의 변경된 파일6개의 추가작업 그리고 6개의 파일을 삭제
  1. 2 2
      spine-ts/build/spine-all.js
  2. 0 0
      spine-ts/build/spine-all.js.map
  3. 2 2
      spine-ts/build/spine-player.js
  4. 0 0
      spine-ts/build/spine-player.js.map
  5. 2 2
      spine-ts/player/src/Player.ts

+ 2 - 2
spine-ts/build/spine-all.js

@@ -12100,9 +12100,9 @@ var spine;
 				};
 			}
 			this.setupInput();
-			if (skeletonData.skins.length == 1)
+			if (skeletonData.skins.length == 1 || (this.config.skins && this.config.skins.length == 1))
 				this.skinButton.classList.add("spine-player-hidden");
-			if (skeletonData.animations.length == 1)
+			if (skeletonData.animations.length == 1 || (this.config.animations && this.config.animations.length == 1))
 				this.animationButton.classList.add("spine-player-hidden");
 			this.config.success(this);
 			this.loaded = true;

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 0 - 0
spine-ts/build/spine-all.js.map


+ 2 - 2
spine-ts/build/spine-player.js

@@ -11433,9 +11433,9 @@ var spine;
 				};
 			}
 			this.setupInput();
-			if (skeletonData.skins.length == 1)
+			if (skeletonData.skins.length == 1 || (this.config.skins && this.config.skins.length == 1))
 				this.skinButton.classList.add("spine-player-hidden");
-			if (skeletonData.animations.length == 1)
+			if (skeletonData.animations.length == 1 || (this.config.animations && this.config.animations.length == 1))
 				this.animationButton.classList.add("spine-player-hidden");
 			this.config.success(this);
 			this.loaded = true;

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 0 - 0
spine-ts/build/spine-player.js.map


+ 2 - 2
spine-ts/player/src/Player.ts

@@ -969,8 +969,8 @@ module spine {
 			this.setupInput();
 
 			// Hide skin and animation if there's only the default skin / no animation
-			if (skeletonData.skins.length == 1) this.skinButton.classList.add("spine-player-hidden");
-			if (skeletonData.animations.length == 1) this.animationButton.classList.add("spine-player-hidden");
+			if (skeletonData.skins.length == 1 || (this.config.skins && this.config.skins.length == 1)) this.skinButton.classList.add("spine-player-hidden");
+			if (skeletonData.animations.length == 1 || (this.config.animations && this.config.animations.length == 1)) this.animationButton.classList.add("spine-player-hidden");
 
 			this.config.success(this);
 			this.loaded = true;

이 변경점에서 너무 많은 파일들이 변경되어 몇몇 파일들은 표시되지 않았습니다.