Gelmiş geçmiş en büyük porno sitemiz olan 2pe de her zaman en kaliteli pornoları sunmayı hedefledik. Diğer video sitemiz olan vuam da ise hd porno ağırlıklı çalışmalara başladık.

  1. #1
    Sencha User
    Join Date
    May 2011
    Posts
    94
    Vote Rating
    0
    hemant1 is on a distinguished road

      0  

    Default Unanswered: Problem in audio tag

    Unanswered: Problem in audio tag


    I have developed the my application in sencha touch 2.0


    In this application i m creating a quiz type application


    When user submit the Answer audio for right and wrong is going to play and on audio ended event display the next question


    When i run the application on browser or iPad simulator it works perfectly. But when i run the application on iPad after 4-5 questions application stucks i.e. when i submit the answer audio is played but before completion of audio audio automatically paused and application stucks. when i press back button the remainig audio is playing
    How to solve the problem
    Here is my code

    Code:
    playMusic:function(music_flag)
    {
              ans_audio=Ext.create('Ext.Audio',{id:'answeraudio'});
               ans_audio.setUrl("");
               que_audio.setUrl("");
               if(music_flag==true)
              {
                   var true_sound=this.getRandomNumber(2,1);
                   if(audio_number==true_sound)
                   {
                        while(audio_number==true_sound)
                        {
                              true_sound=this.getRandomNumber(2,1);
                         }
                    }
                    audio_number=true_sound;
                    ans_audio.setUrl('audio/true'+true_sound+'.mp3');
                    ans_audio.play(); 
               }
               else if(music_flag==false)
               {
                    var false_sound=this.getRandomNumber(3,1);
                    ans_audio.setUrl('audio/false'+false_sound+'.mp3');
                    ans_audio.play();
    
    
               }
    }
    Next Question function (i.e. audio end event)
    Code:
    nextQue: function()
    {
     ans_audio.destroy();
    /*code here for next question */
    }

  2. #2
    jay@moduscreate.com's Avatar
    Join Date
    Mar 2007
    Location
    Frederick MD, NYC, DC
    Posts
    16,353
    Answers
    102
    Vote Rating
    77
    jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all

      0  

    Default


    part of your problem is that you're recreating new audio components every time you want to play something. Why not just re-use the audio component/tag? iOS only supports one channel of audio anyway.

  3. #3
    Sencha User
    Join Date
    May 2011
    Posts
    94
    Vote Rating
    0
    hemant1 is on a distinguished road

      0  

    Default


    I done this in a both way

    1) by using same audio component and only changes the url

    2) by using new component every time

    but there is no diffrence

    application stucks after playing number of questions questions

Thread Participants: 1