📄 set4view.cpp
字号:
// Set4View.cpp : implementation file
//
#include "stdafx.h"
#include "CDMS.h"
#include "Set4View.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// CSet4View
IMPLEMENT_DYNCREATE(CSet4View, CFormView)
CSet4View::CSet4View()
: CFormView(CSet4View::IDD)
{
//{{AFX_DATA_INIT(CSet4View)
// NOTE: the ClassWizard will add member initialization here
//}}AFX_DATA_INIT
m_pMainFrame = NULL;
}
CSet4View::~CSet4View()
{
}
void CSet4View::DoDataExchange(CDataExchange* pDX)
{
CFormView::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CSet4View)
// NOTE: the ClassWizard will add DDX and DDV calls here
//}}AFX_DATA_MAP
}
BEGIN_MESSAGE_MAP(CSet4View, CFormView)
//{{AFX_MSG_MAP(CSet4View)
ON_WM_DESTROY()
ON_WM_PAINT()
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CSet4View diagnostics
#ifdef _DEBUG
void CSet4View::AssertValid() const
{
CFormView::AssertValid();
}
void CSet4View::Dump(CDumpContext& dc) const
{
CFormView::Dump(dc);
}
#endif //_DEBUG
/////////////////////////////////////////////////////////////////////////////
// CSet4View message handlers
void CSet4View::OnInitialUpdate()
{
CFormView::OnInitialUpdate();
// TODO: Add your specialized code here and/or call the base class
/*----隐藏滚动条----*/
CSize sizeTotal;
sizeTotal.cx = sizeTotal.cy = 0;
SetScrollSizes(MM_TEXT, sizeTotal);
/*----隐藏滚动条----*/
//<-------------获取主框架指针------------->
m_pMainFrame = (CMainFrame*)AfxGetMainWnd();
//<-------------保存窗口指针------------->
m_pMainFrame->m_hViewSet4 = this->m_hWnd;
// InitCobArray();
}
LRESULT CSet4View::WindowProc(UINT message, WPARAM wParam, LPARAM lParam)
{
// TODO: Add your specialized code here and/or call the base class
switch(message)
{
case UM_ACTIVATE_VIEW4:
this->GetParentFrame()->ActivateFrame();
break;
case UM_COLLECTCOMPLETE:
for(int i=0; i<1024; i++)
{
m_nData[i] = m_pMainFrame->m_nOriginalData[3][i];
}
// DrawBackgroundOfTimeDomainWave();
break;
}
return CFormView::WindowProc(message, wParam, lParam);
}
void CSet4View::OnDestroy()
{
m_pMainFrame->m_hViewSet4 = NULL;
CFormView::OnDestroy();
// TODO: Add your message handler code here
}
void CSet4View::OnPaint()
{
CPaintDC dc(this); // device context for painting
// TODO: Add your message handler code here
// Do not call CFormView::OnPaint() for painting messages
}
void CSet4View::OnActivateView(BOOL bActivate, CView* pActivateView, CView* pDeactiveView)
{
// TODO: Add your specialized code here and/or call the base class
if(bActivate)
{
//设置当前活动视图标志
m_pMainFrame->SetCurActiveView(VIEW_TYPE_SET4);//
}
CFormView::OnActivateView(bActivate, pActivateView, pDeactiveView);
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -