×

Discussion Board

Results 1 to 5 of 5
  1. #1
    Regular Contributor
    Join Date
    Jul 2005
    Posts
    95

    Application loses focus while dialing a number programmatically using ETel API

    Hello,

    I am dialing a phone number programmatically from my application using the ETel API . However when the dialing starts my application loses focus and after I end the call my application automatically comes to the foreground again.
    Is there any way I can stop my application from losing focus while the number is neing dialed ?

    Thank You

  2. #2
    Registered User
    Join Date
    Apr 2005
    Location
    Barcelona
    Posts
    1,678

    Re: Application loses focus while dialing a number programmatically using ETel API

    You could use something like this for staying in foreground:

    iCoeEnv->RootWin().SetOrdinalPosition(0, ECoeWinPriorityAlwaysAtFront);

  3. #3
    Regular Contributor
    Join Date
    Jul 2005
    Posts
    95

    Re: Application loses focus while dialing a number programmatically using ETel API

    Hello PushL,

    Thanks for ur reply . I am relatively new to Symbian so could you please tell me where to put the line of code you suggested.
    The flow of code in my application is as follows :
    Event handler code in CMyAppAppUi::HandleCommandL() calls CMyAppEngine::MakeCall() which in turn calls the CMakePhoneCall::MakeCallL() function after initialising the telephony system.
    CMakePhoneCall is an active object class and CMyAppEngine is its observer.
    So do I put the line of code in the ConstructL() of my container class or within the RunL() of CMakePhoneCall before calling the dial function ?

    Thanks a lot

  4. #4
    Registered User
    Join Date
    Apr 2005
    Location
    Barcelona
    Posts
    1,678

    Re: Application loses focus while dialing a number programmatically using ETel API

    It will depend on the specific behaviour you want to achieve. The method posted will keep your window on front of the others (with less priority of course). You could call this before dialling, and turn it off by using ECoeWinPriorityNormal, after RunL() is called. Alternatively, you could do this when CEikAppUi::HandleForegroundEventL() (or HandleWsEventL()) is called (only if you're in the middle of the dialling procedure) and force it to stay in foreground (you should test this to see if you get any flickering)
    I'd go to the first option.. in any case, make sure the user will be able to put your app in background, otherwise, your app could "monopolize" the screen, and the user will think the phone is freezed..

  5. #5
    Regular Contributor
    Join Date
    Jul 2005
    Posts
    95

    Re: Application loses focus while dialing a number programmatically using ETel API

    Hi PushL,

    Thanks a lot , that worked

Similar Threads

  1. How to know the application version number ?
    By sdalis in forum Symbian C++
    Replies: 1
    Last Post: 2004-01-09, 03:01
  2. Replies: 0
    Last Post: 2003-12-30, 20:32
  3. Questions about Dialing from an application
    By rkuppala in forum Symbian C++
    Replies: 2
    Last Post: 2003-11-10, 17:10
  4. Nokia UI API : FullCanvas crashes application
    By frankborg2000 in forum Mobile Java Tools & SDKs
    Replies: 5
    Last Post: 2003-11-04, 09:59
  5. 7650 Java application crashes when calling sound API
    By gameskitchen in forum Mobile Java General
    Replies: 3
    Last Post: 2002-12-09, 21:31

Posting Permissions

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