×

Discussion Board

Results 1 to 4 of 4
  1. #1
    Registered User
    Join Date
    Jan 2009
    Posts
    4

    How to Close Video Canvas automatically after Playing Video file

    Can any one help me regarding Below issue in:

    1. I have One Home screen. Screen Contain Three Buttons.
    2. One video file is playing on every button action using Canvas, The Video Canvas called from Frame. and i displayed video from frame like

    Display.getDisplay( midlet).setCurrent(canvas);

    3. After playing video i have to go back to the my Home Screen automatically with out making use of "Stop" Command

  2. #2
    Registered User
    Join Date
    Mar 2008
    Posts
    17

    Re: How to Close Video Canvas automatically after Playing Video file

    I'm not sure if I understood you correctly. If you would like to show the video and return to your home screen instantly after it has played, you could register PlayerListener for your player and check from there when the player has stopped from playing.

    Something like this:
    Code:
    public void playerUpdate(Player player, String event, Object eventData) {
       if(event.equals(PlayerListener.END_OF_MEDIA)) {
          // Player has finished playing, release the player resources
          // and set current display to your main screen
       }
    }
    Last edited by Krapula; 2009-01-20 at 11:17. Reason: fixed some typing errors

  3. #3
    Registered User
    Join Date
    Jan 2009
    Posts
    4

    Re: How to Close Video Canvas automatically after Playing Video file

    Thank you for your quick reply.. i followed your instruction and its working... Thank you very much once again

  4. #4
    Registered User
    Join Date
    Mar 2008
    Posts
    17

    Re: How to Close Video Canvas automatically after Playing Video file

    No problem. Glad it worked.

Similar Threads

  1. Can app get first frame of a video file without playing it?
    By daveice in forum Symbian Media (Closed)
    Replies: 6
    Last Post: 2008-01-20, 07:35
  2. Replies: 1
    Last Post: 2006-11-30, 04:16
  3. Replies: 1
    Last Post: 2005-05-26, 14:22
  4. Replies: 0
    Last Post: 2002-06-10, 12:24

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×