⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 dtp_event.h

📁 三汇CTI示例程序源码
💻 H
字号:
//---------------------------------------------------------------------------

#ifndef DTP_EventH
#define DTP_EventH
//---------------------------------------------------------------------------
#include <Classes.hpp>
#include <Controls.hpp>
#include <StdCtrls.hpp>
#include <Forms.hpp>
#include <ComCtrls.hpp>
//---------------------------------------------------------------------------
#define MAX_CIC 1000		//CHS:最大被监控电路数
			       	//ENG:Maximum number of the monitored circuits
//CHS:自定义电路状态
//ENG:User-defined circuit status
enum CIRCUIT_STATE
{
	CIRCUIT_IDLE,			//CHS:空闲状态
				      	//ENG:Idle state
	CIRCUIT_RCV_PHONUM,		//CHS:收号状态
				      	//ENG:State of receiving phone number
	CIRCUIT_RINGING,		//CHS:振铃状态
				      	//ENG:State of ringing
	CIRCUIT_TALKING			//CHS:通话状态
				      	//ENG:State of talking
};
//-------------------------------------------------------------------------------------

enum RECORD_DIRECTION
{
	CALL_IN_RECORD,		//CHS:来话方向录音
						//ENG:Incoming call recording
	CALL_OUT_RECORD,	//CHS:去话方向录音
						//ENG:Outgoing call recording
	MIX_RECORD			//CHS:来话/去话方向混合录音
						//ENG:Mix-record of incoming/outgoing call 
};
//---------------------------------------------------------------------------------------

typedef struct tagCIC_STRUCT
{
	int  nCicState;		       	//CHS:被监控电路状态
				       	//ENG:State of monitored circuits
	char szCallerId[20];		//CHS:主叫号码
				       	//ENG:Calling party number
	char szCalleeId[20];		//CHS:被叫号码
				       	//ENG:Called party number
	char szCallInDtmf[100];		//CHS:来话通道接收到的DTMF
				       	//ENG:DTMF received on the incoming channel
	char szCallOutDtmf[100];	//CHS:去话通道接收到的DTMF
				       	//ENG:DTMF received on the outgoing channel
	WORD wRecDirection;	       	//CHS:录音方向
				       	//ENG:Recording direction
	int  nCallInCh;		       	//CHS:来话通道
				       	//ENG:Incoming channel
	int  nCallOutCh;	       	//CHS:去话通道
				       	//ENG:Outgoing channel
	int  nCallInIndex;	       	//CHS:指示来话通道接收到的DTMF是第几个
				       	//ENG:Used to denote which number is the DTMF received on the incoming channel
	int  nCallOutIndex;	       	//CHS:指示去话通道接收到的DTMF是第几个
				       	//ENG:Used to denote which number is the DTMF received on the outgoing channel
}CIC_STRUCT;
//----------------------------------------------------------------------

class TDTP_Form : public TForm
{
__published:	// IDE-managed Components
        TListView *m_CicList;
        TGroupBox *GroupBox1;
        TGroupBox *GroupBox2;
        TRadioButton *RadioButton1;
        TRadioButton *RadioButton2;
        TLabel *Label1;
        TComboBox *m_cmbCic;
        TRadioButton *RadioButton3;
        TRadioButton *RadioButton4;
        TRadioButton *RadioButton5;
        void __fastcall RadioButton3Click(TObject *Sender);
        void __fastcall RadioButton1Click(TObject *Sender);
        void __fastcall RadioButton2Click(TObject *Sender);
        void __fastcall m_cmbCicChange(TObject *Sender);
        void __fastcall RadioButton4Click(TObject *Sender);
        void __fastcall RadioButton5Click(TObject *Sender);
        void __fastcall OnCreate(TObject *Sender);
        void __fastcall OnDestroy(TObject *Sender);
private:	// User declarations
        int m_nCallFnMode;
	CIC_STRUCT CicState[MAX_CIC];	//CHS:被监控电路
					//ENG:Monitored circuits
	int nMaxCic;			//CHS:最大被监控电路数
					//ENG:Maximum number of the monitored circuits
        void   __fastcall   WndProc(Messages::TMessage   &Message);
public:		// User declarations
        __fastcall TDTP_Form(TComponent* Owner);
        
	BOOL __fastcall InitCtiBoard();			//CHS:初始化板卡
			        		      	//ENG:Initialize board
	void __fastcall InitCircuitListCtrl();		//CHS:初始化列表
				        	      	//ENG:Initialize list
	void __fastcall UpdateCircuitListCtrl(int n);         //CHS:更新列表
					        	//ENG:Update list
};
//---------------------------------------------------------------------------
extern PACKAGE TDTP_Form *DTP_Form;
//---------------------------------------------------------------------------
#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -