131 "CPhoneSingleAndCallSetup::HandleKeyMessageL()"); |
131 "CPhoneSingleAndCallSetup::HandleKeyMessageL()"); |
132 switch ( aCode ) |
132 switch ( aCode ) |
133 { |
133 { |
134 // send-key |
134 // send-key |
135 case EKeyYes: |
135 case EKeyYes: |
136 if ( CPhoneState::IsNumberEntryUsedL() ) |
136 if ( iNumberEntryManager->IsNumberEntryUsedL() ) |
137 { |
137 { |
138 // send a manual control sequence |
138 // send a manual control sequence |
139 CPhoneState::CallFromNumberEntryL(); |
139 iNumberEntryManager->CallFromNumberEntryL(); |
140 } |
140 } |
141 else |
141 else |
142 { |
142 { |
143 // Show not allowed note |
143 // Show not allowed note |
144 CPhoneState::SendGlobalErrorNoteL( |
144 CPhoneState::SendGlobalErrorNoteL( |
214 TPhoneCmdParamBoolean globalNotifierParam; |
214 TPhoneCmdParamBoolean globalNotifierParam; |
215 globalNotifierParam.SetBoolean( EFalse ); |
215 globalNotifierParam.SetBoolean( EFalse ); |
216 iViewCommandHandle->ExecuteCommandL( EPhoneViewSetGlobalNotifiersDisabled, |
216 iViewCommandHandle->ExecuteCommandL( EPhoneViewSetGlobalNotifiersDisabled, |
217 &globalNotifierParam ); |
217 &globalNotifierParam ); |
218 |
218 |
219 // Remove the number entry if it isn't DTMF dialer |
219 iNumberEntryManager->RemoveNumberEntryIfVisibilityIsFalseL(); |
220 if ( !IsNumberEntryVisibleL() ) |
220 |
221 { |
221 iViewCommandHandle->ExecuteCommandL( EPhoneViewUpdateBubble, aCallId ); |
222 iViewCommandHandle->ExecuteCommandL( EPhoneViewRemoveNumberEntry ); |
222 UpdateUiCommands(); |
223 } |
|
224 |
|
225 TPhoneCmdParamCallHeaderData callHeaderParam; |
|
226 callHeaderParam.SetCallState( EPEStateConnecting ); |
|
227 iViewCommandHandle->ExecuteCommandL( EPhoneViewUpdateBubble, aCallId, |
|
228 &callHeaderParam ); |
|
229 |
|
230 EndUiUpdate(); |
223 EndUiUpdate(); |
231 |
|
232 // Set Hold flag to view EFalse that dtmf menu item not delete |
|
233 TPhoneCmdParamBoolean holdFlag; |
|
234 holdFlag.SetBoolean( EFalse ); |
|
235 iViewCommandHandle->ExecuteCommandL( EPhoneViewSetHoldFlag, &holdFlag ); |
|
236 |
|
237 SetTouchPaneButtons( EPhoneCallSetupAndSingleButtons ); |
|
238 |
224 |
239 // Go to alerting state |
225 // Go to alerting state |
240 UpdateCbaL( EPhoneCallHandlingInCallCBA ); |
|
241 iStateMachine->ChangeState( EPhoneStateAlertingInSingle ); |
226 iStateMachine->ChangeState( EPhoneStateAlertingInSingle ); |
242 } |
227 } |
243 |
228 |
244 // ----------------------------------------------------------- |
229 // ----------------------------------------------------------- |
245 // CPhoneSingleAndCallSetup::HandleConnectedL |
230 // CPhoneSingleAndCallSetup::HandleConnectedL |
251 "CPhoneSingleAndCallSetup::HandleConnectedL()"); |
236 "CPhoneSingleAndCallSetup::HandleConnectedL()"); |
252 |
237 |
253 BeginUiUpdateLC(); |
238 BeginUiUpdateLC(); |
254 |
239 |
255 // Show bubble |
240 // Show bubble |
256 TPhoneCmdParamCallHeaderData callHeaderParam; |
241 iViewCommandHandle->ExecuteCommandL( EPhoneViewUpdateBubble, aCallId ); |
257 callHeaderParam.SetCallState( EPEStateConnected ); |
|
258 iViewCommandHandle->ExecuteCommandL( EPhoneViewUpdateBubble, aCallId, |
|
259 &callHeaderParam ); |
|
260 |
242 |
261 // Remove the number entry if it isn't DTMF dialer |
243 // Remove the number entry if it isn't DTMF dialer |
262 if ( !IsNumberEntryVisibleL() ) |
244 if ( !iNumberEntryManager->IsNumberEntryVisibleL() ) |
263 { |
245 { |
264 iViewCommandHandle->ExecuteCommandL( EPhoneViewRemoveNumberEntry ); |
246 iViewCommandHandle->ExecuteCommandL( EPhoneViewRemoveNumberEntry ); |
265 } |
247 } |
266 |
248 |
267 // Set Hold flag to view |
249 UpdateUiCommands(); |
268 TPhoneCmdParamBoolean holdFlag; |
|
269 holdFlag.SetBoolean( EFalse ); |
|
270 iViewCommandHandle->ExecuteCommandL( EPhoneViewSetHoldFlag, &holdFlag ); |
|
271 |
|
272 SetTouchPaneButtons( EPhoneTwoSinglesButtons ); |
|
273 |
250 |
274 EndUiUpdate(); |
251 EndUiUpdate(); |
275 |
252 |
276 // Go to two singles state |
253 // Go to two singles state |
277 UpdateCbaL( EPhoneCallHandlingNewCallSwapCBA ); |
|
278 iStateMachine->ChangeState( EPhoneStateTwoSingles ); |
254 iStateMachine->ChangeState( EPhoneStateTwoSingles ); |
279 |
255 |
280 } |
256 } |
281 |
257 |
282 // ----------------------------------------------------------- |
258 // ----------------------------------------------------------- |
297 iViewCommandHandle->ExecuteCommandL( |
273 iViewCommandHandle->ExecuteCommandL( |
298 EPhoneViewGetCountOfActiveCalls, &activeCallCount ); |
274 EPhoneViewGetCountOfActiveCalls, &activeCallCount ); |
299 |
275 |
300 if( activeCallCount.Integer() ) |
276 if( activeCallCount.Integer() ) |
301 { |
277 { |
302 if ( IsNumberEntryUsedL() ) |
278 iNumberEntryManager->SetVisibilityIfNumberEntryUsedL(ETrue); |
303 { |
279 UpdateUiCommands(); |
304 // Show the number entry if it exists |
|
305 SetNumberEntryVisibilityL(ETrue); |
|
306 } |
|
307 else |
|
308 { |
|
309 // Set incall CBAs |
|
310 UpdateCbaL( EPhoneCallHandlingInCallCBA ); |
|
311 } |
|
312 |
|
313 SetTouchPaneButtons( EPhoneIncallButtons ); |
|
314 iStateMachine->ChangeState( EPhoneStateSingle ); |
280 iStateMachine->ChangeState( EPhoneStateSingle ); |
315 } |
281 } |
316 else |
282 else |
317 { |
283 { |
318 // Display call termination note, if necessary |
|
319 DisplayCallTerminationNoteL(); |
284 DisplayCallTerminationNoteL(); |
320 |
285 |
321 // Single call was terminated |
286 // Single call was terminated |
322 SetTouchPaneButtons( EPhoneCallSetupButtons ); |
287 UpdateUiCommands(); |
323 SetToolbarButtonLoudspeakerEnabled(); |
288 SetToolbarButtonLoudspeakerEnabled(); |
324 // Update call setup CBAs |
|
325 UpdateCbaL( EPhoneCallHandlingCallSetupCBA ); |
|
326 iStateMachine->ChangeState( EPhoneStateCallSetup ); |
289 iStateMachine->ChangeState( EPhoneStateCallSetup ); |
327 } |
290 } |
328 |
|
329 EndUiUpdate(); |
291 EndUiUpdate(); |
330 } |
292 } |
331 |
293 |
332 // ----------------------------------------------------------- |
294 // ----------------------------------------------------------- |
333 // CPhoneSingleAndCallSetup::HandleCommandL |
295 // CPhoneSingleAndCallSetup::HandleCommandL |