<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xml:base="http://www.newlc.com" xmlns:dc="http://purl.org/dc/elements/1.1/">
<channel>
 <title>NewLC - Problem in CTelephony AnswerIncomingCall in Symbian 9.1 - Comments</title>
 <link>http://www.newlc.com/en/topic-17582</link>
 <description>Comments for &quot;Problem in CTelephony AnswerIncomingCall in Symbian 9.1&quot;</description>
 <language>en</language>
<item>
 <title>Re: Problem in CTelephony AnswerIncomingCall in Symbian 9.1</title>
 <link>http://www.newlc.com/en/topic-17582#comment-37371</link>
 <description>&lt;div class=&quot;smf-content&quot;&gt;Hello zahangir,&lt;br /&gt;&lt;br /&gt;If your code design is ok, there should not be any problem. It will be more convenient if you post some of your code sniffet here. &lt;br /&gt;&lt;br /&gt;By the way, how many views are there in your code? and the important thing is that the SetOrdinalPosition will be used in anywhere&amp;nbsp; successfully if used in proper way.&lt;br /&gt;&lt;br /&gt;If possible post the ur view::ConstructL(), DoActivateL() and container::ConstructL() and phone::RunL() part to better recognise the problem.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Regards,&lt;br /&gt;Tushar&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;</description>
 <pubDate>Tue, 20 Mar 2007 15:53:42 +0100</pubDate>
 <dc:creator>tusharbhatta</dc:creator>
 <guid isPermaLink="false">comment 37371 at http://www.newlc.com</guid>
</item>
<item>
 <title>Re: Problem in CTelephony AnswerIncomingCall in Symbian 9.1</title>
 <link>http://www.newlc.com/en/topic-17582#comment-37370</link>
 <description>&lt;div class=&quot;smf-content&quot;&gt;Hi Tushar,&lt;br /&gt;&lt;br /&gt;I have done it but still some times it works fine but some times it does not work, it goes to background Telephone app comes foregorund. I am working in Symbain 9.1 and using CTelephony API. What I have done that are as follows&lt;br /&gt;&lt;br /&gt;1.&amp;nbsp; My Incoming call notifier is an CActive Object. And set it EPriorityHigh&lt;br /&gt;2. SetProcessPriority as high from ConstructL of AppUi &lt;br /&gt;3. SetThreadPriority as high from ConstructL of AppUi &lt;br /&gt;4. Bring to foreground using SetOrdinalPosition on Incoming call&lt;br /&gt;&lt;br /&gt;Is there any trick is missing.....&lt;br /&gt;&lt;br /&gt;If any idea the please share it.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;</description>
 <pubDate>Tue, 20 Mar 2007 12:26:24 +0100</pubDate>
 <dc:creator>zahangir</dc:creator>
 <guid isPermaLink="false">comment 37370 at http://www.newlc.com</guid>
</item>
<item>
 <title>Re: Problem in CTelephony AnswerIncomingCall in Symbian 9.1</title>
 <link>http://www.newlc.com/en/topic-17582#comment-37369</link>
 <description>&lt;div class=&quot;smf-content&quot;&gt;Hello Zahangir,&lt;br /&gt;&lt;br /&gt;try this code in side your BringForeGroundL() instead of TApaTask.&lt;br /&gt;&lt;br /&gt;&lt;div class=&quot;codeheader&quot;&gt;Code:&lt;/div&gt;&lt;div class=&quot;code&quot;&gt;&lt;br /&gt;RWindowGroup iMyWindowGroup2 = iCoeEnv-&amp;gt;RootWin();&lt;br /&gt;iMyWindowGroup2.SetOrdinalPosition(0,ECoeWinPriorityAlwaysAtFront);&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;and let me know whether it worked.&lt;br /&gt;&lt;br /&gt;Regards,&lt;br /&gt;Tushar&lt;/div&gt;</description>
 <pubDate>Tue, 13 Mar 2007 07:23:37 +0100</pubDate>
 <dc:creator>tusharbhatta</dc:creator>
 <guid isPermaLink="false">comment 37369 at http://www.newlc.com</guid>
