×

Discussion Board

Results 1 to 6 of 6
  1. #1
    Regular Contributor
    Join Date
    Jan 2008
    Posts
    272

    Thumbs up New problem with S40 : fastforward is not working

    Hi friends,

    I have written a small player. It has the controls like fastForward and fastBackward.

    the code looks like:
    public void skip(boolean backwards)
    {

    if (player != null)
    {
    try
    {
    long mTime = player.getMediaTime();
    long jump = 10000000;
    if (backwards)
    {
    setMediaTime(mTime-jump);

    }
    else
    {
    setMediaTime(mTime+jump);
    }
    }
    catch (IllegalStateException ise)
    {

    }
    }
    public void setMediaTime(long time)
    {
    if (player == null)
    {
    return;
    }
    try
    {
    player.stop();
    player.setMediaTime(time);
    player.start();
    }
    catch (Exception e)
    {
    }
    }


    I am getting null pointer exception in Nokia 6300 which is S40.
    But when I run the same code on E61i, its working fine.
    Is there any limitation on S40 for media controls?
    or
    Am I doing any wrong?
    Please help me.


    Thanks,
    Manoj.

  2. #2
    Nokia Developer Champion
    Join Date
    Nov 2007
    Location
    Rome, Italy
    Posts
    2,405

    Re: New problem with S40 : fastforward is not working

    Hi Manoj,

    where are you exactly having the NullPointerException? Are you sure it is thrown by the code portion you've posted?

    Pit

  3. #3
    Regular Contributor
    Join Date
    Jan 2008
    Posts
    272

    Re: New problem with S40 : fastforward is not working

    hi jappit,

    The same code which I posted here worked fine on Nokia E61i, but not on Nokia 6300.

    I am not understanding why I am getting the exception.

    can you please help me.

    Thanks,
    Manoj.

  4. #4
    Nokia Developer Champion
    Join Date
    Apr 2003
    Location
    USA, CA
    Posts
    7,192

    Re: New problem with S40 : fastforward is not working

    manojkumar.m

    please, check first the exact point when you get the null pointer exception as jappit above asks...

    Check also what is the mTime value you get from the player object and the return value of setMediaTime? Have you also implemented the setMediaTime in the same class where the skip method is as you call setMediaTime and not player.setMediaTime

    Hartti

  5. #5
    Registered User
    Join Date
    Oct 2008
    Posts
    1

    Re: New problem with S40 : fastforward is not working

    Hi,

    I'm creating a player in Java for S40 5th edition and have some problems with setmediaTime(). It does not work. Does some one have an example program for fastforward, rewind and setMediaTime() for S40?

    Mi

  6. #6
    Registered User
    Join Date
    Dec 2007
    Posts
    1

    Re: New problem with S40 : fastforward is not working

    Hi all,
    I'm having the same problem on a Nokia 6600 fold: the setMediaTime call is simply not working.
    The undeliying source is rtsp.
    I tried calling setMediaTime while playing or pausing then setMediaTime.

    Any update on that?
    Thanks

    -Hazam

Similar Threads

  1. Problem with streaming video on Nokia 6300 (S40 3rd FP2)
    By burinh in forum Streaming and Video
    Replies: 2
    Last Post: 2010-06-11, 10:25
  2. s40 theme studio 2.2 problem
    By pukkiedeb in forum Tools and SDK Feedback (Closed)
    Replies: 3
    Last Post: 2008-06-26, 06:05
  3. Problem with n93 - very slow working
    By bartisz in forum General Development Questions
    Replies: 1
    Last Post: 2008-02-26, 17:15
  4. s40 dp3 sync problem: Data transfer not possible
    By sim.sim in forum OMA DM/DS/CP
    Replies: 5
    Last Post: 2007-05-03, 01:11
  5. Problem with the opening of theme studio S40 v2.1
    By jim_nastiq in forum Series 40 & S60 Platform Feedback Archive
    Replies: 4
    Last Post: 2006-09-26, 02:39

Posting Permissions

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