Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

audio event listeners in Captivate?

Participant ,
Mar 14, 2018 Mar 14, 2018

Hello!  Is there a way to attach event listeners to audio clips inside Captivate?  I need to trigger some events when audio ends, and prefer to do it without setting timeouts or waiting for a manually entered frame.

Thank you very much!

604
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Participant , Mar 15, 2018 Mar 15, 2018

this.onEndedCallBackFn function inside CPM.js does this - from there I was able to toggle all that I needed on audio end for every slide

Translate
Participant ,
Mar 15, 2018 Mar 15, 2018

this.onEndedCallBackFn function inside CPM.js does this - from there I was able to toggle all that I needed on audio end for every slide

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Nov 21, 2018 Nov 21, 2018
LATEST

I realize this question already has an accepted answer and that is a good solution, but I thought I'd throw in what I learned in case anyone doesn't care to mess with CPM.js files.

I used:

   aud = cp.movie.audioManager.currentSlideAudio;

   audHandle = cp.movie.audioManager.slideAudios[aud].nativeAudio;

   audHandle.onended = function(){

      //do stuff

   }

to an on slide enter action to add an event listener to the slide audio for that slide.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Help resources