</item>
<item>
 <title>Re: Problem in CTelephony AnswerIncomingCall in Symbian 9.1</title>
 <link>http://www.newlc.com/en/topic-17582#comment-37368</link>
 <description>&lt;div class=&quot;smf-content&quot;&gt;Hi Tushar,&lt;br /&gt;&lt;br /&gt;According to some solutions about it, I have understood that three main things are important those are.&lt;br /&gt;1. CActive with &amp;#039;EPriorityHigh&amp;#039; for incoming call listener&lt;br /&gt;2. Application&amp;#039;s thread with &amp;#039;EPriorityAbsoluteHigh&amp;#039;&lt;br /&gt;3. BringForeGround using TApaTask&lt;br /&gt;&lt;br /&gt;I have tried this within the following code. But Still native caller screen seen. MyTest1 application comes foregroundand then goes background and then native caller screen comes foreground.&lt;br /&gt;&lt;br /&gt;I am sure that definitely some mistakes are here. Please clear it.&lt;br /&gt;&lt;br /&gt;My development Points are:&lt;br /&gt;0. SDK: S60 3rd edition and CTelephony API&lt;br /&gt;1. My application name is : MyTest1&lt;br /&gt;2. I have created a call manager for income call listenter with CActive( EPriorityHigh ). CallManager class is like this:&lt;br /&gt;----------------------------------------------------------------&lt;br /&gt;class CCallManager : public CActive&lt;br /&gt;{&lt;br /&gt;public:&lt;br /&gt;&amp;nbsp; &amp;nbsp; static CCallManager* NewL(CTelephony* aTelephony, CInCallListener &amp;amp; aInCallListener);&lt;br /&gt;&amp;nbsp; &amp;nbsp; void Start();&lt;br /&gt;&amp;nbsp; &amp;nbsp; void Stop();&lt;br /&gt;public:&lt;br /&gt;&amp;nbsp; &amp;nbsp; virtual ~CCallManager();&lt;br /&gt;private:&lt;br /&gt;&amp;nbsp; &amp;nbsp; CCallManager(CTelephony* aTelephony, CInCallListener &amp;amp; aInCallListener);&lt;br /&gt;&amp;nbsp; &amp;nbsp; void ConstructL();&lt;br /&gt;private:&lt;br /&gt;&amp;nbsp; &amp;nbsp; void RequestNotification();&lt;br /&gt;protected:&lt;br /&gt;&amp;nbsp; &amp;nbsp; virtual void RunL(); // Inherited from CActive&lt;br /&gt;&amp;nbsp; &amp;nbsp; virtual void DoCancel();&lt;br /&gt;private:&lt;br /&gt;&amp;nbsp; &amp;nbsp; CTelephony* iTelephony;&lt;br /&gt;&amp;nbsp; &amp;nbsp; CInCallListener &amp;amp; iInCallListener;&lt;br /&gt;&amp;nbsp; &amp;nbsp; CTelephony::TCallStatusV1 iLineStatus;&lt;br /&gt;&amp;nbsp; &amp;nbsp;CTelephony::TCallStatusV1Pckg iLineStatusPckg;&lt;br /&gt;};&lt;br /&gt;&lt;br /&gt;//Start of CallManager.cpp file&lt;br /&gt;CCallManager* CCallManager::NewL(CTelephony* aTelephony, CInCallListener &amp;amp; aInCallListener)&lt;br /&gt;{&lt;br /&gt;&amp;nbsp; CCallManager * self = new (ELeave) CCallManager(aTelephony, aInCallListener);&lt;br /&gt;&amp;nbsp; CleanupStack::PushL(self);&lt;br /&gt;&amp;nbsp; self-&amp;gt;ConstructL();&lt;br /&gt;&amp;nbsp; CleanupStack::Pop(self);&lt;br /&gt;&amp;nbsp; return self;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;void CCallManager::Start()&lt;br /&gt;{&lt;br /&gt;&amp;nbsp; Cancel();&lt;br /&gt;&amp;nbsp; RequestNotification();&lt;br /&gt;}&lt;br /&gt;void CCallManager::Stop()&lt;br /&gt;{&lt;br /&gt;&amp;nbsp; Cancel();&lt;br /&gt;}&lt;br /&gt;CCallManager::CCallManager(CTelephony* aTelephony, CInCallListener &amp;amp; aInCallListener)&lt;br /&gt;: CActive( EPriorityHigh ),&lt;br /&gt;iTelephony(aTelephony),&lt;br /&gt;iInCallListener(aInCallListener),&lt;br /&gt;iLineStatusPckg( iLineStatus )&lt;br /&gt;{&lt;br /&gt;&amp;nbsp; iLineStatus.iStatus = CTelephony::EStatusUnknown;&lt;br /&gt;&amp;nbsp; CActiveScheduler::Add(this);&lt;br /&gt;}&lt;br /&gt;CCallManager::~CCallManager()&lt;br /&gt;{&lt;br /&gt;&amp;nbsp; Cancel();&lt;br /&gt;}&lt;br /&gt;void CCallManager::ConstructL()&lt;br /&gt;{&lt;br /&gt;}&lt;br /&gt;void CCallManager::RequestNotification()&lt;br /&gt;{&lt;br /&gt;&amp;nbsp; if(IsActive())&lt;br /&gt;&amp;nbsp; {&lt;br /&gt;&amp;nbsp; &amp;nbsp; return;&lt;br /&gt;&amp;nbsp; }&lt;br /&gt;&amp;nbsp; if(iTelephony)&lt;br /&gt;&amp;nbsp; {&lt;br /&gt;&amp;nbsp; &amp;nbsp; iTelephony-&amp;gt;NotifyChange( iStatus, CTelephony::EVoiceLineStatusChange,&lt;br /&gt;iLineStatusPckg );&lt;br /&gt;&amp;nbsp; &amp;nbsp; SetActive();&lt;br /&gt;&amp;nbsp; }&lt;br /&gt;}&lt;br /&gt;void CCallManager::RunL()&lt;br /&gt;{&lt;br /&gt;&amp;nbsp; if( iStatus==KErrNone )&lt;br /&gt;&amp;nbsp; {&lt;br /&gt;&amp;nbsp; &amp;nbsp; if( iLineStatus.iStatus == CTelephony::EStatusRinging )&lt;br /&gt;&amp;nbsp; &amp;nbsp; {&lt;br /&gt;&amp;nbsp; &amp;nbsp; // Answer call by calling &amp;#039;AnswerIncomingCall()&amp;#039;&lt;br /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;iInCallListener.NewInCallArrived();&lt;br /&gt;&amp;nbsp; &amp;nbsp; }&lt;br /&gt;&amp;nbsp; }&lt;br /&gt;}&lt;br /&gt;void CCallManager::DoCancel()&lt;br /&gt;{&lt;br /&gt;&amp;nbsp; if(iTelephony)&lt;br /&gt;&amp;nbsp; {&lt;br /&gt;&amp;nbsp; &amp;nbsp; iTelephony-&amp;gt;CancelAsync( CTelephony::EVoiceLineStatusChangeCancel );&lt;br /&gt;&amp;nbsp; }&lt;br /&gt;}&lt;br /&gt;//end of CallManager.cpp file&lt;br /&gt;3. Application&amp;#039;s priority setting is:&lt;br /&gt;//SetPriority Code&lt;br /&gt;void CMyTest1AppUi::SetPriority()&lt;br /&gt;{ &lt;br /&gt;#if !defined(__WINS__) //FIXFIXME&lt;br /&gt;&amp;nbsp; &amp;nbsp; CEikonEnv::Static()-&amp;gt;WsSession().ComputeMode(RWsSession::EPriorityControlDisabled);&lt;br /&gt;&amp;nbsp; RThread T;&lt;br /&gt;&amp;nbsp; TFindThread fr(_L(&amp;quot;MyTest1*&amp;quot;));&lt;br /&gt;&amp;nbsp; TFullName fn;&lt;br /&gt;&amp;nbsp; if (fr.Next(fn) == KErrNone) //for thread&lt;br /&gt;&amp;nbsp; {&lt;br /&gt;&amp;nbsp; &amp;nbsp; if (T.Open(fn) == KErrNone)&lt;br /&gt;&amp;nbsp; &amp;nbsp; {&lt;br /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;T.SetPriority(EPriorityAbsoluteHigh);&lt;br /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;T.Close();&lt;br /&gt;&amp;nbsp; &amp;nbsp; }&lt;br /&gt;&amp;nbsp; }&lt;br /&gt;#endif&lt;br /&gt;}&lt;br /&gt;// end of SetPriority Code&lt;br /&gt;&lt;br /&gt;4. BringForeGround code&lt;br /&gt;//BringForeGround&lt;br /&gt;void CMyTest1AppUi::BringForeGroundL()&lt;br /&gt;{&lt;br /&gt;// Construct en empty TApaTask object&lt;br /&gt;// giving it a reference to the Window Server session&lt;br /&gt;&amp;nbsp; TApaTask task(iEikonEnv-&amp;gt;WsSession( ));&lt;br /&gt;&lt;br /&gt;// Initialise the object with the window group id of&lt;br /&gt;// our application (so that it represent our app)&lt;br /&gt;&amp;nbsp; task.SetWgId(CEikonEnv::Static()-&amp;gt;RootWin().Identifier());&lt;br /&gt;&lt;br /&gt;// Request window server to bring our application&lt;br /&gt;// to foreground&lt;br /&gt;&amp;nbsp; task.BringToForeground();&lt;br /&gt;}&lt;br /&gt;//end of BringForeground&lt;br /&gt;&lt;br /&gt;5. on incoming call notification from CallManager&lt;br /&gt;//Code&lt;br /&gt;void CMyTest1AppUi::NewInCallArrived()&lt;br /&gt;{&lt;br /&gt;&amp;nbsp; BringForeGroundL(); &lt;br /&gt;&amp;nbsp; ShowGlobalConfQueryL();&lt;br /&gt;}&lt;br /&gt;//end code&lt;br /&gt;&lt;br /&gt;-------------------------------------------------&lt;br /&gt;Could you verify it?&lt;br /&gt;&lt;br /&gt;Regards,&lt;br /&gt;Zahangir&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;</description>
 <pubDate>Tue, 13 Mar 2007 05:31:06 +0100</pubDate>
 <dc:creator>zahangir</dc:creator>
 <guid isPermaLink="false">comment 37368 at http://www.newlc.com</guid>
