File tree Expand file tree Collapse file tree 1 file changed +0
-8
lines changed
src/vs/platform/audioCues/browser Expand file tree Collapse file tree 1 file changed +0
-8
lines changed Original file line number Diff line number Diff line change @@ -37,12 +37,6 @@ export class AudioCueService extends Disposable implements IAudioCueService {
37
37
@IAccessibilityService private readonly accessibilityService : IAccessibilityService
38
38
) {
39
39
super ( ) ;
40
- // preload all sounds so there's no delay
41
- for ( const audioCue of AudioCue . allAudioCues ) {
42
- playAudio ( FileAccess . asBrowserUri (
43
- `vs/platform/audioCues/browser/media/${ audioCue . sound . fileName } `
44
- ) . toString ( true ) , 0 ) . then ( sound => { { this . sounds . set ( sound . src , sound ) ; } } ) ;
45
- }
46
40
}
47
41
48
42
public async playAudioCue ( cue : AudioCue , allowManyInParallel = false ) : Promise < void > {
@@ -79,11 +73,9 @@ export class AudioCueService extends Disposable implements IAudioCueService {
79
73
try {
80
74
const sound = this . sounds . get ( url ) ;
81
75
if ( sound ) {
82
- // preloaded
83
76
sound . volume = this . getVolumeInPercent ( ) / 100 ;
84
77
await sound . play ( ) ;
85
78
} else {
86
- // not yet preloaded
87
79
const playedSound = await playAudio ( url , this . getVolumeInPercent ( ) / 100 ) ;
88
80
this . sounds . set ( url , playedSound ) ;
89
81
}
You can’t perform that action at this time.
0 commit comments