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

📄 hplaylist.cpp

📁 一个使用tapi实现的自动语音应答的例子
💻 CPP
字号:
// HPlayList.cpp: implementation of the CHPlayList class.
//
//////////////////////////////////////////////////////////////////////

#include "stdafx.h"
#include "HPlayList.h"

#ifdef _DEBUG
#undef THIS_FILE
static char THIS_FILE[]=__FILE__;
#define new DEBUG_NEW
#endif

//////////////////////////////////////////////////////////////////////
// Construction/Destruction
//////////////////////////////////////////////////////////////////////

CHPlayList::CHPlayList()
{
	m_index=0;
}

CHPlayList::~CHPlayList()
{

}

void CHPlayList::Add(CString adr)
{
	if (adr=="") return;
	
	m_list.Add(adr);
}

CString CHPlayList::GetNext()
{
	if (m_index>=(UINT)m_list.GetSize())
		return "END_OF_LIST";
	return m_list.GetAt(m_index++);
}

UINT CHPlayList::GetCurrentIndex()
{
	return m_index;
}

CString CHPlayList::GetPrevious()
{
	if (m_index<=0)
		return "";
	return m_list.GetAt(m_index-1);
}

CString CHPlayList::GetLast()
{
	return m_list.GetAt(m_list.GetSize()-1);
}

UINT CHPlayList::GetCount()
{
	return m_list.GetSize();
}

void CHPlayList::Reset()
{
	m_list.RemoveAll();
	m_index=0;
//	m_list.FreeExtra();
}

⌨️ 快捷键说明

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