</item>
<item>
 <title>Re: Problem in CTelephony AnswerIncomingCall in Symbian 9.1</title>
 <link>http://www.newlc.com/en/topic-17582#comment-37367</link>
 <description>&lt;div class=&quot;smf-content&quot;&gt;Hello Zahangir,&lt;br /&gt;&lt;br /&gt;Did you mean problem regarding setting app foreground during incoming call ?&lt;br /&gt;&lt;br /&gt;In that case use SetOrdinalPosition(). search on this forum and also in the SDK to know how to use it. You can use this method to set ur app on top of everything even the system incoming dialog.&lt;br /&gt;&lt;br /&gt;Plz specify ur probelm in more&amp;nbsp; detail if posible if this is not requirement.&lt;br /&gt;&lt;br /&gt;Regards,&lt;br /&gt;tushar&lt;/div&gt;</description>
 <pubDate>Mon, 12 Mar 2007 16:01:45 +0100</pubDate>
 <dc:creator>tusharbhatta</dc:creator>
 <guid isPermaLink="false">comment 37367 at http://www.newlc.com</guid>
</item>
<item>
 <title>Re: Problem in CTelephony AnswerIncomingCall in Symbian 9.1</title>
 <link>http://www.newlc.com/en/topic-17582#comment-37366</link>
 <description>&lt;div class=&quot;smf-content&quot;&gt;Hi,&lt;br /&gt;&lt;br /&gt;I am fetching some problem application foreground when there is an incoming call.&lt;br /&gt;&lt;br /&gt;Do you have solved this?&lt;br /&gt;If yes, please post some sample code.&lt;br /&gt;If it is possible please send me a copy to &lt;a href=&quot;mailto:zahangirbd@gmail.com&quot;&gt;zahangirbd@gmail.com&lt;/a&gt;&lt;br /&gt;&lt;/div&gt;</description>
 <pubDate>Mon, 12 Mar 2007 13:33:33 +0100</pubDate>
 <dc:creator>zahangir</dc:creator>
 <guid isPermaLink="false">comment 37366 at http://www.newlc.com</guid>
