67 lines
2.2 KiB
C++
67 lines
2.2 KiB
C++
// IndicatorDlg.cpp: 实现文件
|
||
//
|
||
|
||
#include "stdafx.h"
|
||
#include "IndicatorDlg.h"
|
||
#include "afxdialogex.h"
|
||
|
||
|
||
// IndicatorDlg 对话框
|
||
|
||
IMPLEMENT_DYNAMIC(IndicatorDlg, CDialog)
|
||
|
||
IndicatorDlg::IndicatorDlg(MFC_UI *pUI,CWnd* pParent /*=nullptr*/)
|
||
: CDialog(IDD_DIALOG_INDICATOR, pParent)
|
||
{
|
||
m_ui=pUI;
|
||
//SetTimer(1, 100, NULL);
|
||
}
|
||
|
||
IndicatorDlg::~IndicatorDlg()
|
||
{
|
||
//KillTimer(1);
|
||
}
|
||
|
||
void IndicatorDlg::DoDataExchange(CDataExchange* pDX)
|
||
{
|
||
CDialog::DoDataExchange(pDX);
|
||
}
|
||
|
||
|
||
BEGIN_MESSAGE_MAP(IndicatorDlg, CDialog)
|
||
ON_BN_CLICKED(IDC_BTNSTOPSCAN, &IndicatorDlg::OnBnClickedBtnstopscan)
|
||
ON_WM_CLOSE()
|
||
END_MESSAGE_MAP()
|
||
|
||
|
||
// IndicatorDlg 消息处理程序
|
||
|
||
|
||
void IndicatorDlg::OnBnClickedBtnstopscan()
|
||
{
|
||
// TODO: 在此添加控件通知处理程序代码
|
||
CheckCnacel();
|
||
}
|
||
|
||
|
||
void IndicatorDlg::CheckCnacel()
|
||
{
|
||
int ret=IDYES;
|
||
if (!m_ui->m_pDS->IsImageQueueEmpty())
|
||
{
|
||
ret=MessageBox("仍有图像未传输完毕,确认停止传输?","提示",MB_YESNO|MB_ICONWARNING);//""
|
||
}
|
||
|
||
if (ret==IDYES)
|
||
{
|
||
m_ui->Cancel();
|
||
}
|
||
}
|
||
|
||
void IndicatorDlg::OnClose()
|
||
{
|
||
// TODO: 在此添加消息处理程序代码和/或调用默认值
|
||
CheckCnacel();
|
||
CDialog::OnClose();
|
||
}
|