00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #include "CResume.h"
00018
00026 CResume* CResume::NewL(MExecAsync* aController)
00027 {
00028 CResume* self = new(ELeave) CResume(aController);
00029 CleanupStack::PushL(self);
00030 self->ConstructL();
00031 CleanupStack::Pop(self);
00032 return self;
00033 }
00034
00039 CResume::~CResume()
00040 {
00041 Cancel();
00042 }
00043
00049 void CResume::DoStartRequestL(CTelephony::TCallId aCallId)
00050 {
00051 _LIT(KDummyAnswerPanic, "CResume Get Method");
00052 __ASSERT_ALWAYS(!IsActive(), User::Panic(KDummyAnswerPanic, 1));
00053 iRequestNotify = EFalse;
00054 CTelephony::TCallCapsV1 callCapsV1;
00055 CTelephony::TCallCapsV1Pckg callCapsV1Pckg(callCapsV1);
00056
00057
00058 iTelephony->GetCallDynamicCaps(aCallId, callCapsV1Pckg);
00059
00060 if( callCapsV1.iControlCaps & CTelephony::KCapsResume )
00061 {
00062
00063 iTelephony->Resume(iStatus, aCallId);
00064 SetActive();
00065 }
00066 else
00067 {
00068
00069 }
00070 }
00071
00078 CResume::CResume(MExecAsync* aController)
00079 : CISVAPIAsync(aController, KResume)
00080 {
00081
00082 }
00083
00087 void CResume::ConstructL()
00088 {
00089
00090 }
00091
00096 void CResume::RunL()
00097 {
00098 if(iStatus != KErrNone)
00099 {
00100 iConsole->Printf(KError);
00101
00102
00103 iConsole->Printf(_L("%d\n"), iStatus.Int());
00104 }
00105 else
00106 {
00107 ExampleComplete();
00108 }
00109 }
00110
00114 void CResume::DoCancel()
00115 {
00116
00117 iTelephony->CancelAsync(CTelephony::EResumeCancel);
00118 }
00119