97 lines
2.6 KiB
C++
97 lines
2.6 KiB
C++
// LS_launcher.cpp : Defines the class behaviors for the application.
|
|
//
|
|
|
|
#include "stdafx.h"
|
|
#include "LS_launcher.h"
|
|
#include "LS_launcherDlg.h"
|
|
#include <string>
|
|
|
|
#ifdef _DEBUG
|
|
#define new DEBUG_NEW
|
|
#endif
|
|
|
|
// CLS_LauncherApp
|
|
|
|
BEGIN_MESSAGE_MAP(CLS_LauncherApp, CWinApp)
|
|
//ON_COMMAND(ID_HELP, &CWinApp::OnHelp)
|
|
END_MESSAGE_MAP()
|
|
|
|
|
|
// CLS_LauncherApp construction
|
|
|
|
CLS_LauncherApp::CLS_LauncherApp()
|
|
{
|
|
// TODO: add construction code here,
|
|
// Place all significant initialization in InitInstance
|
|
}
|
|
|
|
|
|
// The one and only CLS_LauncherApp object
|
|
|
|
CLS_LauncherApp theApp;
|
|
|
|
// CLS_LauncherApp initialization
|
|
BOOL CLS_LauncherApp::InitInstance()
|
|
{
|
|
MiniDump::Begin(_T("Lostsaga Luncher"));
|
|
// InitCommonControlsEx() is required on Windows XP if an application
|
|
// manifest specifies use of ComCtl32.dll version 6 or later to enable
|
|
// visual styles. Otherwise, any window creation will fail.
|
|
INITCOMMONCONTROLSEX InitCtrls;
|
|
InitCtrls.dwSize = sizeof(InitCtrls);
|
|
// Set this to include all the common control classes you want to use
|
|
// in your application.
|
|
InitCtrls.dwICC = ICC_WIN95_CLASSES;
|
|
InitCommonControlsEx(&InitCtrls);
|
|
|
|
CWinApp::InitInstance();
|
|
|
|
if (!AfxSocketInit())
|
|
{
|
|
MessageBox(NULL, _T("AfxSocketInit failed"), _T("Error"), MB_OK);
|
|
return FALSE;
|
|
}
|
|
|
|
AfxEnableControlContainer();
|
|
|
|
// Standard initialization
|
|
// If you are not using these features and wish to reduce the size
|
|
// of your final executable, you should remove from the following
|
|
// the specific initialization routines you do not need
|
|
// Change the registry key under which our settings are stored
|
|
// TODO: You should modify this string to be something appropriate
|
|
// such as the name of your company or organization
|
|
SetRegistryKey(_T("Local AppWizard-Generated Applications"));
|
|
|
|
//server, batch read
|
|
//_fgetts(m_lpCmdLine,MAX_PATH,stdin);
|
|
//m_lpCmdLine[_tcslen(m_lpCmdLine)-1] = NULL;
|
|
|
|
CLS_launcherDlg dlg(m_lpCmdLine);
|
|
|
|
|
|
m_pMainWnd = &dlg;
|
|
INT_PTR nResponse = dlg.DoModal();
|
|
if (nResponse == IDOK)
|
|
{
|
|
// TODO: Place code here to handle when the dialog is
|
|
// dismissed with OK
|
|
}
|
|
else if (nResponse == IDCANCEL)
|
|
{
|
|
// TODO: Place code here to handle when the dialog is
|
|
// dismissed with Cancel
|
|
}
|
|
// Since the dialog has been closed, return FALSE so that we exit the
|
|
// application, rather than start the application's message pump.
|
|
return FALSE;
|
|
}
|
|
|
|
|
|
int CLS_LauncherApp::ExitInstance()
|
|
{
|
|
// TODO: 여기에 특수화된 코드를 추가 및/또는 기본 클래스를 호출합니다.
|
|
MiniDump::End();
|
|
return CWinApp::ExitInstance();
|
|
}
|