-
Notifications
You must be signed in to change notification settings - Fork 0
/
Wait.cpp
55 lines (49 loc) · 1.09 KB
/
Wait.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
// Wait.cpp : 實作檔
//
#include "stdafx.h"
#include "HM_Machine.h"
#include "Wait.h"
#include "afxdialogex.h"
// CWait 對話方塊
IMPLEMENT_DYNAMIC(CWait, CDialogEx)
CWait::CWait(CWnd* pParent /*=NULL*/)
: CDialogEx(IDD_WAITING, pParent)
{
}
CWait::~CWait()
{
}
void CWait::DoDataExchange(CDataExchange* pDX)
{
CDialogEx::DoDataExchange(pDX);
}
BEGIN_MESSAGE_MAP(CWait, CDialogEx)
ON_WM_TIMER()
END_MESSAGE_MAP()
// CWait 訊息處理常式
BOOL CWait::OnInitDialog()
{
CDialogEx::OnInitDialog();
SetTimer(1, 1, NULL);
AfxGetMainWnd()->SetLayeredWindowAttributes(0, (255 * 70) / 100, LWA_ALPHA);//主視窗透明化
return TRUE; // return TRUE unless you set the focus to a control
// EXCEPTION: OCX 屬性頁應傳回 FALSE
}
void CWait::OnTimer(UINT_PTR nIDEvent)
{
#ifdef MOVE
if (!MO_ReadIsDriving(7))
{
AfxGetMainWnd()->SetLayeredWindowAttributes(0, (255 * 100) / 100, LWA_ALPHA);//主視窗恢復透明化
CDialogEx::OnOK();
}
#endif // MOVE
CDialogEx::OnTimer(nIDEvent);
}
void CWait::OnOK()
{
}
void CWait::OnCancel()
{
//CDialogEx::OnCancel();
}