×
Namespaces

Variants
Actions

如何检测拨出电话的类型和状态

From Nokia Developer Wiki
Jump to: navigation, search
Article Metadata

文章
huwell 在 05 Jul 2007 创建
最后由 hamishwillee 在 15 Dec 2011 编辑
  • 设备, 软件 版本:

S60 3rd Edition

S60 3rd Edition, FP1


  • 详细描述:

我们可以使用Publish & Subscribe keys来检测拨出电话的类型和状态。有三个PS keys可用来获取相关属性值。

    const TUid    KPSUidTelephonyCallHandling = { 0x101f8787 };
 
const TUint32 KTelephonyCallState = 0x00000004;
 
const TUint32 KTelephonyCallType = 0x00000005;


获取电话类型:

    RProperty iProperty;
 
iProperty.Get(KPSUidTelephonyCallHandling, KTelephonyCallType, calltype);


电话呼叫的类型(TPSTelephonyCallType)值:

            EPSTelephonyCallTypeUninitialized = 0,
 
EPSTelephonyCallTypeNone,
 
EPSTelephonyCallTypeCSVoice,
 
EPSTelephonyCallTypeFax,
 
EPSTelephonyCallTypeData,
 
EPSTelephonyCallTypeHSCSD,
 
EPSTelephonyCallTypeH324Multimedia,
 
EPSTelephonyCallTypeVoIP


如何获得呼叫状态信息:

    iProperty.Get(KPSUidTelephonyCallHandling, KTelephonyCallState , callstate);


电话呼叫的状态(TPSTelephonyCallState)值:

            EPSTelephonyCallStateUninitialized = 0,
 
EPSTelephonyCallStateNone,
 
EPSTelephonyCallStateAlerting,
 
EPSTelephonyCallStateRinging,
 
EPSTelephonyCallStateDialling,
 
EPSTelephonyCallStateAnswering,
 
EPSTelephonyCallStateDisconnecting,
 
EPSTelephonyCallStateConnected,
 
EPSTelephonyCallStateHold


PS Keys for Call Status & Indicators API 并非官方S60 SDK的一部分,但可以通过

Extensions plug-in package for S60 3rd Edition SDK for Symbian OS, for C++, MR 获得

注意,Nokia没有承诺这些API在各平台或平台内可以二进制兼容。

This page was last modified on 15 December 2011, at 13:00.
96 page views in the last 30 days.

Was this page helpful?

Your feedback about this content is important. Let us know what you think.

 

Thank you!

We appreciate your feedback.

×