📄 lcdtest.cpp
字号:
// LcdTest.cpp : implementation file
//
#include "stdafx.h"
#include "NoteBook.h"
#include "LcdTest.h"
#include "LcdRlt.h"
#include "SpeedRlt.h"
#include "Performance.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// CLcdTest dialog
CLcdTest::CLcdTest(CWnd* pParent /*=NULL*/)
: CDialog(CLcdTest::IDD, pParent)
{
//{{AFX_DATA_INIT(CLcdTest)
// NOTE: the ClassWizard will add member initialization here
//}}AFX_DATA_INIT
}
void CLcdTest::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CLcdTest)
// NOTE: the ClassWizard will add DDX and DDV calls here
//}}AFX_DATA_MAP
}
BEGIN_MESSAGE_MAP(CLcdTest, CDialog)
//{{AFX_MSG_MAP(CLcdTest)
ON_BN_CLICKED(IDC_STARTTEST, OnStarttest)
ON_BN_CLICKED(IDC_LCDTEST, OnLcdTest)
ON_BN_CLICKED(IDC_SPEED, OnSpeed)
ON_BN_CLICKED(IDC_PERFORMANCE, OnPerformance)
ON_BN_CLICKED(IDC_FINISH, OnFinish)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CLcdTest message handlers
void CLcdTest::OnStarttest()
{
// TODO: Add your control notification handler code here
ShellExecute(NULL,"open","D:\\测试工具\\DisplayX CN.exe",NULL,NULL,SW_SHOW);
Sleep(10000);
if (::FindWindow(NULL,"DisplayX - 显示器测试工具"))
{
CLcdRlt dlg;
dlg.DoModal();
}
else
MessageBox("测试故障,请重新测试!");
ShellExecute(NULL,"open","D:\\测试工具\\CrystalMark2004R3.exe",
NULL,NULL,SW_SHOW);
Sleep(10000);
if (::FindWindow("#32770","CrystalMark 2004R3 [0.9.126.450] "))
{
CSpeedRlt dlg;
dlg.DoModal();
}
else
MessageBox("测试故障,请重新测试!");
ShellExecute(NULL,"open","E:\\测试软件安装包\\PerformanceTest\\pt.exe",
NULL,NULL,SW_SHOW);
Sleep(10000);
if (::FindWindow(NULL,"PerformanceTest 6.0"))
{
CPerformance dlg;
dlg.DoModal();
}
else
MessageBox("测试故障,请重新测试!");
}
void CLcdTest::OnLcdTest()
{
// TODO: Add your control notification handler code here
ShellExecute(NULL,"open","D:\\测试工具\\DisplayX CN.exe",NULL,NULL,SW_SHOW);
Sleep(10000);
if (::FindWindow(NULL,"DisplayX - 显示器测试工具"))
{
CLcdRlt dlg;
dlg.DoModal();
}
else
MessageBox("测试故障,请重新测试!");
}
void CLcdTest::OnSpeed()
{
// TODO: Add your control notification handler code here
ShellExecute(NULL,"open","D:\\测试工具\\CrystalMark2004R3.exe",
NULL,NULL,SW_SHOW);
Sleep(10000);
if (::FindWindow("#32770","CrystalMark 2004R3 [0.9.126.450] "))
{
CSpeedRlt dlg;
dlg.DoModal();
}
else
MessageBox("测试故障,请重新测试!");
}
void CLcdTest::OnPerformance()
{
// TODO: Add your control notification handler code here
ShellExecute(NULL,"open","E:\\测试软件安装包\\PerformanceTest\\pt.exe",
NULL,NULL,SW_SHOW);
Sleep(10000);
if (::FindWindow(NULL,"PerformanceTest 6.0"))
{
CPerformance dlg;
dlg.DoModal();
}
else
MessageBox("测试故障,请重新测试!");
}
void CLcdTest::OnFinish()
{
// TODO: Add your control notification handler code here
SendMessage(WM_SYSCOMMAND,SC_CLOSE,0);
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -