×

Discussion Board

Page 1 of 2 12 LastLast
Results 1 to 15 of 23
  1. #1
    Regular Contributor
    Join Date
    Feb 2008
    Posts
    269

    Image showing Info..

    Hi All,

    I am trying to display an image on the top of the screen in the handset which will show an information that i want. It is like, when a new message come it shows an image at the top.

    Is there an way to do this? Can i display more than one image at the top of the sccreen?

    Please help me..

    Any help will be appreciated.

    With Regards,
    Santu

  2. #2
    Super Contributor
    Join Date
    Jan 2008
    Location
    Bangalore, India
    Posts
    777

    Re: Image showing Info..

    Regards
    $-Nitesh-$

  3. #3
    Regular Contributor
    Join Date
    Feb 2008
    Posts
    269

    Smile Re: Image showing Info..

    Thanks Bhardwaj for your quick reply. I am trying this. Lets see what happen.

    With regards,
    Santu

  4. #4
    Regular Contributor
    Join Date
    Feb 2008
    Posts
    269

    Re: Image showing Info..

    Hi Bhardwaj,

    Its working. But i want if the sis file is installed in the handset the image should display everytime, not only for the applcation. Any idea?

    With regards,
    Santu

  5. #5
    Super Contributor
    Join Date
    Jan 2008
    Location
    Bangalore, India
    Posts
    777

    Re: Image showing Info..

    Quote Originally Posted by santu.paul@gmail.com View Post
    Hi Bhardwaj,

    Its working. But i want if the sis file is installed in the handset the image should display everytime, not only for the applcation. Any idea?

    With regards,
    Santu
    yaa u can do that just look on if condition in observer class
    just manage it according to ur need.
    Regards
    $-Nitesh-$

  6. #6
    Regular Contributor
    Join Date
    Feb 2008
    Posts
    269

    Re: Image showing Info..

    Hi Bhardwaj,

    Can you please explain it, i am not getting how to do it. And one more thing the icon is not coming transparent though i am using the mask file also.
    Got stucked it one place please help me.

    With regards,
    Santu

  7. #7
    Super Contributor
    Join Date
    Jan 2008
    Location
    Bangalore, India
    Posts
    777

    Re: Image showing Info..

    change this code in RunL
    case EEventFocusGroupChanged:
    iOnTopIcon->MakeVisible(ETrue);

    break;
    Last edited by Nitesh Bhardwaj; 2008-09-11 at 13:54. Reason: missing some word
    Regards
    $-Nitesh-$

  8. #8
    Regular Contributor
    Join Date
    Feb 2008
    Posts
    269

    Re: Image showing Info..

    Hi Bhardwaj,

    You mean to say, i have to create a tread. But i want the image should display even when the application is not runing. I want my application should work like a theme.

    Is it possible?

    With Regards,
    Santu

  9. #9
    Super Contributor
    Join Date
    Jan 2008
    Location
    Bangalore, India
    Posts
    777

    Re: Image showing Info..

    I want my application should work like a theme.
    i think this is a different thing,in theme u have to manage other things.
    But i want the image should display even when the application is not runing..
    for this u can make a background exe that will be rsponsible for
    doing this task.
    Regards
    $-Nitesh-$

  10. #10
    Regular Contributor
    Join Date
    Feb 2008
    Posts
    269

    Question Re: Image showing Info..

    Hi,
    I have created an indicator image. Its working fine in the emulator. But the sis file is not working. Its crashes as i try to load. I am using S60 2nd Edition FP3 and i am testing it in Nokia N70. Can anyone give me any idea what may be the reason. Mainly i am using RWindowGroup for drawing the image. Is it is not possible for handset? Please clear me out of this.

    With regards,
    Santu

  11. #11
    Registered User
    Join Date
    Dec 2006
    Posts
    2,280

    Re: Image showing Info..

    There are hundreds of reasons why an application that works in the emulator won't work in the real phone. You need to find out specifically why yours is crashing. Look for posts and wiki articles about debugging on the device or tracing.

    Sorcery

  12. #12
    Regular Contributor
    Join Date
    Feb 2008
    Posts
    269

    Re: Image showing Info..

    Hi Sorcery,

    Ya i know there may be a lots of reason for crashing a sis file in the handset. Thats why i point out that i have use RWindowGroup. Anyway can you please tell me how to debug sis file in a device.

    With regards,
    Santu

  13. #13
    Registered User
    Join Date
    Dec 2006
    Posts
    2,280

    Re: Image showing Info..

    Unfortunately on 2nd Edition phones you can't use On-Device Debugging so you'll have to put logging in to your application.

    You can either log to a file on the device and copy it off after you've attempted to start your application, or you can use a serial port and trace out with RDebug::Print() statements in the code. You will also want to enable extended panic info (search for that in the wiki) to see if there is any error.

    If it crashes silently on startup then it may be the case that you've got mis-matched UIDs (i.e. not the same UID in all file related to the application) - that's happened to me in the past.

    Sorcery

  14. #14
    Regular Contributor
    Join Date
    Feb 2008
    Posts
    269

    Re: Image showing Info..

    Thanks Sorcery...

    With regards,
    Santu

  15. #15
    Regular Contributor
    Join Date
    Feb 2008
    Posts
    269

    Unhappy Re: Image showing Info..

    Hi Sorcery,

    I tried a lot to find out why the sis file is not working, but all in vain.

    Code:
    CBackgroundIcon* CBackgroundIcon::NewL()
    {
    CBackgroundIcon* self = CBackgroundIcon::NewLC();
    CleanupStack::Pop(self);
    return self;
    }

    CBackgroundIcon* CBackgroundIcon::NewLC()
    {
    CBackgroundIcon* self = new (ELeave) CBackgroundIcon();
    CleanupStack::PushL(self);
    self->ConstructL();
    return self;
    }

    CBackgroundIcon::CBackgroundIcon()
    {
    }

    void CBackgroundIcon::ConstructL()
    {

    if (iIndicator)
    {
    delete iIndicator;
    iIndicator = NULL;
    } // if (iIndicator)

    if (iIndicatorMask)
    {
    delete iIndicatorMask;
    iIndicatorMask = NULL;
    } // if (iIndicatorMask)


    iMyWindowGroup = RWindowGroup(iCoeEnv->WsSession());
    User::LeaveIfError(iMyWindowGroup.Construct((TUint32)&iMyWindowGroup));

    iMyWindowGroup.SetOrdinalPosition(0, ECoeWinPriorityAlwaysAtFront);
    iMyWindowGroup.EnableReceiptOfFocus(EFalse);

    CreateWindowL(&iMyWindowGroup);

    // by default setting the indicator icon to inactive
    //SetIndicatorIconL(EIndicatorIconAppActive);

    ActivateL();
    }

    CBackgroundIcon::~CBackgroundIcon()
    {
    if (iIndicator)
    {
    delete iIndicator;
    iIndicator = NULL;
    } // if (iIndicator)

    if (iIndicatorMask)
    {
    delete iIndicatorMask;
    iIndicatorMask = NULL;
    } // if (iIndicatorMask)

    iMyWindowGroup.Close();
    }

    void CBackgroundIcon::SetIndicatorIconL(/*TInt aIndicatorIconType,*/ TBool aRedraw)
    {
    iIndicator = CEikonEnv::Static()->CreateBitmapL(KIconFile, EMbmIcon7);
    iIndicatorMask = CEikonEnv::Static()->CreateBitmapL(KIconFile, EMbmIcon7);


    SetRect(TRect(TPoint(KBackgroundPosX, KBackgroundPosY),TSize(330,290)));

    // if aRedraw == ETrue just draw the canvas again.
    if(aRedraw)
    {
    DrawNow();
    }
    }

    void CBackgroundIcon:raw(const TRect& aRect) const
    {
    CWindowGc& gc = SystemGc();

    gc.Clear();
    gc.SetBrushStyle(CGraphicsContext::ENullBrush);
    gc.BitBltMasked(TPoint(aRect.iTl.iX, aRect.iTl.iY),
    iIndicator,
    TRect(TPoint(0, 0), iIndicator->SizeInPixels()),
    iIndicatorMask,
    ETrue);
    //iRWindow->SetTransparencyBitmap(*iIndicator);
    }

    And i call the function SetIndicatorIconL from my container.
    So, please help me to find out why the sis file is not running in the device. But it is running in the emulator.

    Its very urgent.

    With regards,
    Santu

Similar Threads

  1. Replies: 1
    Last Post: 2008-07-11, 02:32
  2. Image attribute in Bluetooth ServiceRecord
    By lampz in forum Mobile Java Networking & Messaging & Security
    Replies: 7
    Last Post: 2008-02-18, 20:30
  3. how to cut some part of Image
    By mshouab in forum Mobile Java Media (Graphics & Sounds)
    Replies: 2
    Last Post: 2006-08-04, 09:05
  4. S60 showing image at startup
    By mrcap in forum Mobile Java Media (Graphics & Sounds)
    Replies: 2
    Last Post: 2003-10-01, 07:26
  5. Replies: 0
    Last Post: 2003-05-12, 17:38

Posting Permissions

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