×

Discussion Board

Results 1 to 3 of 3
  1. #1
    Regular Contributor
    Join Date
    Feb 2007
    Posts
    52

    how can image be shown on click of a menu option

    hi experts
    as i already mention that i want to show the images while i click the menu option from my mobile can u plz guide me haw can i do that.
    thanks

  2. #2
    Registered User
    Join Date
    Feb 2007
    Location
    India
    Posts
    1,128

    Re: how can image be shown on click of a menu option

    Hi Gill,

    U just read about this class CFbsBitmap from the SDK Help.
    U Type below line in ur SDK help after u will get all things...

    Bitmap Animation Overview
    then after u will have any problem.. plz tell me.

    Good Day..

  3. #3
    Super Contributor
    Join Date
    Jun 2006
    Location
    India
    Posts
    3,037

    Re: how can image be shown on click of a menu option

    you need the to inherit your class MMdaImageUtilObserver and its a mixin class so you need to define the function of this class.

    i am sending the bit of code hope this will help you.


    void CMediaCenterAppUi::ShowImageL()
    {
    iBitmap = new (ELeave) CFbsBitmap();
    iConverter = CMdaImageFileToBitmapUtility::NewL(*this);
    //Start an asynchronous process to open the gif file
    iConverter->OpenL(_L("C:\\imageHere"));

    }

    void CMediaCenterAppUi::MiuoOpenComplete(TInt aError)
    {
    if (aError == KErrNone)
    {
    TFrameInfo frameInfo;
    //Get the frame info
    iConverter->FrameInfo(0,frameInfo);

    //Create a bitmap based on the size of the gif
    TInt err = iBitmap->Create(frameInfo.iOverallSizeInPixels,EColor4K);
    if (err != KErrNone)
    {
    delete iBitmap;
    delete iConverter;
    return;
    }
    //Convert the gif into a bitmap
    TRAPD(convertErr,iConverter->ConvertL(*iBitmap,0));

    //Trap error as this function cannot leave
    if (convertErr != KErrNone)
    {
    delete iBitmap;
    delete iConverter;
    return;
    }

    }
    else
    {
    delete iBitmap;
    delete iConverter;
    return;
    }
    }

    void CMediaCenterAppUi::MiuoConvertComplete(TInt aError)
    {
    if(aError==KErrNone)
    {
    //now bitmap is ready draw it
    delete iConverter;
    iImageDone=1;

    }
    else
    {
    delete iBitmap;
    delete iConverter;
    return;
    }
    }

    void CMediaCenterAppUi::MiuoCreateComplete(TInt /*aError*/)
    {

    }


    Regards,
    KKrish
    Use [URL="http://qt.nokia.com/products/qt-quick/"]Qt-Quick[/URL] to make your application UI more attractive.

    [URL="http://store.ovi.com/content/271896"]http://store.ovi.com/content/271896[/URL] | [URL="http://store.ovi.com/content/276199"]http://store.ovi.com/content/276199[/URL] |[URL="http://store.ovi.com/content/276202"] http://store.ovi.com/content/276202[/URL] | [URL="http://store.ovi.com/content/280827"]http://store.ovi.com/content/280827[/URL]

Similar Threads

  1. Replies: 2
    Last Post: 2007-11-10, 13:19
  2. HELP: Mutable Image to Immutable Image?
    By rj_cybersilver in forum Mobile Java Media (Graphics & Sounds)
    Replies: 1
    Last Post: 2005-03-26, 09:58
  3. Nokia Image Converter
    By davidpurdie in forum General Development Questions
    Replies: 0
    Last Post: 2004-02-18, 15:31
  4. Image Menu with canvas
    By efeba in forum Mobile Java Media (Graphics & Sounds)
    Replies: 2
    Last Post: 2003-06-26, 11:33
  5. RadioButton CheckBox on Option Menu (7650)
    By funko in forum Symbian Tools & SDKs
    Replies: 1
    Last Post: 2003-04-22, 12:45

Posting Permissions

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