134 lines
3.7 KiB
C++
134 lines
3.7 KiB
C++
// opexeccersptestsptlistview.cpp : implementation file
|
|
//
|
|
|
|
#include "stdafx.h"
|
|
#include "geomative.h"
|
|
#include "opexeccersptestsptlistview.h"
|
|
|
|
#ifdef _DEBUG
|
|
#define new DEBUG_NEW
|
|
#undef THIS_FILE
|
|
static char THIS_FILE[] = __FILE__;
|
|
#endif
|
|
|
|
|
|
extern int g_iCurrListColIndex;
|
|
extern int g_iCurrListColOrder;
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
// COpExecCERSPTestSptListView
|
|
|
|
IMPLEMENT_DYNCREATE(COpExecCERSPTestSptListView, CListView)
|
|
|
|
COpExecCERSPTestSptListView::COpExecCERSPTestSptListView()
|
|
{
|
|
}
|
|
|
|
COpExecCERSPTestSptListView::~COpExecCERSPTestSptListView()
|
|
{
|
|
}
|
|
|
|
|
|
BEGIN_MESSAGE_MAP(COpExecCERSPTestSptListView, CListView)
|
|
//{{AFX_MSG_MAP(COpExecCERSPTestSptListView)
|
|
// NOTE - the ClassWizard will add and remove mapping macros here.
|
|
//}}AFX_MSG_MAP
|
|
END_MESSAGE_MAP()
|
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
// COpExecCERSPTestSptListView drawing
|
|
|
|
void COpExecCERSPTestSptListView::OnDraw(CDC* pDC)
|
|
{
|
|
CDocument* pDoc = GetDocument();
|
|
// TODO: add draw code here
|
|
}
|
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
// COpExecCERSPTestSptListView diagnostics
|
|
|
|
#ifdef _DEBUG
|
|
void COpExecCERSPTestSptListView::AssertValid() const
|
|
{
|
|
CListView::AssertValid();
|
|
}
|
|
|
|
void COpExecCERSPTestSptListView::Dump(CDumpContext& dc) const
|
|
{
|
|
CListView::Dump(dc);
|
|
}
|
|
#endif //_DEBUG
|
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
// COpExecCERSPTestSptListView message handlers
|
|
|
|
void COpExecCERSPTestSptListView::OnInitialUpdate()
|
|
{
|
|
CListView::OnInitialUpdate();
|
|
|
|
// TODO: Add your specialized code here and/or call the base class
|
|
CString strColTitle;
|
|
LVCOLUMN lvCol;
|
|
int iColIndex = (int)VAL_ZERO;
|
|
lvCol.mask = LVCF_FMT;
|
|
lvCol.fmt = LVCFMT_RIGHT;
|
|
/*
|
|
GetListCtrl().SetExtendedStyle(LVS_EX_FULLROWSELECT | LVS_EX_HEADERDRAGDROP
|
|
| LVS_EX_ONECLICKACTIVATE | LVS_EX_GRIDLINES | LVS_EX_CHECKBOXES);
|
|
*/
|
|
|
|
GetListCtrl().SetExtendedStyle(LVS_EX_FULLROWSELECT | LVS_EX_HEADERDRAGDROP
|
|
| LVS_EX_ONECLICKACTIVATE | LVS_EX_GRIDLINES);
|
|
|
|
g_iCurrListColIndex = (int)VAL_ZERO;
|
|
g_iCurrListColOrder = (int)VAL_ZERO;
|
|
|
|
strColTitle.Empty();
|
|
strColTitle.LoadString(IDS_DB_TD2DCON_TSN);
|
|
GetListCtrl().InsertColumn(iColIndex, strColTitle, LVCFMT_LEFT, 55);
|
|
GetListCtrl().SetColumn(iColIndex, &lvCol);
|
|
|
|
iColIndex++;
|
|
strColTitle.Empty();
|
|
strColTitle.LoadString(IDS_DB_SCRIPT_a);
|
|
GetListCtrl().InsertColumn(iColIndex, strColTitle, LVCFMT_LEFT, 60);
|
|
GetListCtrl().SetColumn(iColIndex, &lvCol);
|
|
|
|
iColIndex++;
|
|
strColTitle.Empty();
|
|
strColTitle.LoadString(IDS_DB_SCRIPT_b);
|
|
GetListCtrl().InsertColumn(iColIndex, strColTitle, LVCFMT_LEFT, 60);
|
|
GetListCtrl().SetColumn(iColIndex, &lvCol);
|
|
|
|
iColIndex++;
|
|
strColTitle.Empty();
|
|
strColTitle.LoadString(IDS_DB_SCRIPT_x);
|
|
GetListCtrl().InsertColumn(iColIndex, strColTitle, LVCFMT_LEFT, 60);
|
|
GetListCtrl().SetColumn(iColIndex, &lvCol);
|
|
|
|
iColIndex++;
|
|
strColTitle.Empty();
|
|
strColTitle.LoadString(IDS_DB_SCRIPT_y);
|
|
GetListCtrl().InsertColumn(iColIndex, strColTitle, LVCFMT_LEFT, 60);
|
|
GetListCtrl().SetColumn(iColIndex, &lvCol);
|
|
|
|
iColIndex++;
|
|
strColTitle.Empty();
|
|
strColTitle.LoadString(IDS_DB_TD2DCON_N);
|
|
GetListCtrl().InsertColumn(iColIndex, strColTitle, LVCFMT_LEFT, 60);
|
|
GetListCtrl().SetColumn(iColIndex, &lvCol);
|
|
|
|
iColIndex++;
|
|
strColTitle.Empty();
|
|
strColTitle.LoadString(IDS_DB_TD2DCON_K);
|
|
GetListCtrl().InsertColumn(iColIndex, strColTitle, LVCFMT_LEFT, 90);
|
|
GetListCtrl().SetColumn(iColIndex, &lvCol);
|
|
}
|
|
|
|
BOOL COpExecCERSPTestSptListView::PreCreateWindow(CREATESTRUCT& cs)
|
|
{
|
|
// TODO: Add your specialized code here and/or call the base class
|
|
cs.style &= ~LVS_TYPEMASK;
|
|
cs.style |= LVS_REPORT | LVS_SINGLESEL | LVS_SHOWSELALWAYS;
|
|
return CListView::PreCreateWindow(cs);
|
|
}
|