mirror of
https://github.com/electronicarts/CnC_Renegade.git
synced 2025-12-16 07:31:40 -05:00
Initial commit of Command & Conquer Renegade source code.
This commit is contained in:
99
Code/Tools/W3DUpdate/FileCopyDialog.cpp
Normal file
99
Code/Tools/W3DUpdate/FileCopyDialog.cpp
Normal file
@@ -0,0 +1,99 @@
|
||||
/*
|
||||
** Command & Conquer Renegade(tm)
|
||||
** Copyright 2025 Electronic Arts Inc.
|
||||
**
|
||||
** This program is free software: you can redistribute it and/or modify
|
||||
** it under the terms of the GNU General Public License as published by
|
||||
** the Free Software Foundation, either version 3 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
// FileCopyDialog.cpp : implementation file
|
||||
//
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "W3DUpdate.h"
|
||||
#include "FileCopyDialog.h"
|
||||
|
||||
#ifdef _DEBUG
|
||||
#define new DEBUG_NEW
|
||||
#undef THIS_FILE
|
||||
static char THIS_FILE[] = __FILE__;
|
||||
#endif
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// FileCopyDialogClass dialog
|
||||
|
||||
|
||||
FileCopyDialogClass::FileCopyDialogClass(CWnd* pParent /*=NULL*/)
|
||||
: CDialog(FileCopyDialogClass::IDD, pParent)
|
||||
{
|
||||
//{{AFX_DATA_INIT(FileCopyDialogClass)
|
||||
// NOTE: the ClassWizard will add member initialization here
|
||||
//}}AFX_DATA_INIT
|
||||
}
|
||||
|
||||
|
||||
void FileCopyDialogClass::DoDataExchange(CDataExchange* pDX)
|
||||
{
|
||||
CDialog::DoDataExchange(pDX);
|
||||
//{{AFX_DATA_MAP(FileCopyDialogClass)
|
||||
DDX_Control(pDX, IDC_ANIMATE_CTRL, m_AnimateCtrl);
|
||||
//}}AFX_DATA_MAP
|
||||
}
|
||||
|
||||
|
||||
BEGIN_MESSAGE_MAP(FileCopyDialogClass, CDialog)
|
||||
//{{AFX_MSG_MAP(FileCopyDialogClass)
|
||||
//}}AFX_MSG_MAP
|
||||
END_MESSAGE_MAP()
|
||||
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// WindowProc
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
LRESULT
|
||||
FileCopyDialogClass::WindowProc
|
||||
(
|
||||
UINT message,
|
||||
WPARAM wParam,
|
||||
LPARAM lParam
|
||||
)
|
||||
{
|
||||
if (message == WM_USER + 101) {
|
||||
EndDialog (TRUE);
|
||||
}
|
||||
|
||||
return CDialog::WindowProc(message, wParam, lParam);
|
||||
}
|
||||
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// OnInitDialog
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
BOOL
|
||||
FileCopyDialogClass::OnInitDialog (void)
|
||||
{
|
||||
CDialog::OnInitDialog();
|
||||
|
||||
CString app_title;
|
||||
app_title.Format ("Application: %s", m_AppTitle);
|
||||
SetDlgItemText (IDC_CURRENT_APP, app_title);
|
||||
|
||||
m_AnimateCtrl.Open (IDR_FILECOPY_AVI);
|
||||
|
||||
return TRUE; // return TRUE unless you set the focus to a control
|
||||
// EXCEPTION: OCX Property Pages should return FALSE
|
||||
}
|
||||
72
Code/Tools/W3DUpdate/FileCopyDialog.h
Normal file
72
Code/Tools/W3DUpdate/FileCopyDialog.h
Normal file
@@ -0,0 +1,72 @@
|
||||
/*
|
||||
** Command & Conquer Renegade(tm)
|
||||
** Copyright 2025 Electronic Arts Inc.
|
||||
**
|
||||
** This program is free software: you can redistribute it and/or modify
|
||||
** it under the terms of the GNU General Public License as published by
|
||||
** the Free Software Foundation, either version 3 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#if !defined(AFX_FILECOPYDIALOG_H__4305AC5C_1EAB_11D3_A038_00104B791122__INCLUDED_)
|
||||
#define AFX_FILECOPYDIALOG_H__4305AC5C_1EAB_11D3_A038_00104B791122__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
// FileCopyDialog.h : header file
|
||||
//
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// FileCopyDialogClass dialog
|
||||
|
||||
class FileCopyDialogClass : public CDialog
|
||||
{
|
||||
// Construction
|
||||
public:
|
||||
FileCopyDialogClass(CWnd* pParent = NULL); // standard constructor
|
||||
|
||||
// Dialog Data
|
||||
//{{AFX_DATA(FileCopyDialogClass)
|
||||
enum { IDD = IDD_FILE_COPY };
|
||||
CAnimateCtrl m_AnimateCtrl;
|
||||
//}}AFX_DATA
|
||||
|
||||
|
||||
// Overrides
|
||||
// ClassWizard generated virtual function overrides
|
||||
//{{AFX_VIRTUAL(FileCopyDialogClass)
|
||||
protected:
|
||||
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
|
||||
virtual LRESULT WindowProc(UINT message, WPARAM wParam, LPARAM lParam);
|
||||
//}}AFX_VIRTUAL
|
||||
|
||||
// Implementation
|
||||
protected:
|
||||
|
||||
// Generated message map functions
|
||||
//{{AFX_MSG(FileCopyDialogClass)
|
||||
virtual BOOL OnInitDialog();
|
||||
//}}AFX_MSG
|
||||
DECLARE_MESSAGE_MAP()
|
||||
|
||||
public:
|
||||
void Set_Current_File (LPCTSTR filename) { if (m_hWnd != NULL) SetDlgItemText (IDC_FILENAME_TEXT, filename); }
|
||||
void Set_Current_Application (LPCTSTR filename) { m_AppTitle = filename; }
|
||||
|
||||
private:
|
||||
CString m_AppTitle;
|
||||
};
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_FILECOPYDIALOG_H__4305AC5C_1EAB_11D3_A038_00104B791122__INCLUDED_)
|
||||
26
Code/Tools/W3DUpdate/StdAfx.cpp
Normal file
26
Code/Tools/W3DUpdate/StdAfx.cpp
Normal file
@@ -0,0 +1,26 @@
|
||||
/*
|
||||
** Command & Conquer Renegade(tm)
|
||||
** Copyright 2025 Electronic Arts Inc.
|
||||
**
|
||||
** This program is free software: you can redistribute it and/or modify
|
||||
** it under the terms of the GNU General Public License as published by
|
||||
** the Free Software Foundation, either version 3 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
// stdafx.cpp : source file that includes just the standard includes
|
||||
// W3DUpdate.pch will be the pre-compiled header
|
||||
// stdafx.obj will contain the pre-compiled type information
|
||||
|
||||
#include "stdafx.h"
|
||||
|
||||
|
||||
|
||||
44
Code/Tools/W3DUpdate/StdAfx.h
Normal file
44
Code/Tools/W3DUpdate/StdAfx.h
Normal file
@@ -0,0 +1,44 @@
|
||||
/*
|
||||
** Command & Conquer Renegade(tm)
|
||||
** Copyright 2025 Electronic Arts Inc.
|
||||
**
|
||||
** This program is free software: you can redistribute it and/or modify
|
||||
** it under the terms of the GNU General Public License as published by
|
||||
** the Free Software Foundation, either version 3 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
// stdafx.h : include file for standard system include files,
|
||||
// or project specific include files that are used frequently, but
|
||||
// are changed infrequently
|
||||
//
|
||||
|
||||
#if !defined(AFX_STDAFX_H__4305AC52_1EAB_11D3_A038_00104B791122__INCLUDED_)
|
||||
#define AFX_STDAFX_H__4305AC52_1EAB_11D3_A038_00104B791122__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
|
||||
#define VC_EXTRALEAN // Exclude rarely-used stuff from Windows headers
|
||||
|
||||
#include <afxwin.h> // MFC core and standard components
|
||||
#include <afxext.h> // MFC extensions
|
||||
#include <afxdtctl.h> // MFC support for Internet Explorer 4 Common Controls
|
||||
#ifndef _AFX_NO_AFXCMN_SUPPORT
|
||||
#include <afxcmn.h> // MFC support for Windows Common Controls
|
||||
#endif // _AFX_NO_AFXCMN_SUPPORT
|
||||
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_STDAFX_H__4305AC52_1EAB_11D3_A038_00104B791122__INCLUDED_)
|
||||
90
Code/Tools/W3DUpdate/W3DUpdate.cpp
Normal file
90
Code/Tools/W3DUpdate/W3DUpdate.cpp
Normal file
@@ -0,0 +1,90 @@
|
||||
/*
|
||||
** Command & Conquer Renegade(tm)
|
||||
** Copyright 2025 Electronic Arts Inc.
|
||||
**
|
||||
** This program is free software: you can redistribute it and/or modify
|
||||
** it under the terms of the GNU General Public License as published by
|
||||
** the Free Software Foundation, either version 3 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
// W3DUpdate.cpp : Defines the class behaviors for the application.
|
||||
//
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "W3DUpdate.h"
|
||||
#include "W3DUpdateDlg.h"
|
||||
|
||||
#ifdef _DEBUG
|
||||
#define new DEBUG_NEW
|
||||
#undef THIS_FILE
|
||||
static char THIS_FILE[] = __FILE__;
|
||||
#endif
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CW3DUpdateApp
|
||||
|
||||
BEGIN_MESSAGE_MAP(CW3DUpdateApp, CWinApp)
|
||||
//{{AFX_MSG_MAP(CW3DUpdateApp)
|
||||
// NOTE - the ClassWizard will add and remove mapping macros here.
|
||||
// DO NOT EDIT what you see in these blocks of generated code!
|
||||
//}}AFX_MSG
|
||||
ON_COMMAND(ID_HELP, CWinApp::OnHelp)
|
||||
END_MESSAGE_MAP()
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CW3DUpdateApp construction
|
||||
|
||||
CW3DUpdateApp::CW3DUpdateApp()
|
||||
{
|
||||
// TODO: add construction code here,
|
||||
// Place all significant initialization in InitInstance
|
||||
}
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// The one and only CW3DUpdateApp object
|
||||
|
||||
CW3DUpdateApp theApp;
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CW3DUpdateApp initialization
|
||||
|
||||
BOOL CW3DUpdateApp::InitInstance()
|
||||
{
|
||||
// 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.
|
||||
|
||||
#ifdef _AFXDLL
|
||||
Enable3dControls(); // Call this when using MFC in a shared DLL
|
||||
#else
|
||||
Enable3dControlsStatic(); // Call this when linking to MFC statically
|
||||
#endif
|
||||
|
||||
CW3DUpdateDlg dlg;
|
||||
m_pMainWnd = &dlg;
|
||||
int 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;
|
||||
}
|
||||
163
Code/Tools/W3DUpdate/W3DUpdate.dsp
Normal file
163
Code/Tools/W3DUpdate/W3DUpdate.dsp
Normal file
@@ -0,0 +1,163 @@
|
||||
# Microsoft Developer Studio Project File - Name="W3DUpdate" - Package Owner=<4>
|
||||
# Microsoft Developer Studio Generated Build File, Format Version 6.00
|
||||
# ** DO NOT EDIT **
|
||||
|
||||
# TARGTYPE "Win32 (x86) Application" 0x0101
|
||||
|
||||
CFG=W3DUpdate - Win32 Debug
|
||||
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
|
||||
!MESSAGE use the Export Makefile command and run
|
||||
!MESSAGE
|
||||
!MESSAGE NMAKE /f "W3DUpdate.mak".
|
||||
!MESSAGE
|
||||
!MESSAGE You can specify a configuration when running NMAKE
|
||||
!MESSAGE by defining the macro CFG on the command line. For example:
|
||||
!MESSAGE
|
||||
!MESSAGE NMAKE /f "W3DUpdate.mak" CFG="W3DUpdate - Win32 Debug"
|
||||
!MESSAGE
|
||||
!MESSAGE Possible choices for configuration are:
|
||||
!MESSAGE
|
||||
!MESSAGE "W3DUpdate - Win32 Release" (based on "Win32 (x86) Application")
|
||||
!MESSAGE "W3DUpdate - Win32 Debug" (based on "Win32 (x86) Application")
|
||||
!MESSAGE
|
||||
|
||||
# Begin Project
|
||||
# PROP AllowPerConfigDependencies 0
|
||||
# PROP Scc_ProjName ""$/Commando/Code/Tools/W3DUpdate", BFWBAAAA"
|
||||
# PROP Scc_LocalPath "."
|
||||
CPP=snCl.exe
|
||||
MTL=midl.exe
|
||||
RSC=rc.exe
|
||||
|
||||
!IF "$(CFG)" == "W3DUpdate - Win32 Release"
|
||||
|
||||
# PROP BASE Use_MFC 5
|
||||
# PROP BASE Use_Debug_Libraries 0
|
||||
# PROP BASE Output_Dir "Release"
|
||||
# PROP BASE Intermediate_Dir "Release"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_MFC 5
|
||||
# PROP Use_Debug_Libraries 0
|
||||
# PROP Output_Dir "Release"
|
||||
# PROP Intermediate_Dir "Release"
|
||||
# PROP Target_Dir ""
|
||||
# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /Yu"stdafx.h" /FD /c
|
||||
# ADD CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /FR /Yu"stdafx.h" /FD /c
|
||||
# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
|
||||
# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
|
||||
# ADD BASE RSC /l 0x409 /d "NDEBUG"
|
||||
# ADD RSC /l 0x409 /d "NDEBUG"
|
||||
BSC32=bscmake.exe
|
||||
# ADD BASE BSC32 /nologo
|
||||
# ADD BSC32 /nologo
|
||||
LINK32=snLink.exe
|
||||
# ADD BASE LINK32 /nologo /subsystem:windows /machine:I386
|
||||
# ADD LINK32 /nologo /subsystem:windows /machine:I386
|
||||
|
||||
!ELSEIF "$(CFG)" == "W3DUpdate - Win32 Debug"
|
||||
|
||||
# PROP BASE Use_MFC 5
|
||||
# PROP BASE Use_Debug_Libraries 1
|
||||
# PROP BASE Output_Dir "Debug"
|
||||
# PROP BASE Intermediate_Dir "Debug"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_MFC 5
|
||||
# PROP Use_Debug_Libraries 1
|
||||
# PROP Output_Dir "Debug"
|
||||
# PROP Intermediate_Dir "Debug"
|
||||
# PROP Ignore_Export_Lib 0
|
||||
# PROP Target_Dir ""
|
||||
# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /Yu"stdafx.h" /FD /GZ /c
|
||||
# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /FR /Yu"stdafx.h" /FD /GZ /c
|
||||
# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
|
||||
# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
|
||||
# ADD BASE RSC /l 0x409 /d "_DEBUG"
|
||||
# ADD RSC /l 0x409 /d "_DEBUG"
|
||||
BSC32=bscmake.exe
|
||||
# ADD BASE BSC32 /nologo
|
||||
# ADD BSC32 /nologo
|
||||
LINK32=snLink.exe
|
||||
# ADD BASE LINK32 /nologo /subsystem:windows /debug /machine:I386
|
||||
# ADD LINK32 /nologo /base:"" /subsystem:windows /debug /machine:I386
|
||||
|
||||
!ENDIF
|
||||
|
||||
# Begin Target
|
||||
|
||||
# Name "W3DUpdate - Win32 Release"
|
||||
# Name "W3DUpdate - Win32 Debug"
|
||||
# Begin Group "Source Files"
|
||||
|
||||
# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\FileCopyDialog.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\StdAfx.cpp
|
||||
# ADD CPP /Yc"stdafx.h"
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\W3DUpdate.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\W3DUpdate.rc
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\W3DUpdateDlg.cpp
|
||||
# End Source File
|
||||
# End Group
|
||||
# Begin Group "Header Files"
|
||||
|
||||
# PROP Default_Filter "h;hpp;hxx;hm;inl"
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\FileCopyDialog.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\Resource.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\StdAfx.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\W3DUpdate.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\W3DUpdateDlg.h
|
||||
# End Source File
|
||||
# End Group
|
||||
# Begin Group "Resource Files"
|
||||
|
||||
# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\res\icon1.ico
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\res\W3DUpdate.ico
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\res\W3DUpdate.rc2
|
||||
# End Source File
|
||||
# End Group
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\res\Filecopy.avi
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\ReadMe.txt
|
||||
# End Source File
|
||||
# End Target
|
||||
# End Project
|
||||
67
Code/Tools/W3DUpdate/W3DUpdate.h
Normal file
67
Code/Tools/W3DUpdate/W3DUpdate.h
Normal file
@@ -0,0 +1,67 @@
|
||||
/*
|
||||
** Command & Conquer Renegade(tm)
|
||||
** Copyright 2025 Electronic Arts Inc.
|
||||
**
|
||||
** This program is free software: you can redistribute it and/or modify
|
||||
** it under the terms of the GNU General Public License as published by
|
||||
** the Free Software Foundation, either version 3 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
// W3DUpdate.h : main header file for the W3DUPDATE application
|
||||
//
|
||||
|
||||
#if !defined(AFX_W3DUPDATE_H__4305AC4E_1EAB_11D3_A038_00104B791122__INCLUDED_)
|
||||
#define AFX_W3DUPDATE_H__4305AC4E_1EAB_11D3_A038_00104B791122__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
|
||||
#ifndef __AFXWIN_H__
|
||||
#error include 'stdafx.h' before including this file for PCH
|
||||
#endif
|
||||
|
||||
#include "resource.h" // main symbols
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CW3DUpdateApp:
|
||||
// See W3DUpdate.cpp for the implementation of this class
|
||||
//
|
||||
|
||||
class CW3DUpdateApp : public CWinApp
|
||||
{
|
||||
public:
|
||||
CW3DUpdateApp();
|
||||
|
||||
// Overrides
|
||||
// ClassWizard generated virtual function overrides
|
||||
//{{AFX_VIRTUAL(CW3DUpdateApp)
|
||||
public:
|
||||
virtual BOOL InitInstance();
|
||||
//}}AFX_VIRTUAL
|
||||
|
||||
// Implementation
|
||||
|
||||
//{{AFX_MSG(CW3DUpdateApp)
|
||||
// NOTE - the ClassWizard will add and remove member functions here.
|
||||
// DO NOT EDIT what you see in these blocks of generated code !
|
||||
//}}AFX_MSG
|
||||
DECLARE_MESSAGE_MAP()
|
||||
};
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_W3DUPDATE_H__4305AC4E_1EAB_11D3_A038_00104B791122__INCLUDED_)
|
||||
294
Code/Tools/W3DUpdate/W3DUpdate.rc
Normal file
294
Code/Tools/W3DUpdate/W3DUpdate.rc
Normal file
@@ -0,0 +1,294 @@
|
||||
//Microsoft Developer Studio generated resource script.
|
||||
//
|
||||
#include "resource.h"
|
||||
|
||||
#define APSTUDIO_READONLY_SYMBOLS
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Generated from the TEXTINCLUDE 2 resource.
|
||||
//
|
||||
#include "afxres.h"
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
#undef APSTUDIO_READONLY_SYMBOLS
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// English (U.S.) resources
|
||||
|
||||
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
|
||||
#ifdef _WIN32
|
||||
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
|
||||
#pragma code_page(1252)
|
||||
#endif //_WIN32
|
||||
|
||||
#ifdef APSTUDIO_INVOKED
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// TEXTINCLUDE
|
||||
//
|
||||
|
||||
1 TEXTINCLUDE DISCARDABLE
|
||||
BEGIN
|
||||
"resource.h\0"
|
||||
END
|
||||
|
||||
2 TEXTINCLUDE DISCARDABLE
|
||||
BEGIN
|
||||
"#include ""afxres.h""\r\n"
|
||||
"\0"
|
||||
END
|
||||
|
||||
3 TEXTINCLUDE DISCARDABLE
|
||||
BEGIN
|
||||
"#define _AFX_NO_SPLITTER_RESOURCES\r\n"
|
||||
"#define _AFX_NO_OLE_RESOURCES\r\n"
|
||||
"#define _AFX_NO_TRACKER_RESOURCES\r\n"
|
||||
"#define _AFX_NO_PROPERTY_RESOURCES\r\n"
|
||||
"\r\n"
|
||||
"#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)\r\n"
|
||||
"#ifdef _WIN32\r\n"
|
||||
"LANGUAGE 9, 1\r\n"
|
||||
"#pragma code_page(1252)\r\n"
|
||||
"#endif //_WIN32\r\n"
|
||||
"#include ""res\\W3DUpdate.rc2"" // non-Microsoft Visual C++ edited resources\r\n"
|
||||
"#include ""afxres.rc"" // Standard components\r\n"
|
||||
"#endif\r\n"
|
||||
"\0"
|
||||
END
|
||||
|
||||
#endif // APSTUDIO_INVOKED
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Icon
|
||||
//
|
||||
|
||||
// Icon with lowest ID value placed first to ensure application icon
|
||||
// remains consistent on all systems.
|
||||
IDR_MAINFRAME ICON DISCARDABLE "res\\W3DUpdate.ico"
|
||||
IDI_COPY ICON DISCARDABLE "res\\icon1.ico"
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Dialog
|
||||
//
|
||||
|
||||
IDD_W3DUPDATE_DIALOG DIALOGEX 0, 0, 306, 213
|
||||
STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
|
||||
EXSTYLE WS_EX_APPWINDOW
|
||||
CAPTION "W3D Update"
|
||||
FONT 8, "MS Sans Serif"
|
||||
BEGIN
|
||||
ICON IDI_COPY,IDC_STATIC,7,7,20,20
|
||||
LTEXT "Select the W3D applications you wish to update on your machine. Note: If you select 'Clean' all files in the application directory WILL BE DELETED.",
|
||||
IDC_STATIC,42,7,246,26
|
||||
GROUPBOX "&Applications",IDC_STATIC,7,39,292,143
|
||||
CONTROL "W3D&Viewer",IDC_VIEWER_CHECK,"Button",BS_AUTOCHECKBOX |
|
||||
WS_GROUP | WS_TABSTOP,16,57,52,10
|
||||
CONTROL "Clean",IDC_VIEWER_CLEAN_CHECK,"Button",BS_AUTOCHECKBOX |
|
||||
WS_TABSTOP,71,57,34,10
|
||||
PUSHBUTTON "<directory>",IDC_VIEWER_DIR_BUTTON,111,55,179,14
|
||||
CONTROL "&Max3 Plugin",IDC_PLUGIN_CHECK,"Button",BS_AUTOCHECKBOX |
|
||||
WS_TABSTOP,16,73,52,10
|
||||
CONTROL "Clean",IDC_PLUGIN_CLEAN_CHECK,"Button",BS_AUTOCHECKBOX |
|
||||
WS_TABSTOP,71,73,34,10
|
||||
PUSHBUTTON "<directory>",IDC_PLUGIN_DIR_BUTTON,111,71,179,14
|
||||
CONTROL "&WDump",IDC_WDUMP_CHECK,"Button",BS_AUTOCHECKBOX |
|
||||
WS_TABSTOP,16,90,41,10
|
||||
CONTROL "Clean",IDC_WDUMP_CLEAN_CHECK,"Button",BS_AUTOCHECKBOX |
|
||||
WS_TABSTOP,71,90,34,10
|
||||
PUSHBUTTON "<directory>",IDC_WDUMP_DIR_BUTTON,111,88,179,14
|
||||
CONTROL "&Renegade Dazzles",IDC_RENEGDAZZLE_CHECK,"Button",
|
||||
BS_AUTOCHECKBOX | WS_TABSTOP,16,165,90,10
|
||||
DEFPUSHBUTTON "OK",IDOK,56,192,50,14,WS_GROUP
|
||||
PUSHBUTTON "Cancel",IDCANCEL,122,192,50,14
|
||||
PUSHBUTTON "Defaults",IDC_DEFAULTS,188,192,50,14
|
||||
CONTROL "&Max4 Plugin",IDC_MAX4_PLUGIN_CHECK,"Button",
|
||||
BS_AUTOCHECKBOX | WS_TABSTOP,16,108,52,10
|
||||
CONTROL "Clean",IDC_MAX4_PLUGIN_CLEAN_CHECK,"Button",
|
||||
BS_AUTOCHECKBOX | WS_TABSTOP,71,108,34,10
|
||||
PUSHBUTTON "<directory>",IDC_MAX4_PLUGIN_DIR_BUTTON,111,106,179,14
|
||||
CONTROL "&W3D Shell Extension",IDC_W3DSHELLEXT,"Button",
|
||||
BS_AUTOCHECKBOX | WS_TABSTOP,16,140,78,10
|
||||
CONTROL "&GMax",IDC_GMAX_CHECK,"Button",BS_AUTOCHECKBOX |
|
||||
WS_TABSTOP,16,124,52,10
|
||||
CONTROL "Clean",IDC_GMAX_CLEAN_CHECK2,"Button",BS_AUTOCHECKBOX |
|
||||
WS_TABSTOP,71,123,34,10
|
||||
END
|
||||
|
||||
IDD_FILE_COPY DIALOGEX 0, 0, 210, 79
|
||||
STYLE DS_MODALFRAME | DS_SETFOREGROUND | WS_POPUP | WS_VISIBLE | WS_CAPTION
|
||||
EXSTYLE WS_EX_APPWINDOW
|
||||
CAPTION "Updating Application..."
|
||||
FONT 8, "MS Sans Serif", 0, 0, 0x1
|
||||
BEGIN
|
||||
CONTROL "Animate1",IDC_ANIMATE_CTRL,"SysAnimate32",ACS_CENTER |
|
||||
ACS_TRANSPARENT | ACS_AUTOPLAY | WS_TABSTOP,7,23,196,34
|
||||
LTEXT "Building file list...",IDC_FILENAME_TEXT,7,60,196,8
|
||||
LTEXT "Application:",IDC_CURRENT_APP,7,7,196,8
|
||||
END
|
||||
|
||||
IDD_DIR_SELECT_DIALOG DIALOG DISCARDABLE 36, 24, 268, 134
|
||||
STYLE DS_MODALFRAME | DS_3DLOOK | DS_CONTEXTHELP | WS_POPUP | WS_CAPTION |
|
||||
WS_SYSMENU
|
||||
CAPTION "Open"
|
||||
FONT 8, "MS Shell Dlg"
|
||||
BEGIN
|
||||
LTEXT "&Folder Name:",1090,6,6,76,9
|
||||
EDITTEXT 1152,6,16,90,12,ES_AUTOHSCROLL | ES_OEMCONVERT
|
||||
LTEXT "",1088,110,16,96,9,SS_NOPREFIX
|
||||
LISTBOX 1121,110,32,96,68,LBS_SORT | LBS_OWNERDRAWFIXED |
|
||||
LBS_HASSTRINGS | LBS_DISABLENOSCROLL | WS_VSCROLL |
|
||||
WS_TABSTOP
|
||||
LTEXT "Dri&ves:",1091,110,104,96,9
|
||||
COMBOBOX 1137,110,114,96,68,CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED |
|
||||
CBS_AUTOHSCROLL | CBS_SORT | CBS_HASSTRINGS | WS_VSCROLL |
|
||||
WS_TABSTOP
|
||||
DEFPUSHBUTTON "OK",IDOK,212,6,50,14,WS_GROUP
|
||||
PUSHBUTTON "Cancel",IDCANCEL,212,24,50,14,WS_GROUP
|
||||
PUSHBUTTON "&Help",1038,212,46,50,14,WS_GROUP
|
||||
END
|
||||
|
||||
|
||||
#ifndef _MAC
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Version
|
||||
//
|
||||
|
||||
VS_VERSION_INFO VERSIONINFO
|
||||
FILEVERSION 1,0,0,1
|
||||
PRODUCTVERSION 1,0,0,1
|
||||
FILEFLAGSMASK 0x3fL
|
||||
#ifdef _DEBUG
|
||||
FILEFLAGS 0x1L
|
||||
#else
|
||||
FILEFLAGS 0x0L
|
||||
#endif
|
||||
FILEOS 0x4L
|
||||
FILETYPE 0x1L
|
||||
FILESUBTYPE 0x0L
|
||||
BEGIN
|
||||
BLOCK "StringFileInfo"
|
||||
BEGIN
|
||||
BLOCK "040904B0"
|
||||
BEGIN
|
||||
VALUE "CompanyName", "\0"
|
||||
VALUE "FileDescription", "W3DUpdate MFC Application\0"
|
||||
VALUE "FileVersion", "1, 0, 0, 1\0"
|
||||
VALUE "InternalName", "W3DUpdate\0"
|
||||
VALUE "LegalCopyright", "Copyright (C) 1999\0"
|
||||
VALUE "LegalTrademarks", "\0"
|
||||
VALUE "OriginalFilename", "W3DUpdate.EXE\0"
|
||||
VALUE "ProductName", "W3DUpdate Application\0"
|
||||
VALUE "ProductVersion", "1, 0, 0, 1\0"
|
||||
END
|
||||
END
|
||||
BLOCK "VarFileInfo"
|
||||
BEGIN
|
||||
VALUE "Translation", 0x409, 1200
|
||||
END
|
||||
END
|
||||
|
||||
#endif // !_MAC
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// DESIGNINFO
|
||||
//
|
||||
|
||||
#ifdef APSTUDIO_INVOKED
|
||||
GUIDELINES DESIGNINFO DISCARDABLE
|
||||
BEGIN
|
||||
IDD_W3DUPDATE_DIALOG, DIALOG
|
||||
BEGIN
|
||||
LEFTMARGIN, 7
|
||||
RIGHTMARGIN, 299
|
||||
TOPMARGIN, 7
|
||||
BOTTOMMARGIN, 206
|
||||
END
|
||||
|
||||
IDD_FILE_COPY, DIALOG
|
||||
BEGIN
|
||||
LEFTMARGIN, 7
|
||||
RIGHTMARGIN, 203
|
||||
TOPMARGIN, 7
|
||||
BOTTOMMARGIN, 72
|
||||
END
|
||||
END
|
||||
#endif // APSTUDIO_INVOKED
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// AVI
|
||||
//
|
||||
|
||||
IDR_FILECOPY_AVI AVI DISCARDABLE "res\\Filecopy.avi"
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// String Table
|
||||
//
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
IDS_COPYFAIL "Cannot copy %s to %s. Please make sure no applications are running before running the update."
|
||||
IDS_SYSTEMDLL "The changes will take effect after you reboot the computer."
|
||||
IDS_SHELLEXT_CLSID "CLSID\\{556F8779-49C4-4e88-9CEF-0AC2CFD6B763}"
|
||||
IDS_SHELLEXT_NAME "W3D Shell Extension"
|
||||
IDS_SHELLEXT_DLLNAME "W3Dshellext.dll"
|
||||
IDS_W3DSHELLEXT_THMODEL "ThreadingModel"
|
||||
IDS_W3DSHELLEXT_APARTMENT "Apartment"
|
||||
IDS_W3DFILEEXT ".w3d"
|
||||
IDS_W3DFILETEXT "W3DFile"
|
||||
IDS_W3DFILEKEY "HKEY_CLASSES_ROOT\\W3DFile"
|
||||
IDS_CTXMENUHANDLERS "W3DFile\\shellex\\ContextMenuHandlers"
|
||||
IDS_W3DMENU_TEXT "W3DCtxMenu"
|
||||
IDS_W3DCTXMENU_KEY "W3DFile\\shellex\\ContextMenuHandlers\\W3DCtxMenu"
|
||||
IDS_W3DSHELLEXT_GUID "{556F8779-49C4-4e88-9CEF-0AC2CFD6B763}"
|
||||
IDS_W3DPROPSHEETHANDLERS "W3DFile\\shellex\\PropertySheetHandlers"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
IDS_W3DPROPPAGE_TEXT "W3DPropertyPage"
|
||||
IDS_W3DPROPPAGE_KEY "W3DFile\\shellex\\PropertySheetHandlers\\W3DPropertyPage"
|
||||
IDS_MSEXTENSIONS_KEY "SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Shell Extensions\\Approved"
|
||||
IDS_W3DSHELLEXT_TEXT "W3D Shell Extension"
|
||||
IDS_W3DDEFAULTICON_TEXT "%SystemRoot%\\system32\\W3DShellExt.dll,0"
|
||||
IDS_W3DDEFAULTICON_KEY "W3DFile\\DefaultIcon"
|
||||
IDS_OPENWITH "W3DFile\\Shell\\Open\\Command"
|
||||
IDS_VIEWERCOMMAND "\\W3DVIEW.EXE %1"
|
||||
IDS_GMAXRENX_PATH "Gamepacks\\Westwood\\RenX"
|
||||
END
|
||||
|
||||
#endif // English (U.S.) resources
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
|
||||
#ifndef APSTUDIO_INVOKED
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Generated from the TEXTINCLUDE 3 resource.
|
||||
//
|
||||
#define _AFX_NO_SPLITTER_RESOURCES
|
||||
#define _AFX_NO_OLE_RESOURCES
|
||||
#define _AFX_NO_TRACKER_RESOURCES
|
||||
#define _AFX_NO_PROPERTY_RESOURCES
|
||||
|
||||
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
|
||||
#ifdef _WIN32
|
||||
LANGUAGE 9, 1
|
||||
#pragma code_page(1252)
|
||||
#endif //_WIN32
|
||||
#include "res\W3DUpdate.rc2" // non-Microsoft Visual C++ edited resources
|
||||
#include "afxres.rc" // Standard components
|
||||
#endif
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
#endif // not APSTUDIO_INVOKED
|
||||
|
||||
917
Code/Tools/W3DUpdate/W3DUpdateDlg.cpp
Normal file
917
Code/Tools/W3DUpdate/W3DUpdateDlg.cpp
Normal file
@@ -0,0 +1,917 @@
|
||||
/*
|
||||
** Command & Conquer Renegade(tm)
|
||||
** Copyright 2025 Electronic Arts Inc.
|
||||
**
|
||||
** This program is free software: you can redistribute it and/or modify
|
||||
** it under the terms of the GNU General Public License as published by
|
||||
** the Free Software Foundation, either version 3 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
// W3DUpdateDlg.cpp : implementation file
|
||||
//
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "W3DUpdate.h"
|
||||
#include "W3DUpdateDlg.h"
|
||||
#include "FileCopyDialog.H"
|
||||
|
||||
#ifdef _DEBUG
|
||||
#define new DEBUG_NEW
|
||||
#undef THIS_FILE
|
||||
static char THIS_FILE[] = __FILE__;
|
||||
#endif
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Data Tables
|
||||
//
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
typedef struct
|
||||
{
|
||||
FileCopyDialogClass *dialog;
|
||||
CString src_dir;
|
||||
CString dest_dir;
|
||||
bool result;
|
||||
} UPDATE_INFO;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
LPCTSTR title;
|
||||
LPCTSTR src;
|
||||
LPCTSTR default_dir;
|
||||
LPCTSTR reg_key;
|
||||
UINT ctrl_id;
|
||||
UINT clean_ctrl_id;
|
||||
UINT dir_ctrl_id;
|
||||
bool clean_default;
|
||||
int copy_to_app_dir1;
|
||||
int copy_to_app_dir2;
|
||||
} APP_INFO;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
APP_VIEWER = 0,
|
||||
APP_PLUGIN,
|
||||
APP_WDUMP,
|
||||
APP_MAX4_PLUGIN,
|
||||
APP_RENEGADE_DAZZLES,
|
||||
APP_W3DSHELLEXT,
|
||||
APP_GMAXRENX,
|
||||
APP_MAX,
|
||||
} APPLICATION_IDS;
|
||||
|
||||
const APP_INFO APPLICATIONS[APP_MAX] =
|
||||
// --- Title --- ---Source --- --Default Dir--- ---RegKey--- ---Ctrl_ID--- ---Clean CtrlID-- --Dir CtrlID--- --Clean default- copy to appdir1, copy to appdir2
|
||||
{
|
||||
{ "W3DViewer", "\\\\cabal\\mis\\r&d\\w3d\\w3dview", "c:\\w3d\\w3dview", "W3DUpdate\\W3DView", IDC_VIEWER_CHECK, IDC_VIEWER_CLEAN_CHECK, IDC_VIEWER_DIR_BUTTON, true, -1, -1 },
|
||||
{ "Max3 Plugin", "\\\\cabal\\mis\\r&d\\w3d\\maxplugins\\max3", "c:\\3dsmax3\\plugins\\westwood", "W3DUpdate\\MaxPlugin30", IDC_PLUGIN_CHECK, IDC_PLUGIN_CLEAN_CHECK, IDC_PLUGIN_DIR_BUTTON, false, -1, -1 },
|
||||
{ "WDump", "\\\\cabal\\mis\\r&d\\w3d\\wdump", "c:\\w3d\\wdump", "W3DUpdate\\WDump", IDC_WDUMP_CHECK, IDC_WDUMP_CLEAN_CHECK, IDC_WDUMP_DIR_BUTTON, true, -1, -1 },
|
||||
{ "Max4 Plugin", "\\\\cabal\\mis\\r&d\\w3d\\maxplugins\\max4", "c:\\3dsmax4\\plugins\\westwood", "W3DUpdate\\MaxPlugin40", IDC_MAX4_PLUGIN_CHECK, IDC_MAX4_PLUGIN_CLEAN_CHECK, IDC_MAX4_PLUGIN_DIR_BUTTON, false, -1, -1 },
|
||||
{ "Renegade Dazzles", "\\\\mobius\\project7\\projects\\renegade\\asset management\\assets\\dazzle", "", "W3DUpdate\\Reneg Dazzle", IDC_RENEGDAZZLE_CHECK, -1, -1 , false, APP_VIEWER, APP_PLUGIN },
|
||||
{ "W3D Shell Extension","\\\\cabal\\mis\\r&d\\w3d\\W3DShellExt", "", "W3DUpdate\\W3DShellExt", IDC_W3DSHELLEXT, -1 , -1 , false, -1, -1 },
|
||||
{"Gmax Settings", "\\\\cabal\\mis\\r&d\\w3d\\GmaxRenX", "", "W3DUpdate\\GmaxRenX", IDC_GMAX_CHECK, IDC_GMAX_CLEAN_CHECK2 , -1 , false, -1, -1}
|
||||
};
|
||||
|
||||
|
||||
const char * const INSTALL_REG_VALUE = "Path";
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Local prototypes
|
||||
//
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
bool Update_App (CWnd *parent_wnd, LPCTSTR title, LPCTSTR src_dir, LPCTSTR dest_dir);
|
||||
bool Clean_Directory (LPCTSTR local_dir);
|
||||
bool Get_Install_Directory (HWND hparent_wnd, LPCTSTR title, CString &folder);
|
||||
bool Delete_File (LPCTSTR filename);
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CW3DUpdateDlg dialog
|
||||
|
||||
CW3DUpdateDlg::CW3DUpdateDlg(CWnd* pParent /*=NULL*/)
|
||||
: CDialog(CW3DUpdateDlg::IDD, pParent)
|
||||
{
|
||||
//{{AFX_DATA_INIT(CW3DUpdateDlg)
|
||||
// NOTE: the ClassWizard will add member initialization here
|
||||
//}}AFX_DATA_INIT
|
||||
// Note that LoadIcon does not require a subsequent DestroyIcon in Win32
|
||||
m_hIcon = AfxGetApp()->LoadIcon(IDR_MAINFRAME);
|
||||
}
|
||||
|
||||
void CW3DUpdateDlg::DoDataExchange(CDataExchange* pDX)
|
||||
{
|
||||
CDialog::DoDataExchange(pDX);
|
||||
//{{AFX_DATA_MAP(CW3DUpdateDlg)
|
||||
// NOTE: the ClassWizard will add DDX and DDV calls here
|
||||
//}}AFX_DATA_MAP
|
||||
}
|
||||
|
||||
BEGIN_MESSAGE_MAP(CW3DUpdateDlg, CDialog)
|
||||
//{{AFX_MSG_MAP(CW3DUpdateDlg)
|
||||
ON_WM_PAINT()
|
||||
ON_WM_QUERYDRAGICON()
|
||||
ON_BN_CLICKED(IDC_DEFAULTS, OnDefaults)
|
||||
//}}AFX_MSG_MAP
|
||||
END_MESSAGE_MAP()
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CW3DUpdateDlg message handlers
|
||||
|
||||
BOOL CW3DUpdateDlg::OnInitDialog()
|
||||
{
|
||||
CDialog::OnInitDialog();
|
||||
|
||||
// Set the icon for this dialog. The framework does this automatically
|
||||
// when the application's main window is not a dialog
|
||||
SetIcon(m_hIcon, TRUE); // Set big icon
|
||||
SetIcon(m_hIcon, FALSE); // Set small icon
|
||||
|
||||
//
|
||||
// Check/uncheck the applications by default
|
||||
//
|
||||
for (int index = 0; index < APP_MAX; index ++) {
|
||||
const APP_INFO &app_info = APPLICATIONS[index];
|
||||
HKEY hreg_key = NULL;
|
||||
CString reg_key_name;
|
||||
reg_key_name.Format ("Software\\Westwood Studios\\%s", app_info.reg_key);
|
||||
|
||||
TCHAR path[MAX_PATH] = { 0 };
|
||||
|
||||
|
||||
//
|
||||
// Is this application installed?
|
||||
//
|
||||
if (::RegOpenKeyEx (HKEY_CURRENT_USER, reg_key_name, 0L, KEY_READ, &hreg_key) == ERROR_SUCCESS) {
|
||||
//Moumine-
|
||||
//SendDlgItemMessage (app_info.ctrl_id, BM_SETCHECK, (WPARAM)TRUE);
|
||||
|
||||
//
|
||||
// Read the installation directory from the registry
|
||||
//
|
||||
DWORD size = sizeof (path);
|
||||
::RegQueryValueEx (hreg_key, INSTALL_REG_VALUE, 0L, NULL, (BYTE *)path, &size);
|
||||
::RegCloseKey (hreg_key);
|
||||
} else {
|
||||
::EnableWindow (::GetDlgItem (m_hWnd, app_info.clean_ctrl_id), false);
|
||||
::EnableWindow (::GetDlgItem (m_hWnd, app_info.dir_ctrl_id), false);
|
||||
}
|
||||
|
||||
//
|
||||
// Set the text of the install directory buttons
|
||||
//
|
||||
if (path[0] == 0) {
|
||||
::lstrcpy (path, app_info.default_dir);
|
||||
}
|
||||
|
||||
if (app_info.dir_ctrl_id != -1) {
|
||||
SetDlgItemText (app_info.dir_ctrl_id, path);
|
||||
}
|
||||
|
||||
//
|
||||
// Check the clean option (by default) if necessary
|
||||
//
|
||||
if (app_info.clean_default && app_info.clean_ctrl_id != -1) {
|
||||
SendDlgItemMessage (app_info.clean_ctrl_id, BM_SETCHECK, (WPARAM)TRUE);
|
||||
}
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
// If you add a minimize button to your dialog, you will need the code below
|
||||
// to draw the icon. For MFC applications using the document/view model,
|
||||
// this is automatically done for you by the framework.
|
||||
|
||||
void CW3DUpdateDlg::OnPaint()
|
||||
{
|
||||
if (IsIconic())
|
||||
{
|
||||
CPaintDC dc(this); // device context for painting
|
||||
|
||||
SendMessage(WM_ICONERASEBKGND, (WPARAM) dc.GetSafeHdc(), 0);
|
||||
|
||||
// Center icon in client rectangle
|
||||
int cxIcon = GetSystemMetrics(SM_CXICON);
|
||||
int cyIcon = GetSystemMetrics(SM_CYICON);
|
||||
CRect rect;
|
||||
GetClientRect(&rect);
|
||||
int x = (rect.Width() - cxIcon + 1) / 2;
|
||||
int y = (rect.Height() - cyIcon + 1) / 2;
|
||||
|
||||
// Draw the icon
|
||||
dc.DrawIcon(x, y, m_hIcon);
|
||||
}
|
||||
else
|
||||
{
|
||||
CDialog::OnPaint();
|
||||
}
|
||||
}
|
||||
|
||||
// The system calls this to obtain the cursor to display while the user drags
|
||||
// the minimized window.
|
||||
HCURSOR CW3DUpdateDlg::OnQueryDragIcon()
|
||||
{
|
||||
return (HCURSOR) m_hIcon;
|
||||
}
|
||||
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// OnOK
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
void
|
||||
CW3DUpdateDlg::OnOK (void)
|
||||
{
|
||||
//
|
||||
// Install/upgrade each application
|
||||
//
|
||||
bool success = true;
|
||||
for (int index = 0; (index < APP_MAX) && success; index ++) {
|
||||
const APP_INFO &app_info = APPLICATIONS[index];
|
||||
|
||||
//
|
||||
// Does the user want to install this application?
|
||||
//
|
||||
if (SendDlgItemMessage (app_info.ctrl_id, BM_GETCHECK) == 1) {
|
||||
|
||||
//
|
||||
// Build a string containing the name registry key we will keep information
|
||||
// about this application in.
|
||||
//
|
||||
CString reg_key_name;
|
||||
reg_key_name.Format ("Software\\Westwood Studios\\%s", app_info.reg_key);
|
||||
|
||||
//
|
||||
// Should we install this application to the same directory as another
|
||||
// application in the list?
|
||||
//
|
||||
if (app_info.copy_to_app_dir1 != -1) {
|
||||
CString local_path;
|
||||
|
||||
//
|
||||
// Install the application to the same directory as App1
|
||||
//
|
||||
Get_Destination_Path (app_info.copy_to_app_dir1, local_path);
|
||||
success = Install_App (app_info.title, app_info.src, local_path, reg_key_name, false);
|
||||
|
||||
if (success) {
|
||||
if (app_info.copy_to_app_dir2 != -1) {
|
||||
|
||||
//
|
||||
// Install the application to the same directory as App2
|
||||
//
|
||||
Get_Destination_Path (app_info.copy_to_app_dir2, local_path);
|
||||
success = Install_App (app_info.title, app_info.src, local_path, reg_key_name, false);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
} else {
|
||||
|
||||
//
|
||||
// Do we need to clean the source directory for this application?
|
||||
//
|
||||
bool clean = (SendDlgItemMessage (app_info.clean_ctrl_id, BM_GETCHECK) == 1);
|
||||
|
||||
//
|
||||
// Get the path where this application is installed
|
||||
//
|
||||
CString local_path;
|
||||
Get_Destination_Path (index, local_path);
|
||||
|
||||
//
|
||||
// Install the application
|
||||
//
|
||||
success = Install_App (app_info.title, app_info.src, local_path, reg_key_name, clean);
|
||||
}
|
||||
if(index == APP_W3DSHELLEXT){ //Need more registration
|
||||
RegisterShellExt();
|
||||
}else{
|
||||
if(index == APP_VIEWER){
|
||||
//Set Viewer as default application
|
||||
RegisterViewer(index);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
CDialog::OnOK ();
|
||||
return ;
|
||||
}
|
||||
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Get_Destination_Path
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
void
|
||||
CW3DUpdateDlg::Get_Destination_Path (int app_id, CString &dest_path)
|
||||
{
|
||||
//
|
||||
// Read the destination directory from the dialog
|
||||
//
|
||||
switch(app_id){
|
||||
case APP_W3DSHELLEXT:{
|
||||
//SHGetFolderPath(NULL,CSIDL_SYSTEM, NULL,SHGFP_TYPE_CURRENT,dest_path.GetBuffer(MAX_PATH) );
|
||||
SHGetSpecialFolderPath(NULL,dest_path.GetBuffer(MAX_PATH), CSIDL_SYSTEM, TRUE);
|
||||
dest_path.ReleaseBuffer();
|
||||
break;
|
||||
}
|
||||
case APP_GMAXRENX:{
|
||||
GetEnvironmentVariable("GMaxLoc", dest_path.GetBuffer(MAX_PATH),MAX_PATH);
|
||||
dest_path.ReleaseBuffer();
|
||||
CString str(MAKEINTRESOURCE(IDS_GMAXRENX_PATH));
|
||||
dest_path += str;
|
||||
break;
|
||||
}
|
||||
default:{
|
||||
GetDlgItemText (APPLICATIONS[app_id].dir_ctrl_id, dest_path);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
//
|
||||
// Ensure the path doesn't contain a terminating delimiter
|
||||
//
|
||||
if (dest_path[::lstrlen (dest_path) - 1] == '\\') {
|
||||
dest_path.Delete (::lstrlen (dest_path) - 1, 1);
|
||||
}
|
||||
|
||||
return ;
|
||||
}
|
||||
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Install_App
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
bool
|
||||
CW3DUpdateDlg::Install_App
|
||||
(
|
||||
const CString &title,
|
||||
const CString &src_path,
|
||||
const CString &dest_path,
|
||||
const CString ®_key_name,
|
||||
bool clean
|
||||
)
|
||||
{
|
||||
CWaitCursor wait_cursor;
|
||||
|
||||
//
|
||||
// Clean the old version if necessary
|
||||
//
|
||||
if (clean) {
|
||||
::Clean_Directory (dest_path);
|
||||
}
|
||||
|
||||
//
|
||||
// Update the application's files
|
||||
//
|
||||
bool ret_val = ::Update_App (this, title, src_path, dest_path);
|
||||
|
||||
//
|
||||
// Write the app's installation dir to the registry if we
|
||||
// installed it correctly.
|
||||
//
|
||||
if (ret_val) {
|
||||
HKEY reg_key = NULL;
|
||||
ret_val &= (::RegCreateKeyEx ( HKEY_CURRENT_USER,
|
||||
reg_key_name,
|
||||
0L,
|
||||
NULL,
|
||||
REG_OPTION_NON_VOLATILE,
|
||||
KEY_ALL_ACCESS,
|
||||
NULL,
|
||||
®_key,
|
||||
NULL) == ERROR_SUCCESS);
|
||||
if (ret_val) {
|
||||
::RegSetValueEx ( reg_key,
|
||||
INSTALL_REG_VALUE,
|
||||
0L,
|
||||
REG_SZ,
|
||||
(BYTE *)(LPCTSTR)dest_path,
|
||||
dest_path.GetLength () + 1);
|
||||
::RegCloseKey (reg_key);
|
||||
}
|
||||
}
|
||||
|
||||
return ret_val;
|
||||
}
|
||||
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Get_Install_Directory
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
bool
|
||||
Get_Install_Directory (HWND hparent_wnd, LPCTSTR title, CString &folder)
|
||||
{
|
||||
bool ret_val = false;
|
||||
|
||||
// Browse for the folder
|
||||
BROWSEINFO browse_info = { 0 };
|
||||
browse_info.hwndOwner = hparent_wnd;
|
||||
browse_info.lpszTitle = title;
|
||||
browse_info.ulFlags = BIF_RETURNONLYFSDIRS;
|
||||
LPITEMIDLIST pidl = ::SHBrowseForFolder (&browse_info);
|
||||
if (pidl != NULL) {
|
||||
|
||||
// Convert the 'PIDL' into a string
|
||||
char path[MAX_PATH];
|
||||
ret_val = (::SHGetPathFromIDList (pidl, path) == TRUE);
|
||||
if (ret_val) {
|
||||
folder = path;
|
||||
}
|
||||
|
||||
// Free the 'PIDL'
|
||||
LPMALLOC pmalloc = NULL;
|
||||
if (SUCCEEDED (::SHGetMalloc (&pmalloc))) {
|
||||
pmalloc->Free (pidl);
|
||||
pmalloc->Release ();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//CFileDialog dialog (TRUE, ".pth", "test.pth", OFN_PATHMUSTEXIST | OFN_EXPLORER, "files *.*|*.*||", CWnd::FromHandle(hparent_wnd));
|
||||
//CFileDialog dialog (TRUE, ".pth", "test.pth", OFN_PATHMUSTEXIST | OFN_EXPLORER | OFN_ENABLETEMPLATEHANDLE, "files *.*|*.*||", CWnd::FromHandle(hparent_wnd));
|
||||
//dialog.m_ofn.lpTemplateName = MAKEINTRESOURCE (IDD_DIR_SELECT_DIALOG);
|
||||
//dialog.m_ofn.hInstance = ::AfxGetInstanceHandle ();
|
||||
//HRSRC resource = ::FindResource (::AfxGetInstanceHandle (), MAKEINTRESOURCE (IDD_DIR_SELECT_DIALOG), RT_DIALOG);
|
||||
//dialog.m_ofn.hInstance = (HINSTANCE)::LoadResource (::AfxGetInstanceHandle (), resource);
|
||||
|
||||
//dialog.DoModal ();
|
||||
/*TCHAR path[MAX_PATH] = { 0 };
|
||||
|
||||
OPENFILENAME ofn = { 0 };
|
||||
ofn.lStructSize = sizeof (ofn);
|
||||
ofn.Flags = OFN_PATHMUSTEXIST | OFN_ENABLETEMPLATE;
|
||||
ofn.hInstance = ::AfxGetInstanceHandle ();
|
||||
ofn.lpTemplateName = MAKEINTRESOURCE (IDD_DIR_SELECT_DIALOG);
|
||||
ofn.hwndOwner = hparent_wnd;
|
||||
ofn.lpstrFile = path;
|
||||
ofn.nMaxFile = sizeof (path);
|
||||
GetOpenFileName (&ofn);
|
||||
::CommDlgExtendedError ();*/
|
||||
//ret_val = (dialog.DoModal () == IDOK);
|
||||
|
||||
// Return the true/false result code
|
||||
return ret_val;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Strip_Filename_From_Path
|
||||
//
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
CString
|
||||
Strip_Filename_From_Path (LPCTSTR path)
|
||||
{
|
||||
// Copy the path to a buffer we can modify
|
||||
TCHAR temp_path[MAX_PATH];
|
||||
::lstrcpy (temp_path, path);
|
||||
|
||||
// Find the last occurance of the directory deliminator
|
||||
LPTSTR filename = ::strrchr (temp_path, '\\');
|
||||
if (filename != NULL) {
|
||||
// Strip off the filename
|
||||
filename[0] = 0;
|
||||
}
|
||||
|
||||
// Return the path only
|
||||
return CString (temp_path);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Delete_File
|
||||
//
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
bool
|
||||
Delete_File (LPCTSTR filename)
|
||||
{
|
||||
// Assume failure
|
||||
bool ret_val = false;
|
||||
|
||||
ASSERT (filename != NULL);
|
||||
if (filename != NULL) {
|
||||
|
||||
// Strip the readonly bit off if necessary
|
||||
DWORD attributes = ::GetFileAttributes (filename);
|
||||
if ((attributes != 0xFFFFFFFF) &&
|
||||
((attributes & FILE_ATTRIBUTE_READONLY) == FILE_ATTRIBUTE_READONLY)) {
|
||||
::SetFileAttributes (filename, attributes & (~FILE_ATTRIBUTE_READONLY));
|
||||
}
|
||||
|
||||
// Perform the delete operation!
|
||||
ret_val = ::DeleteFile (filename) == TRUE;
|
||||
}
|
||||
|
||||
// Return the true/false result code
|
||||
return ret_val;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Copy_File
|
||||
//
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
bool
|
||||
Copy_File
|
||||
(
|
||||
LPCTSTR existing_filename,
|
||||
LPCTSTR new_filename,
|
||||
bool bforce_copy
|
||||
)
|
||||
{
|
||||
// Assume failure
|
||||
bool ret_val = false;
|
||||
|
||||
ASSERT (existing_filename != NULL);
|
||||
ASSERT (new_filename != NULL);
|
||||
if ((existing_filename != NULL) &&
|
||||
(new_filename != NULL)) {
|
||||
|
||||
// Make sure we aren't copying over ourselves
|
||||
bool allow_copy = (::lstrcmpi (existing_filename, new_filename) != 0);
|
||||
|
||||
// Strip the readonly bit off if necessary
|
||||
DWORD attributes = ::GetFileAttributes (new_filename);
|
||||
if (allow_copy &&
|
||||
(attributes != 0xFFFFFFFF) &&
|
||||
((attributes & FILE_ATTRIBUTE_READONLY) == FILE_ATTRIBUTE_READONLY)) {
|
||||
if (bforce_copy) {
|
||||
::SetFileAttributes (new_filename, attributes & (~FILE_ATTRIBUTE_READONLY));
|
||||
} else {
|
||||
allow_copy = false;
|
||||
}
|
||||
}
|
||||
|
||||
// Perform the copy operation!
|
||||
if (allow_copy) {
|
||||
ret_val = (::CopyFile (existing_filename, new_filename, FALSE) == TRUE);
|
||||
}
|
||||
}
|
||||
|
||||
// Return the true/false result code
|
||||
return ret_val;
|
||||
}
|
||||
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Clean_Directory
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
bool
|
||||
Clean_Directory (LPCTSTR local_dir)
|
||||
{
|
||||
bool ret_val = true;
|
||||
// Build a search mask from the directory
|
||||
CString search_mask = CString (local_dir) + "\\*.*";
|
||||
// Loop through all the files in this directory and add them
|
||||
// to our list
|
||||
WIN32_FIND_DATA find_info = { 0 };
|
||||
HANDLE hfind = ::FindFirstFile (search_mask, &find_info);
|
||||
if(hfind){
|
||||
while(FindNextFile(hfind, &find_info)){
|
||||
// If this file isn't a directory, add it to the list
|
||||
if(!(find_info.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)) {
|
||||
CString full_path = local_dir + CString ("\\") + find_info.cFileName;
|
||||
if (::Delete_File (full_path) == FALSE) {
|
||||
CString message;
|
||||
message.Format ("Cannot delete %s. This may result in an incomplete update. Please make sure no applications are running before running the update.", full_path);
|
||||
::MessageBox (NULL, message, "Delete Error", MB_SETFOREGROUND | MB_TOPMOST | MB_ICONEXCLAMATION | MB_OK);
|
||||
ret_val = false;
|
||||
}
|
||||
}else{
|
||||
if( find_info.cFileName[0] != '.'){
|
||||
CString new_dir = CString(local_dir) + "\\" + CString(find_info.cFileName);
|
||||
Clean_Directory(new_dir.GetBuffer(new_dir.GetLength()));
|
||||
new_dir.ReleaseBuffer();
|
||||
RemoveDirectory(new_dir.GetBuffer(new_dir.GetLength()));
|
||||
new_dir.ReleaseBuffer();
|
||||
}
|
||||
}
|
||||
}
|
||||
::FindClose (hfind);
|
||||
}
|
||||
return ret_val;
|
||||
}
|
||||
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Create_Dir_If_Necessary
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
void
|
||||
Create_Dir_If_Necessary (LPCTSTR path)
|
||||
{
|
||||
if (::GetFileAttributes (path) == 0xFFFFFFFF) {
|
||||
Create_Dir_If_Necessary (::Strip_Filename_From_Path (path));
|
||||
::CreateDirectory (path, NULL);
|
||||
}
|
||||
|
||||
return ;
|
||||
}
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// fnUpdateAppDirectory
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
UINT
|
||||
fnUpdateAppDirectory (LPVOID pParam)
|
||||
{
|
||||
static call_depth(0);
|
||||
UPDATE_INFO *info = (UPDATE_INFO *)pParam;
|
||||
ASSERT (info != NULL);
|
||||
if (info != NULL) {
|
||||
info->result = true;
|
||||
|
||||
// Build a search mask from the directory
|
||||
CString search_mask = info->src_dir + "\\*.*";
|
||||
|
||||
// Loop through all the files in this directory and add them
|
||||
// to our list
|
||||
WIN32_FIND_DATA find_info = { 0 };
|
||||
HANDLE hfind = ::FindFirstFile (search_mask, &find_info);
|
||||
if(hfind){
|
||||
while(FindNextFile(hfind, &find_info)){
|
||||
// If this file isn't a directory, add it to the list
|
||||
if (!(find_info.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)) {
|
||||
CString src_path = info->src_dir + CString ("\\") + find_info.cFileName;
|
||||
CString dest_path = info->dest_dir + CString ("\\") + find_info.cFileName;
|
||||
::Create_Dir_If_Necessary (info->dest_dir);
|
||||
//info->dialog->Set_Current_File (find_info.cFileName);
|
||||
if (::Copy_File (src_path, dest_path, true) == FALSE) {
|
||||
CString message;
|
||||
message.Format (IDS_COPYFAIL, src_path, dest_path);
|
||||
::MessageBox (NULL, message, "Copy Error", MB_SETFOREGROUND | MB_TOPMOST | MB_ICONEXCLAMATION | MB_OK);
|
||||
info->result = false;
|
||||
}
|
||||
}else{
|
||||
if( find_info.cFileName[0] != '.'){
|
||||
UPDATE_INFO info2 = *info;
|
||||
CString folder = "\\";
|
||||
folder += find_info.cFileName;
|
||||
info2.dest_dir += folder;
|
||||
info2.src_dir += folder;
|
||||
call_depth ++;
|
||||
fnUpdateAppDirectory(&info2);
|
||||
call_depth --;
|
||||
}
|
||||
}
|
||||
}
|
||||
::FindClose (hfind);
|
||||
}
|
||||
}
|
||||
if(!call_depth){
|
||||
// Kill the updating dialog
|
||||
::PostMessage(info->dialog->m_hWnd, WM_USER + 101, 0, 0L);
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Update_App
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
bool
|
||||
Update_App
|
||||
(
|
||||
CWnd * parent_wnd,
|
||||
LPCTSTR title,
|
||||
LPCTSTR src_dir,
|
||||
LPCTSTR dest_dir
|
||||
)
|
||||
{
|
||||
CWaitCursor wait_cursor;
|
||||
|
||||
FileCopyDialogClass dialog (parent_wnd);
|
||||
dialog.Set_Current_Application (title);
|
||||
|
||||
//
|
||||
// Create the destination directory if necessary
|
||||
//
|
||||
if (::GetFileAttributes (dest_dir) == 0xFFFFFFFF) {
|
||||
::CreateDirectory (dest_dir, NULL);
|
||||
}
|
||||
|
||||
//
|
||||
// Kick off a worker thread to do the actual file copy
|
||||
//
|
||||
UPDATE_INFO *info = new UPDATE_INFO;
|
||||
info->dialog = &dialog;
|
||||
info->src_dir = src_dir;
|
||||
info->dest_dir = dest_dir;
|
||||
::AfxBeginThread (fnUpdateAppDirectory, (LPVOID)info);
|
||||
// Kill the updating dialog
|
||||
::PostMessage( dialog.m_hWnd, WM_USER + 101, 0, 0L);
|
||||
|
||||
//
|
||||
// Display a dialog to monitor the progress
|
||||
//
|
||||
dialog.DoModal ();
|
||||
bool ret_val = info->result;
|
||||
delete info;
|
||||
return ret_val;
|
||||
}
|
||||
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// OnCommand
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
BOOL
|
||||
CW3DUpdateDlg::OnCommand
|
||||
(
|
||||
WPARAM wParam,
|
||||
LPARAM lParam
|
||||
)
|
||||
{
|
||||
for (int index = 0; index < APP_MAX; index ++) {
|
||||
const APP_INFO &app_info = APPLICATIONS[index];
|
||||
|
||||
if (LOWORD (wParam) == app_info.ctrl_id) {
|
||||
|
||||
//
|
||||
// Enable or disable the clean and directory buttons
|
||||
//
|
||||
bool enable = (SendDlgItemMessage (LOWORD(wParam), BM_GETCHECK) == 1);
|
||||
::EnableWindow (::GetDlgItem (m_hWnd, app_info.clean_ctrl_id), enable);
|
||||
::EnableWindow (::GetDlgItem (m_hWnd, app_info.dir_ctrl_id), enable);
|
||||
|
||||
} else if (LOWORD (wParam) == app_info.dir_ctrl_id) {
|
||||
|
||||
//
|
||||
// Change the installation directoy
|
||||
//
|
||||
CString directory;
|
||||
CString dlg_title;
|
||||
dlg_title.Format ("Select a directory to install the %s to.", app_info.title);
|
||||
if (Get_Install_Directory (m_hWnd, dlg_title, directory)) {
|
||||
SetDlgItemText (app_info.dir_ctrl_id, directory);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return CDialog::OnCommand(wParam, lParam);
|
||||
}
|
||||
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// OnDefaults
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
void
|
||||
CW3DUpdateDlg::OnDefaults (void)
|
||||
{
|
||||
for (int index = 0; index < APP_MAX; index ++) {
|
||||
const APP_INFO &app_info = APPLICATIONS[index];
|
||||
|
||||
if (SendDlgItemMessage (app_info.ctrl_id, BM_GETCHECK) != 0) {
|
||||
SetDlgItemText (app_info.dir_ctrl_id, app_info.default_dir);
|
||||
}
|
||||
}
|
||||
|
||||
return ;
|
||||
}
|
||||
|
||||
void CW3DUpdateDlg::RegisterShellExt()
|
||||
{
|
||||
HKEY reg_key;
|
||||
CString reg_key_name(MAKEINTRESOURCE(IDS_SHELLEXT_CLSID));
|
||||
CString reg_value(MAKEINTRESOURCE(IDS_SHELLEXT_NAME));
|
||||
CString value_name;
|
||||
//[HKEY_CLASSES_ROOT\CLSID\{556F8779-49C4-4e88-9CEF-0AC2CFD6B763}]
|
||||
DWORD ret_val = ::RegCreateKeyEx (HKEY_CLASSES_ROOT,reg_key_name,0L,NULL,REG_OPTION_NON_VOLATILE,KEY_ALL_ACCESS,NULL,®_key,NULL);
|
||||
if (ERROR_SUCCESS == ret_val) {
|
||||
// @="W3D Shell Extension"
|
||||
ret_val = ::RegSetValueEx(reg_key,"",0L,REG_SZ,(BYTE *)(LPCTSTR)reg_value,reg_value.GetLength () + 1);
|
||||
}
|
||||
//[HKEY_CLASSES_ROOT\CLSID\{556F8779-49C4-4e88-9CEF-0AC2CFD6B763}\InProcServer32]
|
||||
::RegCloseKey (reg_key);
|
||||
reg_key_name += "\\InProcServer32";
|
||||
ret_val = ::RegCreateKeyEx (HKEY_CLASSES_ROOT,reg_key_name,0L,NULL,REG_OPTION_NON_VOLATILE,KEY_ALL_ACCESS,NULL,®_key,NULL);
|
||||
if (ERROR_SUCCESS == ret_val){
|
||||
//@="W3Dshellext.dll"
|
||||
reg_value.LoadString(IDS_SHELLEXT_DLLNAME);
|
||||
ret_val = ::RegSetValueEx(reg_key, "",0L,REG_SZ,(BYTE *)(LPCTSTR)reg_value,reg_value.GetLength () + 1);
|
||||
//"ThreadingModel"="Apartment"
|
||||
reg_value.LoadString(IDS_W3DSHELLEXT_APARTMENT);
|
||||
value_name.LoadString(IDS_W3DSHELLEXT_THMODEL);
|
||||
ret_val = ::RegSetValueEx(reg_key, value_name,0L,REG_SZ,(BYTE *)(LPCTSTR)reg_value,reg_value.GetLength () + 1);
|
||||
}
|
||||
::RegCloseKey (reg_key);
|
||||
//[HKEY_CLASSES_ROOT\.w3d]
|
||||
reg_key_name.LoadString(IDS_W3DFILEEXT);
|
||||
ret_val = ::RegCreateKeyEx (HKEY_CLASSES_ROOT,reg_key_name,0L,NULL,REG_OPTION_NON_VOLATILE,KEY_ALL_ACCESS,NULL,®_key,NULL);
|
||||
if (ERROR_SUCCESS == ret_val) {
|
||||
//@="W3DFile"
|
||||
reg_value.LoadString(IDS_W3DFILETEXT);
|
||||
ret_val = ::RegSetValueEx(reg_key, "",0L,REG_SZ,(BYTE *)(LPCTSTR)reg_value,reg_value.GetLength () + 1);
|
||||
}
|
||||
::RegCloseKey (reg_key);
|
||||
//[HKEY_CLASSES_ROOT\W3DFile]
|
||||
reg_key_name.LoadString(IDS_W3DFILEKEY);
|
||||
ret_val = ::RegCreateKeyEx (HKEY_CLASSES_ROOT,reg_key_name,0L,NULL,REG_OPTION_NON_VOLATILE,KEY_ALL_ACCESS,NULL,®_key,NULL);
|
||||
if (ERROR_SUCCESS == ret_val) {
|
||||
//@="Shell Extension file"
|
||||
reg_value.LoadString(IDS_W3DSHELLEXT_TEXT);
|
||||
ret_val = ::RegSetValueEx(reg_key, "",0L,REG_SZ,(BYTE *)(LPCTSTR)reg_value,reg_value.GetLength () + 1);
|
||||
}
|
||||
::RegCloseKey (reg_key);
|
||||
//[HKEY_CLASSES_ROOT\W3DFile\shellex\ContextMenuHandlers]
|
||||
reg_key_name.LoadString(IDS_CTXMENUHANDLERS);
|
||||
ret_val = ::RegCreateKeyEx (HKEY_CLASSES_ROOT,reg_key_name,0L,NULL,REG_OPTION_NON_VOLATILE,KEY_ALL_ACCESS,NULL,®_key,NULL);
|
||||
if (ERROR_SUCCESS == ret_val) {
|
||||
//@="W3DCtxMenu"
|
||||
reg_value.LoadString(IDS_W3DMENU_TEXT);
|
||||
ret_val = ::RegSetValueEx(reg_key, "",0L,REG_SZ,(BYTE *)(LPCTSTR)reg_value,reg_value.GetLength () + 1);
|
||||
}
|
||||
::RegCloseKey (reg_key);
|
||||
//[HKEY_CLASSES_ROOT\W3DFile\shellex\ContextMenuHandlers\W3DCtxMenu]
|
||||
reg_key_name.LoadString(IDS_W3DCTXMENU_KEY);
|
||||
ret_val = ::RegCreateKeyEx (HKEY_CLASSES_ROOT,reg_key_name,0L,NULL,REG_OPTION_NON_VOLATILE,KEY_ALL_ACCESS,NULL,®_key,NULL);
|
||||
if (ERROR_SUCCESS == ret_val) {
|
||||
//@="{556F8779-49C4-4e88-9CEF-0AC2CFD6B763}"
|
||||
reg_value.LoadString(IDS_W3DSHELLEXT_GUID);
|
||||
ret_val = ::RegSetValueEx(reg_key, "",0L,REG_SZ,(BYTE *)(LPCTSTR)reg_value,reg_value.GetLength () + 1);
|
||||
}
|
||||
::RegCloseKey (reg_key);
|
||||
//[HKEY_CLASSES_ROOT\W3DFile\shellex\PropertySheetHandlers]
|
||||
reg_key_name.LoadString(IDS_W3DPROPSHEETHANDLERS);
|
||||
ret_val = ::RegCreateKeyEx (HKEY_CLASSES_ROOT,reg_key_name,0L,NULL,REG_OPTION_NON_VOLATILE,KEY_ALL_ACCESS,NULL,®_key,NULL);
|
||||
if (ERROR_SUCCESS == ret_val) {
|
||||
//@="W3DPropertyPage"
|
||||
reg_value.LoadString(IDS_W3DPROPPAGE_TEXT);
|
||||
ret_val = ::RegSetValueEx(reg_key, "",0L,REG_SZ,(BYTE *)(LPCTSTR)reg_value,reg_value.GetLength () + 1);
|
||||
}
|
||||
::RegCloseKey (reg_key);
|
||||
//[HKEY_CLASSES_ROOT\W3DFile\shellex\PropertySheetHandlers\W3DPropertyPage]
|
||||
reg_key_name.LoadString(IDS_W3DPROPPAGE_KEY);
|
||||
ret_val = ::RegCreateKeyEx (HKEY_CLASSES_ROOT,reg_key_name,0L,NULL,REG_OPTION_NON_VOLATILE,KEY_ALL_ACCESS,NULL,®_key,NULL);
|
||||
if (ERROR_SUCCESS == ret_val) {
|
||||
//@="{556F8779-49C4-4e88-9CEF-0AC2CFD6B763}"
|
||||
reg_value.LoadString(IDS_W3DSHELLEXT_GUID);
|
||||
ret_val = ::RegSetValueEx(reg_key, "",0L,REG_SZ,(BYTE *)(LPCTSTR)reg_value,reg_value.GetLength () + 1);
|
||||
}
|
||||
::RegCloseKey (reg_key);
|
||||
//[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Shell Extensions\Approved]
|
||||
reg_key_name.LoadString(IDS_MSEXTENSIONS_KEY);
|
||||
ret_val = ::RegCreateKeyEx (HKEY_LOCAL_MACHINE,reg_key_name,0L,NULL,REG_OPTION_NON_VOLATILE,KEY_ALL_ACCESS,NULL,®_key,NULL);
|
||||
if (ERROR_SUCCESS == ret_val) {
|
||||
//"{556F8779-49C4-4e88-9CEF-0AC2CFD6B763}"="W3D Shell Extension"
|
||||
value_name.LoadString(IDS_W3DSHELLEXT_GUID);
|
||||
reg_value.LoadString(IDS_W3DSHELLEXT_TEXT);
|
||||
ret_val = ::RegSetValueEx(reg_key, value_name,0L,REG_SZ,(BYTE *)(LPCTSTR)reg_value,reg_value.GetLength () + 1);
|
||||
}
|
||||
::RegCloseKey (reg_key);
|
||||
//[HKEY_CLASSES_ROOT\W3DFile\\DefaultIcon
|
||||
reg_key_name.LoadString(IDS_W3DDEFAULTICON_KEY);
|
||||
ret_val = ::RegCreateKeyEx (HKEY_CLASSES_ROOT,reg_key_name,0L,NULL,REG_OPTION_NON_VOLATILE,KEY_ALL_ACCESS,NULL,®_key,NULL);
|
||||
if (ERROR_SUCCESS == ret_val) {
|
||||
//%SystemRoot%\\system32\\W3DShellExt.dll,0
|
||||
reg_value.LoadString(IDS_W3DDEFAULTICON_TEXT);
|
||||
ret_val = ::RegSetValueEx(reg_key, "",0L,REG_SZ,(BYTE *)(LPCTSTR)reg_value,reg_value.GetLength () + 1);
|
||||
}
|
||||
SHChangeNotify(SHCNE_ASSOCCHANGED,SHCNF_IDLIST ,NULL,NULL);
|
||||
}
|
||||
|
||||
void CW3DUpdateDlg::RegisterViewer(int index){
|
||||
HKEY reg_key;
|
||||
CString reg_key_name(MAKEINTRESOURCE(IDS_OPENWITH));
|
||||
CString dest_path;
|
||||
Get_Destination_Path(index, dest_path);
|
||||
CString reg_value(MAKEINTRESOURCE(IDS_VIEWERCOMMAND));
|
||||
reg_value = dest_path + reg_value;
|
||||
//[HKEY_CLASSES_ROOT\CLSID\{556F8779-49C4-4e88-9CEF-0AC2CFD6B763}]
|
||||
DWORD ret_val = ::RegCreateKeyEx (HKEY_CLASSES_ROOT,reg_key_name,0L,NULL,REG_OPTION_NON_VOLATILE,KEY_ALL_ACCESS,NULL,®_key,NULL);
|
||||
if (ERROR_SUCCESS == ret_val) {
|
||||
// @="W3D Shell Extension"
|
||||
ret_val = ::RegSetValueEx(reg_key,"",0L,REG_SZ,(BYTE *)(LPCTSTR)reg_value,reg_value.GetLength () + 1);
|
||||
}
|
||||
|
||||
}
|
||||
79
Code/Tools/W3DUpdate/W3DUpdateDlg.h
Normal file
79
Code/Tools/W3DUpdate/W3DUpdateDlg.h
Normal file
@@ -0,0 +1,79 @@
|
||||
/*
|
||||
** Command & Conquer Renegade(tm)
|
||||
** Copyright 2025 Electronic Arts Inc.
|
||||
**
|
||||
** This program is free software: you can redistribute it and/or modify
|
||||
** it under the terms of the GNU General Public License as published by
|
||||
** the Free Software Foundation, either version 3 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
// W3DUpdateDlg.h : header file
|
||||
//
|
||||
|
||||
#if !defined(AFX_W3DUPDATEDLG_H__4305AC50_1EAB_11D3_A038_00104B791122__INCLUDED_)
|
||||
#define AFX_W3DUPDATEDLG_H__4305AC50_1EAB_11D3_A038_00104B791122__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// CW3DUpdateDlg dialog
|
||||
|
||||
class CW3DUpdateDlg : public CDialog
|
||||
{
|
||||
// Construction
|
||||
public:
|
||||
void RegisterViewer(int index);
|
||||
void RegisterShellExt();
|
||||
CW3DUpdateDlg(CWnd* pParent = NULL); // standard constructor
|
||||
|
||||
// Dialog Data
|
||||
//{{AFX_DATA(CW3DUpdateDlg)
|
||||
enum { IDD = IDD_W3DUPDATE_DIALOG };
|
||||
// NOTE: the ClassWizard will add data members here
|
||||
//}}AFX_DATA
|
||||
|
||||
// ClassWizard generated virtual function overrides
|
||||
//{{AFX_VIRTUAL(CW3DUpdateDlg)
|
||||
protected:
|
||||
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
|
||||
virtual BOOL OnCommand(WPARAM wParam, LPARAM lParam);
|
||||
//}}AFX_VIRTUAL
|
||||
|
||||
// Implementation
|
||||
protected:
|
||||
HICON m_hIcon;
|
||||
|
||||
// Generated message map functions
|
||||
//{{AFX_MSG(CW3DUpdateDlg)
|
||||
virtual BOOL OnInitDialog();
|
||||
afx_msg void OnPaint();
|
||||
afx_msg HCURSOR OnQueryDragIcon();
|
||||
virtual void OnOK();
|
||||
afx_msg void OnDefaults();
|
||||
//}}AFX_MSG
|
||||
DECLARE_MESSAGE_MAP()
|
||||
|
||||
private:
|
||||
|
||||
///////////////////////////////////////////////////////////////
|
||||
// Private methods
|
||||
///////////////////////////////////////////////////////////////
|
||||
void Get_Destination_Path (int app_id, CString &dest_path);
|
||||
bool Install_App (const CString &title, const CString &src_path, const CString &dest_path, const CString ®_key_name, bool clean);
|
||||
};
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_W3DUPDATEDLG_H__4305AC50_1EAB_11D3_A038_00104B791122__INCLUDED_)
|
||||
BIN
Code/Tools/W3DUpdate/res/Filecopy.avi
Normal file
BIN
Code/Tools/W3DUpdate/res/Filecopy.avi
Normal file
Binary file not shown.
BIN
Code/Tools/W3DUpdate/res/W3DUpdate.ico
Normal file
BIN
Code/Tools/W3DUpdate/res/W3DUpdate.ico
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.1 KiB |
13
Code/Tools/W3DUpdate/res/W3DUpdate.rc2
Normal file
13
Code/Tools/W3DUpdate/res/W3DUpdate.rc2
Normal file
@@ -0,0 +1,13 @@
|
||||
//
|
||||
// W3DUPDATE.RC2 - resources Microsoft Visual C++ does not edit directly
|
||||
//
|
||||
|
||||
#ifdef APSTUDIO_INVOKED
|
||||
#error this file is not editable by Microsoft Visual C++
|
||||
#endif //APSTUDIO_INVOKED
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Add manually edited resources here...
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
BIN
Code/Tools/W3DUpdate/res/icon1.ico
Normal file
BIN
Code/Tools/W3DUpdate/res/icon1.ico
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 766 B |
76
Code/Tools/W3DUpdate/resource.h
Normal file
76
Code/Tools/W3DUpdate/resource.h
Normal file
@@ -0,0 +1,76 @@
|
||||
//{{NO_DEPENDENCIES}}
|
||||
// Microsoft Developer Studio generated include file.
|
||||
// Used by W3DUpdate.rc
|
||||
//
|
||||
#define IDS_COPYFAIL 1
|
||||
#define IDS_SYSTEMDLL 2
|
||||
#define IDC_DEFAULTS 3
|
||||
#define IDS_SHELLEXT_CLSID 3
|
||||
#define IDS_SHELLEXT_NAME 4
|
||||
#define IDS_SHELLEXT_DLLNAME 5
|
||||
#define IDS_W3DSHELLEXT_THMODEL 6
|
||||
#define IDS_W3DSHELLEXT_APARTMENT 7
|
||||
#define IDS_W3DFILEEXT 8
|
||||
#define IDS_W3DFILETEXT 9
|
||||
#define IDS_W3DFILEKEY 10
|
||||
#define IDS_CTXMENUHANDLERS 11
|
||||
#define IDS_W3DMENU_TEXT 12
|
||||
#define IDS_W3DCTXMENU_KEY 13
|
||||
#define IDS_W3DSHELLEXT_GUID 14
|
||||
#define IDS_W3DPROPSHEETHANDLERS 15
|
||||
#define IDS_W3DPROPPAGE_TEXT 16
|
||||
#define IDS_W3DPROPPAGE_KEY 17
|
||||
#define IDS_MSEXTENSIONS_KEY 18
|
||||
#define IDS_W3DSHELLEXT_TEXT 19
|
||||
#define IDS_W3DDEFAULTICON_TEXT 20
|
||||
#define IDS_W3DDEFAULTICON_KEY 21
|
||||
#define IDS_OPENWITH 22
|
||||
#define IDS_VIEWERCOMMAND 23
|
||||
#define IDS_GMAXRENX_PATH 24
|
||||
#define IDD_W3DUPDATE_DIALOG 102
|
||||
#define IDD_FILE_COPY 103
|
||||
#define IDR_MAINFRAME 128
|
||||
#define IDI_COPY 129
|
||||
#define IDR_FILECOPY_AVI 129
|
||||
#define IDC_EDITOR_CHECK 1000
|
||||
#define IDC_ANIMATE_CTRL 1000
|
||||
#define IDC_GAME_CHECK 1001
|
||||
#define IDC_FILENAME_TEXT 1001
|
||||
#define IDC_PLUGIN_CHECK 1001
|
||||
#define IDC_VIEWER_CHECK 1002
|
||||
#define IDC_CURRENT_APP 1002
|
||||
#define IDC_MAX_PLUGIN_CHECK 1003
|
||||
#define IDC_MAX4_PLUGIN_CHECK 1003
|
||||
#define IDC_EDITOR_CLEAN_CHECK 1004
|
||||
#define IDC_GMAX_CHECK 1004
|
||||
#define IDC_GAME_CLEAN_CHECK 1005
|
||||
#define IDC_PLUGIN_CLEAN_CHECK 1005
|
||||
#define IDC_VIEWER_CLEAN_CHECK 1006
|
||||
#define IDC_WDUMP_CHECK 1007
|
||||
#define IDC_MAX_PLUGIN_CLEAN_CHECK 1008
|
||||
#define IDC_RENEGDAZZLE_CHECK 1008
|
||||
#define IDC_WDUMP_CLEAN_CHECK 1009
|
||||
#define IDC_LIGHTMAP_CHECK 1010
|
||||
#define IDC_MAX4_PLUGIN_CLEAN_CHECK 1010
|
||||
#define IDC_LIGHTMAP_CLEAN_CHECK 1011
|
||||
#define IDC_W3DSHELLEXT 1011
|
||||
#define IDC_EDITOR_DIR_BUTTON 1012
|
||||
#define IDC_VIEWER_DIR_BUTTON 1012
|
||||
#define IDC_GMAX_CLEAN_CHECK2 1013
|
||||
#define IDC_GAME_DIR_BUTTON 1014
|
||||
#define IDC_PLUGIN_DIR_BUTTON 1014
|
||||
#define IDC_MAX4_PLUGIN_DIR_BUTTON 1015
|
||||
#define IDC_LIGHTMAP_DIR_BUTTON 1018
|
||||
#define IDC_WDUMP_DIR_BUTTON 1018
|
||||
#define IDD_DIR_SELECT_DIALOG 1019
|
||||
|
||||
// Next default values for new objects
|
||||
//
|
||||
#ifdef APSTUDIO_INVOKED
|
||||
#ifndef APSTUDIO_READONLY_SYMBOLS
|
||||
#define _APS_NEXT_RESOURCE_VALUE 130
|
||||
#define _APS_NEXT_COMMAND_VALUE 32771
|
||||
#define _APS_NEXT_CONTROL_VALUE 1013
|
||||
#define _APS_NEXT_SYMED_VALUE 101
|
||||
#endif
|
||||
#endif
|
||||
Reference in New Issue
Block a user