</item>
<item>
 <title>Re: Problem in CTelephony AnswerIncomingCall in Symbian 9.1</title>
 <link>http://www.newlc.com/en/topic-17582#comment-37365</link>
 <description>&lt;div class=&quot;smf-content&quot;&gt;&lt;br /&gt;I have solved the app hang problem ( well, without a single reply from anybody&amp;nbsp; &lt;img src=&quot;/en/sites/all/modules/smf_filter/smf_smileys/undecided.gif&quot; alt=&quot;Undecided&quot; border=&quot;0&quot; /&gt; ). My app code was requesting two asynchronous methods simultaneously. &lt;br /&gt;&lt;br /&gt;&lt;/div&gt;</description>
 <pubDate>Sun, 25 Feb 2007 14:38:40 +0100</pubDate>
 <dc:creator>tusharbhatta</dc:creator>
 <guid isPermaLink="false">comment 37365 at http://www.newlc.com</guid>
</item>
<item>
 <title>Problem in CTelephony AnswerIncomingCall in Symbian 9.1</title>
 <link>http://www.newlc.com/en/topic-17582</link>
 <description>&lt;div class=&quot;smf-content&quot;&gt;&lt;/div&gt;&lt;p&gt;&lt;a href=&quot;http://www.newlc.com/en/topic-17582&quot;&gt;read more&lt;/a&gt;&lt;/p&gt;</description>
 <comments>http://www.newlc.com/en/topic-17582#comments</comments>
 <category domain="http://www.newlc.com/en/forums/telephony">Telephony</category>
 <pubDate>Thu, 08 Feb 2007 16:20:25 +0100</pubDate>
 <dc:creator>tusharbhatta</dc:creator>
 <guid isPermaLink="false">17101 at http://www.newlc.com</guid>
</item>
</channel>
</rss>
