vidinit.cpp 2.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192
  1. /*
  2. ** Command & Conquer Renegade(tm)
  3. ** Copyright 2025 Electronic Arts Inc.
  4. **
  5. ** This program is free software: you can redistribute it and/or modify
  6. ** it under the terms of the GNU General Public License as published by
  7. ** the Free Software Foundation, either version 3 of the License, or
  8. ** (at your option) any later version.
  9. **
  10. ** This program is distributed in the hope that it will be useful,
  11. ** but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. ** GNU General Public License for more details.
  14. **
  15. ** You should have received a copy of the GNU General Public License
  16. ** along with this program. If not, see <http://www.gnu.org/licenses/>.
  17. */
  18. // vidinit.cpp : Defines the class behaviors for the application.
  19. //
  20. #include "stdafx.h"
  21. #include "vidinit.h"
  22. #include "vidinitDlg.h"
  23. #ifdef _DEBUG
  24. #define new DEBUG_NEW
  25. #undef THIS_FILE
  26. static char THIS_FILE[] = __FILE__;
  27. #endif
  28. /////////////////////////////////////////////////////////////////////////////
  29. // CVidinitApp
  30. BEGIN_MESSAGE_MAP(CVidinitApp, CWinApp)
  31. //{{AFX_MSG_MAP(CVidinitApp)
  32. // NOTE - the ClassWizard will add and remove mapping macros here.
  33. // DO NOT EDIT what you see in these blocks of generated code!
  34. //}}AFX_MSG
  35. ON_COMMAND(ID_HELP, CWinApp::OnHelp)
  36. END_MESSAGE_MAP()
  37. /////////////////////////////////////////////////////////////////////////////
  38. // CVidinitApp construction
  39. CVidinitApp::CVidinitApp():
  40. WindowIsClosing(false)
  41. {
  42. // TODO: add construction code here,
  43. // Place all significant initialization in InitInstance
  44. }
  45. /////////////////////////////////////////////////////////////////////////////
  46. // The one and only CVidinitApp object
  47. CVidinitApp theApp;
  48. /////////////////////////////////////////////////////////////////////////////
  49. // CVidinitApp initialization
  50. BOOL CVidinitApp::InitInstance()
  51. {
  52. // Standard initialization
  53. // If you are not using these features and wish to reduce the size
  54. // of your final executable, you should remove from the following
  55. // the specific initialization routines you do not need.
  56. #ifdef _AFXDLL
  57. Enable3dControls(); // Call this when using MFC in a shared DLL
  58. #else
  59. Enable3dControlsStatic(); // Call this when linking to MFC statically
  60. #endif
  61. CVidinitDlg dlg(NULL);
  62. m_pMainWnd = &dlg;
  63. int nResponse = dlg.DoModal();
  64. if (nResponse == IDOK)
  65. {
  66. // TODO: Place code here to handle when the dialog is
  67. // dismissed with OK
  68. }
  69. else if (nResponse == IDCANCEL)
  70. {
  71. // TODO: Place code here to handle when the dialog is
  72. // dismissed with Cancel
  73. }
  74. // Since the dialog has been closed, return FALSE so that we exit the
  75. // application, rather than start the application's message pump.
  76. return FALSE;
  77. }