You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

753 lines
23 KiB
C++

#include "stdafx.h"
#include "DlgDeviceMain.h"
#include "afxdialogex.h"
#include "CommonFlowMgr.h"
#include "LogMgr.h"
#include "AuthorityMgr.h"
#include "AllThreadMgr.h"
#include "CStringFuc.h"
#include "GlobalFunction.h"
#include "DlgChildWaferHistory.h"
#include "ProgramLaserTuiHuo.h"
#include "LogMgr.h"
#include "AuthorityMgr.h"
#include "WarningMgr.h"
#include "DlgChildRecipe.h"
#include "DlgAuthorityLogin.h"
#include "ProgramLaserTuiHuo.h"
#include "AllThreadMgr.h"
#include "LaiPuLaser.h"
#include "MyDlgView.h"
#include "EncryptionMgr.h"
#include "Laser.h"
#include "GlobalDrawMgr.h"
#include "LanguageMgr.h"
#include "CommonFlowMgr.h"
#include "MarkArea.h"
#include "FileMgr.h"
#include "WorkCmdInvoker.h"
#include "DlgChildEventLog.h"
#include "DlgChildDataAnalysis.h"
#include "DlgChildAlarmLog.h"
#include "DlgChildCheckHistory.h"
#include "DlgChildParaHistory.h"
#include "DlgChildRealTimeDataHistory.h"
#include "DlgChildBeamDataHistory.h"
#include "DlgChildConfigHistory.h"
#include "DlgAuthorityAccount.h"
#include "DlgChildLoginHistory.h"
#include "DlgChildJobHistory.h"
#define UPDATE_INFO_TIMER 1
#define UPDATE_INFO_TIMER_DELAY 1000
#define SET_DLG_SIZE_TIMER 2
#define SET_DLG_SIZE_TIMER_DELAY 500
#define ID_READ_LASER_DIS_METER_TIMER 3
#define SWITCH_DLG_TIMER 4
#define SWITCH_DLG_TIMER_DELAY 100
#define MAX_MODULE_CHILD_VIEW_CNT 12//<2F>ӽ<EFBFBD><D3BD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
#define UPDATE_DATE_TIMER 5
#define UPDATE_DATE_TIMER_DELAY 200
#define LAIPU_APP_WNDS_NAME "LaiPuLaser" //<2F><><EFBFBD>ҵĴ<D2B5><C4B4><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
HWND gLaipuAppHwnd = 0;
//<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ھ<EFBFBD><DABE><EFBFBD>,<2C><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ҫ<EFBFBD><D2AA><EFBFBD><EFBFBD><EFBFBD>ô<EFBFBD><C3B4>ڳ<EFBFBD><DAB3><EFBFBD>
BOOL CALLBACK EnumLaipuAppWnds( HWND hwnd, LPARAM lParam )
{
const int size1 = 1024;
char szClass[size1];
if( !GetWindow( hwnd, GW_OWNER ) && IsWindowVisible( hwnd ) ) // <20>˵<EFBFBD><CBB5><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʾ<EFBFBD>Ĵ<EFBFBD><C4B4><EFBFBD>
{
GetClassName( hwnd, szClass, size1 );
// <20>˵<EFBFBD><CBB5><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>// <20>˵<EFBFBD><CBB5><EFBFBD><EFBFBD><EFBFBD>
if( strcmp( szClass, "Shell_TrayWnd" ) != 0 && strcmp( szClass, "Progman" ) != 0 )
{
if(GetWindowLong(hwnd, GWL_EXSTYLE) & WS_EX_TOOLWINDOW)
{
return true;
}
char szTitle[size1];
GetWindowText( hwnd, szTitle,size1);
CString s(szTitle);
if(s.Find(_T(LAIPU_APP_WNDS_NAME), 0)!=-1)
{
gLaipuAppHwnd = hwnd;
}
}
}
return TRUE;
}
IMPLEMENT_DYNAMIC(CDlgDeviceMain, CMyDlgView)
BEGIN_MESSAGE_MAP(CDlgDeviceMain, CMyDlgView)
ON_WM_TIMER()
ON_BN_CLICKED(CHILD_DEVICE_STATE_BTN, &CDlgDeviceMain::OnBnClickedDeviceStateBtn)
ON_BN_CLICKED(CHILD_PCS_BTN, &CDlgDeviceMain::OnBnClickedPCS)
ON_BN_CLICKED(CHILD_LOGIN_BTN, &CDlgDeviceMain::OnBnClickedLoginBtn)
ON_BN_CLICKED(CHILD_RECORD_BTN, &CDlgDeviceMain::OnBnClickedRecordBtn)
ON_BN_CLICKED(CHILD_CONFIG_BTN, &CDlgDeviceMain::OnBnClickedConfigBtn)
ON_BN_CLICKED(CHILD_RECIPE_BTN, &CDlgDeviceMain::OnBnClickedRecipeBtn)
ON_BN_CLICKED(NEW_LOGO_BTN, &CDlgDeviceMain::OnBnClickedLogoBtn)
ON_BN_CLICKED(IDC_PCS_TEST_BTN, &CDlgDeviceMain::OnBnClickedPcsTestBtn)
ON_BN_CLICKED(NEW_SUB_MODULE_BTN1, &CDlgDeviceMain::OnBnClickedModuleChildViewBtn1)
ON_BN_CLICKED(NEW_SUB_MODULE_BTN2, &CDlgDeviceMain::OnBnClickedModuleChildViewBtn2)
ON_BN_CLICKED(NEW_SUB_MODULE_BTN3, &CDlgDeviceMain::OnBnClickedModuleChildViewBtn3)
ON_BN_CLICKED(NEW_SUB_MODULE_BTN4, &CDlgDeviceMain::OnBnClickedModuleChildViewBtn4)
ON_BN_CLICKED(NEW_SUB_MODULE_BTN5, &CDlgDeviceMain::OnBnClickedModuleChildViewBtn5)
ON_BN_CLICKED(NEW_SUB_MODULE_BTN6, &CDlgDeviceMain::OnBnClickedModuleChildViewBtn6)
ON_BN_CLICKED(NEW_SUB_MODULE_BTN7, &CDlgDeviceMain::OnBnClickedModuleChildViewBtn7)
ON_BN_CLICKED(NEW_SUB_MODULE_BTN8, &CDlgDeviceMain::OnBnClickedModuleChildViewBtn8)
ON_BN_CLICKED(NEW_SUB_MODULE_BTN9, &CDlgDeviceMain::OnBnClickedModuleChildViewBtn9)
ON_BN_CLICKED(NEW_SUB_MODULE_BTN10, &CDlgDeviceMain::OnBnClickedModuleChildViewBtn10)
ON_BN_CLICKED(NEW_SUB_MODULE_BTN11, &CDlgDeviceMain::OnBnClickedModuleChildViewBtn11)
ON_BN_CLICKED(NEW_SUB_MODULE_BTN12, &CDlgDeviceMain::OnBnClickedModuleChildViewBtn12)
ON_BN_CLICKED(CHILD_CLOSE_APP_BTN, &CDlgDeviceMain::OnBnClickedCloseAppBtn)
ON_BN_CLICKED(CHILD_SHOW_WINDOW_MIN_BTN, &CDlgDeviceMain::OnBnClickedShowWindowMinBtn)
ON_BN_CLICKED(CHILD_USER_MGR_BTN, &CDlgDeviceMain::OnBnClickedUserMgrBtn)
END_MESSAGE_MAP()
CDlgDeviceMain *gDlgDeviceMain = NULL;
CDlgDeviceMain::CDlgDeviceMain(CWnd* pParent /*=NULL*/)
: CMyDlgView(CDlgDeviceMain::IDD, pParent)
{
//m_TestStr1 = "33554431";
m_TestStr1 = "0";
m_WarningTimes = 0;//<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ʊ<EFBFBD><C6B1><EFBFBD>ʱ<EFBFBD><CAB1>ť<EFBFBD><C5A5>˸
for(int k=0;k<MAX_MODULE_CHILD_VIEW_CNT;k++)
{
m_ModuleChildViewVec.push_back(_ChildView_NULL);
}
}
CDlgDeviceMain::~CDlgDeviceMain()
{
KillTimer(ID_READ_LASER_DIS_METER_TIMER);
KillTimer(UPDATE_INFO_TIMER);
}
void CDlgDeviceMain::DoDataExchange(CDataExchange* pDX)
{
CDialogEx::DoDataExchange(pDX);
DDX_Control(pDX, IDC_EDIT_CHILD, m_EditChild);
DDX_Control(pDX, IDC_PCS_TEST_COMBO, m_PcsTestComb);
DDX_Text(pDX, IDC_PCS_TEST1_EDIT, m_TestStr1);
DDX_Text(pDX, IDC_PCS_TEST2_EDIT, m_TestStr2);
}
BOOL CDlgDeviceMain::OnInitDialog()
{
CMyDlgView::OnInitDialog();
// <20><>ʼ<EFBFBD><CABC><EFBFBD><EFBFBD><EFBFBD><EFBFBD>λ<EFBFBD><CEBB><EFBFBD><EFBFBD><EFBFBD><EFBFBD>С
InitChildArea();
UpdateData(FALSE);
gChildRecipe = new CDlgChildRecipe;
gChildRecipe->Create(gChildRecipe->GetIDD());
gChildWaferHistory = new CDlgChildWaferHistory;
gChildWaferHistory->Create(gChildWaferHistory->GetIDD());
gChildEventLog = new CDlgChildEventLog;
gChildEventLog->Create(gChildEventLog->GetIDD());
gChildAlarmLog = new CDlgChildAlarmLog;
gChildAlarmLog->Create(gChildAlarmLog->GetIDD());
gChildCheckHistory = new CDlgChildCheckHistory;
gChildCheckHistory->Create(gChildCheckHistory->GetIDD());
gDlgChildRealTimeDataHistory = new CDlgChildRealTimeDataHistory;
gDlgChildRealTimeDataHistory->Create(gDlgChildRealTimeDataHistory->GetIDD());
gDlgChildBeamDataHistory = new CDlgChildBeamDataHistory;
gDlgChildBeamDataHistory->Create(gDlgChildBeamDataHistory->GetIDD());
gDlgChildConfigHistory = new CDlgChildConfigHistory;
gDlgChildConfigHistory->Create(gDlgChildConfigHistory->GetIDD());
gChildParaHistory = new CDlgChildParaHistory;
gChildParaHistory->Create(gChildParaHistory->GetIDD());
gDlgChildLoginHistory = new CDlgChildLoginHistory;
gDlgChildLoginHistory->Create(gDlgChildLoginHistory->GetIDD());
gDlgChildJobHistory = new CDlgChildJobHistory;
gDlgChildJobHistory->Create(gDlgChildJobHistory->GetIDD());
Sleep(200);
SetActiveView(_ChildView_Recipe);
//<2F><><EFBFBD>öԻ<C3B6><D4BB><EFBFBD><EFBFBD>ijߴ<C4B3>
SetTimer(SET_DLG_SIZE_TIMER,SET_DLG_SIZE_TIMER_DELAY,NULL);
SetTimer(UPDATE_INFO_TIMER,UPDATE_INFO_TIMER_DELAY,NULL);
return TRUE;
}
//<2F><>ֹ<EFBFBD><D6B9><EFBFBD><EFBFBD>ر<EFBFBD>
void CDlgDeviceMain::OnCancel()
{
//CDialogEx::OnCancel();
}
void CDlgDeviceMain::OnTimer(UINT nIDEvent)
{
if(nIDEvent == UPDATE_INFO_TIMER)
{
KillTimer(UPDATE_INFO_TIMER);
UpdateInfoExt();
SetTimer(UPDATE_INFO_TIMER,UPDATE_INFO_TIMER_DELAY,NULL);
}
if(nIDEvent == SET_DLG_SIZE_TIMER)
{
KillTimer(SET_DLG_SIZE_TIMER);
SetWndSize();
}
if(nIDEvent == SWITCH_DLG_TIMER)
{
KillTimer(SWITCH_DLG_TIMER);
SetActiveView(m_SwitchChildViewType);
}
CDialog::OnTimer(nIDEvent);
}
//<2F><><EFBFBD>öԻ<C3B6><D4BB><EFBFBD><EFBFBD>Ĵ<EFBFBD>С
void CDlgDeviceMain::SetWndSize()
{
//<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
//GetFrame()->ShowWindowMin();
//Sleep(1000);
//<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
//GetFrame()->ShowWindowMax();
//Ĭ<><C4AC>ѡ<EFBFBD><D1A1>rcp<63><70><EFBFBD><EFBFBD>
//OnBnClickedRecipeBtn();
OnBnClickedRecordBtn();
//Ĭ<>ϵ<EFBFBD>¼<EFBFBD><C2BC><EFBFBD><EFBFBD>
if(!gAuthorityMgr->CheckAuthority(_Authority_Factory,false))
{
//OnBnClickedLoginBtn();//22-08-02
}
}
//<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E6B2BC>
void CDlgDeviceMain::AdjustLayout()
{
if(gEncryptionMgr->IsbRunAtNoteBook())
return;
int w = gDraw->GetDlgMainWidth();
//GetFrame()->m_DeviceMainPane.MoveWindow(CRect(35,0,w,1100),TRUE,NULL);
}
void CDlgDeviceMain::SetTextCtrlItemID()
{
}
void CDlgDeviceMain::UpdateLanguageTxt()
{
}
void CDlgDeviceMain::UpdateInfoExt()
{
if(gExitApp)
return;
//<2F>û<EFBFBD><C3BB><EFBFBD>
SetItemText(IDC_CUR_USER_NAME,gAuthorityMgr->GetCurUserName());
//<2F>˻<EFBFBD><CBBB><EFBFBD><EFBFBD><EFBFBD>
SetItemText(IDC_CUR_USER_AUTH,gAuthorityMgr->GetCurAccountName());
//<2F><><EFBFBD><EFBFBD><EFBFBD>
SetItemText(IDC_CUR_SOFT_VISION,gProgramLaserTuiHuo->GetCurSoftVision());
}
void CDlgDeviceMain::SwitchChildDlg(EChildViewType ViewType)
{
m_SwitchChildViewType = ViewType;//<2F>л<EFBFBD><D0BB><EFBFBD><EFBFBD>ӽ<EFBFBD><D3BD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
SetTimer(SWITCH_DLG_TIMER,SWITCH_DLG_TIMER_DELAY,NULL);
}
#if 1
// <20><>ʼ<EFBFBD><CABC><EFBFBD><EFBFBD><EFBFBD><EFBFBD>λ<EFBFBD><CEBB><EFBFBD><EFBFBD><EFBFBD><EFBFBD>С(<28><>Ҫ<EFBFBD>ȸ<EFBFBD>m_EditChild <20>󶨿ؼ<F3B6A8BF>)
void CDlgDeviceMain::InitChildArea()
{
//<2F><>һ<EFBFBD><D2BB>eidt <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ӽ<EFBFBD><D3BD><EFBFBD><EFBFBD>Ĵ<EFBFBD>С
m_EditChild.GetWindowRect(m_rChildRect);
CRect rect;
GetWindowRect(rect);
// <20><><EFBFBD><EFBFBD><E3B3A4>
m_rChildRect.bottom -= m_rChildRect.top;
m_rChildRect.right -= m_rChildRect.left;
// <20><><EFBFBD><EFBFBD>λ<EFBFBD><CEBB>
m_rChildRect.left -= rect.left;
m_rChildRect.top -= rect.top;
m_rChildRect.bottom += m_rChildRect.top;
m_rChildRect.right += m_rChildRect.left;
}
CString CDlgDeviceMain::GetModuleChildViewName(EChildViewType ChildViewType)
{
CString Name;
switch(ChildViewType)
{
case _ChildView_PCS:
Name = "Process";
break;
case _ChildView_WorkPrepare:
Name = "Work Prepare";
break;
case _ChildView_WorkWaferCnt:
Name = "Work Wafer Cnt";
break;
case _ChildView_Recipe:
Name = "Recipe<EFBFBD>";
break;
case _ChildView_RecipeScanAreaEdit:
Name = "ͼ<EFBFBD>α";
break;
case _ChildView_LaserPathState:
Name = "Laser Path State";
break;
case _ChildView_LaserDeviceState:
Name = "Laser Device State";
break;
case _ChildView_Robot:
Name = "Robot";
break;
case _ChildView_IOState:
Name = "IO State";
break;
case _ChildView_DeviceMaintenance:
Name = "Maintenance";
break;
case _ChildView_LaserPowCheck:
Name = "Laser Pow Check";
break;
case _ChildView_SysParaSet:
Name = "Sys Para Set";
break;
case _ChildView_EventLog:
Name = "Event";
break;
case _ChildView_AlarmLog:
Name = "Alarm History";
break;
case _ChildView_WaferHistory:
Name = "Wafer History";
break;
case _ChildView_CheckHistory:
Name = "Check History";
break;
case _ChildView_RealTimeDataHistory:
Name = "RealTime History";
break;
case _ChildView_BeamDataHistory:
Name = "BeamData History";
break;
case _ChildView_ConfigHistory:
Name = "Config History";
break;
case _ChildView_JobHistory:
Name = "Job History";
break;
case _ChildView_ParHistory:
Name = "Recipe History";
break;
case _ChildView_LoginHistory:
Name = "Login History";
break;
case _ChildView_DataAnalysis:
Name = "Data Analyse";
break;
default:
break;
}
return Name;
}
#endif
#if 1
//<2F><><EFBFBD><EFBFBD>lock ״̬<D7B4>ı<EFBFBD>
void CDlgDeviceMain::ChangeItemState()
{
ChangeItemStateExt();
gChildPCS->ChangeItemState();
gChildLaserPathState->ChangeItemState();
gChildWaferHistory->ChangeItemState();
gChildCheckHistory->ChangeItemState();
gDlgChildRealTimeDataHistory->ChangeItemState();
gDlgChildBeamDataHistory->ChangeItemState();
gDlgChildConfigHistory->ChangeItemState();
gChildSysParaSet->ChangeItemState();
gChildRecipe->ChangeItemState();
gChildIOState->ChangeItemState();
gChildParaHistory->ChangeItemState();
gDlgChildLoginHistory->ChangeItemState();
gDlgChildJobHistory->ChangeItemState();
}
void CDlgDeviceMain::ChangeItemStateExt()
{
}
#endif
#if 1//<2F><><EFBFBD><EFBFBD><EFBFBD>л<EFBFBD>
void CDlgDeviceMain::ResetModuleChildView()
{
for(int k=0;k<MAX_MODULE_CHILD_VIEW_CNT;k++)
{
m_ModuleChildViewVec[k] = _ChildView_NULL;
}
}
//<2F><><EFBFBD><EFBFBD>ģ<EFBFBD><C4A3><EFBFBD>ӽ<EFBFBD><D3BD><EFBFBD>
void CDlgDeviceMain::UpdateModuleChildView()
{
COLORREF BkColor = RGB_BLACK;
int BtnId = 0;
for(int k=0;k<MAX_MODULE_CHILD_VIEW_CNT;k++)
{
CString ChildViewName = GetModuleChildViewName(m_ModuleChildViewVec[k]);
switch(k)
{
case 0:
BtnId = NEW_SUB_MODULE_BTN1;
break;
case 1:
BtnId = NEW_SUB_MODULE_BTN2;
break;
case 2:
BtnId = NEW_SUB_MODULE_BTN3;
break;
case 3:
BtnId = NEW_SUB_MODULE_BTN4;
break;
case 4:
BtnId = NEW_SUB_MODULE_BTN5;
break;
case 5:
BtnId = NEW_SUB_MODULE_BTN6;
break;
case 6:
BtnId = NEW_SUB_MODULE_BTN7;
break;
case 7:
BtnId = NEW_SUB_MODULE_BTN8;
break;
case 8:
BtnId = NEW_SUB_MODULE_BTN9;
break;
case 9:
BtnId = NEW_SUB_MODULE_BTN10;
break;
case 10:
BtnId = NEW_SUB_MODULE_BTN11;
break;
case 11:
BtnId = NEW_SUB_MODULE_BTN12;
break;
default:
break;
}
GetDlgItem(BtnId)->SetWindowText(ChildViewName);
if(ChildViewName!="")
GetDlgItem(BtnId)->ShowWindow(SW_SHOW);
else
GetDlgItem(BtnId)->ShowWindow(SW_HIDE);
}
//Ĭ<><C4AC>ѡ<EFBFBD><D1A1><EFBFBD><EFBFBD>һ<EFBFBD><D2BB>View
if(!m_ModuleChildViewVec.empty())
SetActiveView(m_ModuleChildViewVec[0]);
}
void CDlgDeviceMain::OnBnClickedPCS()
{
gLogMgr->WriteDebugLog("Func---->OnBnClickedPCS");
ResetModuleChildView();
int idx = 0;
m_ModuleChildViewVec[idx++] = _ChildView_PCS;
m_ModuleChildViewVec[idx++] = _ChildView_WorkPrepare;
m_ModuleChildViewVec[idx++] = _ChildView_WorkWaferCnt;
UpdateModuleChildView();
}
void CDlgDeviceMain::OnBnClickedRecipeBtn()
{
gLogMgr->WriteDebugLog("Func---->OnBnClickedRecipeBtn");
ResetModuleChildView();
int idx = 0;
m_ModuleChildViewVec[idx++] = _ChildView_Recipe;
m_ModuleChildViewVec[idx++] = _ChildView_RecipeScanAreaEdit;
UpdateModuleChildView();
}
void CDlgDeviceMain::OnBnClickedDeviceStateBtn()
{
gLogMgr->WriteDebugLog("Func---->OnBnClickedDeviceStateBtn");
ResetModuleChildView();
int idx = 0;
m_ModuleChildViewVec[idx++] = _ChildView_LaserPathState;
m_ModuleChildViewVec[idx++] = _ChildView_LaserDeviceState;
m_ModuleChildViewVec[idx++] = _ChildView_Robot;
m_ModuleChildViewVec[idx++] = _ChildView_IOState;
UpdateModuleChildView();
}
void CDlgDeviceMain::OnBnClickedRecordBtn()
{
gLogMgr->WriteDebugLog("Func---->OnBnClickedRecordBtn");
ResetModuleChildView();
int idx = 0;
m_ModuleChildViewVec[idx++] = _ChildView_EventLog;
m_ModuleChildViewVec[idx++] = _ChildView_WaferHistory;
m_ModuleChildViewVec[idx++] = _ChildView_CheckHistory;
m_ModuleChildViewVec[idx++] = _ChildView_ParHistory;
m_ModuleChildViewVec[idx++] = _ChildView_RealTimeDataHistory;
m_ModuleChildViewVec[idx++] = _ChildView_BeamDataHistory;
m_ModuleChildViewVec[idx++] = _ChildView_ConfigHistory;
m_ModuleChildViewVec[idx++] = _ChildView_AlarmLog;
m_ModuleChildViewVec[idx++] = _ChildView_LoginHistory;
m_ModuleChildViewVec[idx++] = _ChildView_JobHistory;
//m_ModuleChildViewVec[idx++] = _ChildView_DataAnalysis;
UpdateModuleChildView();
}
void CDlgDeviceMain::OnBnClickedModuleChildViewBtn1()
{
gLogMgr->WriteDebugLog("Func---->OnBnClickedModuleChildViewBtn1");
SetActiveView(m_ModuleChildViewVec[0]);
}
void CDlgDeviceMain::OnBnClickedModuleChildViewBtn2()
{
gLogMgr->WriteDebugLog("Func---->OnBnClickedModuleChildViewBtn2");
if(_ChildView_RecipeScanAreaEdit == m_ModuleChildViewVec[1])
{
if(!gAuthorityMgr->CheckAuthorityByName("AUTHORITY_EditScanArea",true))
return;
GetFrame()->m_DlgGraphEdit.ShowAllItem();
//<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>༭ͼ<E0BCAD><CDBC>
ShowWindow(SW_HIDE);
}
else
{
SetActiveView(m_ModuleChildViewVec[1]);
}
}
void CDlgDeviceMain::OnBnClickedModuleChildViewBtn3()
{
gLogMgr->WriteDebugLog("Func---->OnBnClickedModuleChildViewBtn3");
SetActiveView(m_ModuleChildViewVec[2]);
}
void CDlgDeviceMain::OnBnClickedModuleChildViewBtn4()
{
gLogMgr->WriteDebugLog("Func---->OnBnClickedModuleChildViewBtn4");
SetActiveView(m_ModuleChildViewVec[3]);
}
void CDlgDeviceMain::OnBnClickedModuleChildViewBtn5()
{
gLogMgr->WriteDebugLog("Func---->OnBnClickedModuleChildViewBtn5");
SetActiveView(m_ModuleChildViewVec[4]);
}
void CDlgDeviceMain::OnBnClickedModuleChildViewBtn6()
{
gLogMgr->WriteDebugLog("Func---->OnBnClickedModuleChildViewBtn6");
SetActiveView(m_ModuleChildViewVec[5]);
}
void CDlgDeviceMain::OnBnClickedModuleChildViewBtn7()
{
gLogMgr->WriteDebugLog("Func---->OnBnClickedModuleChildViewBtn7");
SetActiveView(m_ModuleChildViewVec[6]);
}
void CDlgDeviceMain::OnBnClickedModuleChildViewBtn8()
{
gLogMgr->WriteDebugLog("Func---->OnBnClickedModuleChildViewBtn8");
SetActiveView(m_ModuleChildViewVec[7]);
}
void CDlgDeviceMain::OnBnClickedModuleChildViewBtn9()
{
gLogMgr->WriteDebugLog("Func---->OnBnClickedModuleChildViewBtn9");
SetActiveView(m_ModuleChildViewVec[8]);
}
void CDlgDeviceMain::OnBnClickedModuleChildViewBtn10()
{
gLogMgr->WriteDebugLog("Func---->OnBnClickedModuleChildViewBtn10");
SetActiveView(m_ModuleChildViewVec[9]);
}
void CDlgDeviceMain::OnBnClickedModuleChildViewBtn11()
{
gLogMgr->WriteDebugLog("Func---->OnBnClickedModuleChildViewBtn11");
SetActiveView(m_ModuleChildViewVec[10]);
}
void CDlgDeviceMain::OnBnClickedModuleChildViewBtn12()
{
gLogMgr->WriteDebugLog("Func---->OnBnClickedModuleChildViewBtn12");
SetActiveView(m_ModuleChildViewVec[11]);
}
#endif
#if 1
#define PCS_TEST_FUNC1 "test <20><><EFBFBD><EFBFBD>"
#define PCS_TEST_FUNC2 "Init Port1 Wafer State"
#define PCS_TEST_FUNC3 "Init Port2 Wafer State"
#define PCS_TEST_FUNC4 "xxxxxxxxxxxxx"
#define PCS_TEST_FUNC5 "xxxxxxxxxxxxx"
#define PCS_TEST_FUNC6 "xxxxxxxxxxxxx"
#define PCS_TEST_FUNC7 "xxxxxxxxxxxxx"
#define PCS_TEST_FUNC8 "xxxxxxxxxxxxx"
#define PCS_TEST_FUNC9 "xxxxxxxxxxxxx"
#define PCS_TEST_FUNC10 "xxxxxxxxxxxxx"
#define PCS_TEST_FUNC11 "xxxxxxxxxxxxx"
#define PCS_TEST_FUNC12 "xxxxxxxxxxxxx"
#define PCS_TEST_FUNC13 "AREA<45>༭"
#define PCS_TEST_FUNC14 "xxxxxxxxxxxxx"
#define PCS_TEST_FUNC15 "xxxxxxxxxxxxx"
#define PCS_TEST_FUNC16 "xxxxxxxxxxxxx"
void CDlgDeviceMain::InitPcsTestComb()
{
int Idx = 0;
m_PcsTestComb.InsertString(Idx++,PCS_TEST_FUNC1);
m_PcsTestComb.InsertString(Idx++,PCS_TEST_FUNC2);
m_PcsTestComb.InsertString(Idx++,PCS_TEST_FUNC3);
m_PcsTestComb.InsertString(Idx++,PCS_TEST_FUNC4);
m_PcsTestComb.InsertString(Idx++,PCS_TEST_FUNC5);
m_PcsTestComb.InsertString(Idx++,PCS_TEST_FUNC6);
m_PcsTestComb.InsertString(Idx++,PCS_TEST_FUNC7);
m_PcsTestComb.InsertString(Idx++,PCS_TEST_FUNC8);
m_PcsTestComb.InsertString(Idx++,PCS_TEST_FUNC9);
m_PcsTestComb.InsertString(Idx++,PCS_TEST_FUNC10);
m_PcsTestComb.InsertString(Idx++,PCS_TEST_FUNC11);
m_PcsTestComb.InsertString(Idx++,PCS_TEST_FUNC12);
m_PcsTestComb.InsertString(Idx++,PCS_TEST_FUNC13);
m_PcsTestComb.InsertString(Idx++,PCS_TEST_FUNC14);
m_PcsTestComb.InsertString(Idx++,PCS_TEST_FUNC15);
m_PcsTestComb.InsertString(Idx++,PCS_TEST_FUNC16);
}
//<2F><><EFBFBD>Թ<EFBFBD><D4B9><EFBFBD>
void CDlgDeviceMain::OnBnClickedPcsTestBtn()
{
if(gAuthorityMgr->CheckAuthority(_Authority_Factory,true)==false)
return;
if(!UpdateData(TRUE))
return;
vector<double> DBValVec;
CFileMgr FileMgr;
FileMgr.GetDoubleVal(m_TestStr1,DBValVec);
CString CombStr;
GetDlgItem(IDC_PCS_TEST_COMBO)->GetWindowText(CombStr);
if(CombStr==PCS_TEST_FUNC1)
{
ShowWindow(SW_HIDE);
}
if(CombStr==PCS_TEST_FUNC2)
{
}
if(CombStr==PCS_TEST_FUNC3)
{
}
if(CombStr==PCS_TEST_FUNC4)
{
}
if(CombStr==PCS_TEST_FUNC5)
{
}
if(CombStr==PCS_TEST_FUNC6)
{
}
if(CombStr==PCS_TEST_FUNC7)
{
}
if(CombStr==PCS_TEST_FUNC8)
{
}
if(CombStr==PCS_TEST_FUNC9)
{
}
if(CombStr==PCS_TEST_FUNC10)
{
}
if(CombStr==PCS_TEST_FUNC11)
{
}
if(CombStr==PCS_TEST_FUNC12)
{
}
if(CombStr==PCS_TEST_FUNC13)
{
}
if(CombStr==PCS_TEST_FUNC14)
{
}
if(CombStr==PCS_TEST_FUNC15)
{
}
if(CombStr==PCS_TEST_FUNC16)
{
}
}
#endif
void CDlgDeviceMain::OnBnClickedCloseAppBtn()
{
if(!gAuthorityMgr->CheckAuthorityByName("AUTHORITY_CloseApp",true))
return;
gProgramLaserTuiHuo->CloseAppBySysMsg();
}
void CDlgDeviceMain::OnBnClickedConfigBtn()
{
gLogMgr->WriteDebugLog("Func---->OnBnClickedReStatrBtn");
gProgramLaserTuiHuo->ReStartApp();
}
void CDlgDeviceMain::OnBnClickedShowWindowMinBtn()
{
gLogMgr->WriteDebugLog("Func---->OnBnClickedShowWindowMinBtn");
GetFrame()->ShowWindowMin();
}
//<2F>û<EFBFBD><C3BB><EFBFBD><EFBFBD><EFBFBD>
void CDlgDeviceMain::OnBnClickedUserMgrBtn()
{
gLogMgr->WriteDebugLog("Func---->OnBnClickedUserMgrBtn");
if(!gAuthorityMgr->CheckAuthorityByName("AUTHORITY_UserEdit",true))
return;
CDlgAuthorityAccount dlg;
dlg.DoModal();
}
//<2F><>¼<EFBFBD><C2BC><EFBFBD><EFBFBD>
void CDlgDeviceMain::OnBnClickedLoginBtn()
{
gLogMgr->WriteDebugLog("Func---->OnBnClickedLoginBtn");
CDlgAuthorityLogin dlg;
dlg.DoModal();
}
void CDlgDeviceMain::OnBnClickedLogoBtn()
{
}