Sophie

Sophie

distrib > Mandriva > 2011.0 > i586 > media > contrib-release-debug > by-pkgid > f53c6fc016b4649afd106d82f7232fba > files > 30

cmmusic-debug-1.5-3mdv2011.0.i586.rpm

/*! @file
********************************************************************************
<PRE>
Module       : CMMusic
file	     : 
function	 : 
author       : fedorawang
ver	         : v1.5
--------------------------------------------------------------------------------
Copyright    : GPL(General Public License)
--------------------------------------------------------------------------------
</PRE>
*******************************************************************************/
#ifndef FILEMGR_H_
#define FILEMGR_H_

#include "Helper.h"

class CFileMgr
{
public:
	typedef struct _FILEITEM
	{
		unsigned char ucType;
		std::string strName;
		std::string strType;
	} FILEITEM, *LPFILEITEM;
public:
	CFileMgr();
	virtual ~CFileMgr();
public:
	void Load(int nType);
	int GetSize();
	const char* GetName(int nIndex);
	unsigned char GetType(int nIndex);
	const char* GetDesc(int nIndex);
	std::string GetPath(int nIndex);
	void Clear();
	bool SetSel(int nIndex);
	int FindIndex(const char* lpszStr);
	void InsertItem(const std::string& strType,const LPFILEITEM pItem);
private:
	static bool CmpName(const FILEITEM& lItem,const FILEITEM& rItem);
	std::vector<FILEITEM> m_vctFile;
	std::string m_strPath;
	std::string m_strMusicType;
	std::string m_strListType;
};

#endif /*FILEMGR_H_*/