Explorar o código

Merge branch '2023-8-14_指法预览'

liushengqiang %!s(int64=2) %!d(string=hai) anos
pai
achega
f31c3b8484
Modificáronse 1 ficheiros con 3 adicións e 0 borrados
  1. 3 0
      src/page-instrument/view-figner/index.tsx

+ 3 - 0
src/page-instrument/view-figner/index.tsx

@@ -77,6 +77,9 @@ export default defineComponent({
 			// console.log("🚀 ~ item:", item);
 			const noteAudio = data.soundFonts[item.realKey];
 			if (type === "start") {
+				if (data.realKey) {
+					data.soundFonts[data.realKey].stop();
+				}
 				data.realKey = item.realKey;
 				if (noteAudio) {
 					noteAudio.play();