|
#if !defined(AFX_SORTCOLUMN_H__B429EFC1_93B3_11D2_BD3E_204C4F4F5020__INCLUDED_)
#define AFX_SORTCOLUMN_H__B429EFC1_93B3_11D2_BD3E_204C4F4F5020__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
//////////////////////////////////////////////////////////////////////
// CSortItemText
class CSortItemText
{
public:
CSortItemText();
CSortItemText(const DWORD& dwData, const CString& sTxt);
virtual ~CSortItemText();
CString m_strTxt;
DWORD m_dwData;
};
//////////////////////////////////////////////////////////////////////
// CSortItemInt
class CSortItemInt
{
public:
CSortItemInt();
CSortItemInt(const DWORD& dwData, const CString& sTxt);
virtual ~CSortItemInt();
CString m_strTxt;
int m_nInt;
DWORD m_dwData;
};
//////////////////////////////////////////////////////////////////////
// CSortColumn
class CSortColumn
{
public:
CSortColumn();
CSortColumn(CListCtrl* pWnd, const int& nCol, const bool& bIsNumeric);
virtual ~CSortColumn();
void Sort(const bool& bAsc);
CListCtrl* m_pWnd;
int m_nCol;
bool m_bIsNumeric;
static int CALLBACK CompareAscText(LPARAM lParam1, LPARAM lParam2, LPARAM lParamSort);
static int CALLBACK CompareDesText(LPARAM lParam1, LPARAM lParam2, LPARAM lParamSort);
static int CALLBACK CompareAscInt(LPARAM lParam1, LPARAM lParam2, LPARAM lParamSort);
static int CALLBACK CompareDesInt(LPARAM lParam1, LPARAM lParam2, LPARAM lParamSort);
};
#endif // !defined(AFX_SORTCOLUMN_H__B429EFC1_93B3_11D2_BD3E_204C4F4F5020__INCLUDED_)
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.
This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.
A list of licenses authors might use can be found here
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.