InputDlg.h 3.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. /*
  2. ** Command & Conquer Generals Zero Hour(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. /***********************************************************************************************
  19. *** C O N F I D E N T I A L --- W E S T W O O D S T U D I O S ***
  20. ***********************************************************************************************
  21. * *
  22. * Project Name : G *
  23. * *
  24. * $Archive:: /Commando/Code/Tools/max2w3d/InputDlg.h $*
  25. * *
  26. * $Author:: Andre_a $*
  27. * *
  28. * $Modtime:: 5/08/00 1:36p $*
  29. * *
  30. * $Revision:: 1 $*
  31. * *
  32. *---------------------------------------------------------------------------------------------*
  33. * Functions: *
  34. * - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
  35. #ifndef INPUTDLG_H
  36. #define INPUTDLG_H
  37. #include "dllmain.h"
  38. #include "resource.h"
  39. /////////////////////////////////////////////////////////////////////////////
  40. // InputDlg dialog - a generic input box for MAXScript
  41. class InputDlg
  42. {
  43. friend BOOL CALLBACK _thunk_dialog_proc (HWND, UINT, WPARAM, LPARAM);
  44. public:
  45. // Construction
  46. InputDlg (HWND hWndParent=NULL);
  47. // Methods
  48. int DoModal (void); // returns IDOK or IDCANCEL
  49. void SetCaption (const char *caption);
  50. void SetLabel (const char *label);
  51. void SetValue (const char *value);
  52. // DialogProc
  53. BOOL CALLBACK DialogProc (HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam);
  54. // Dialog data associated with GUI components.
  55. char m_Value[1024]; // edit box
  56. char m_Label[512]; // description label
  57. char m_Caption[128]; // dialog caption
  58. protected:
  59. // Dialog data
  60. enum { IDD = IDD_INPUT_DIALOG };
  61. HWND m_hWnd;
  62. HWND m_hWndParent;
  63. // Message Handlers
  64. LRESULT OnInitDialog (WPARAM wParam, LPARAM lParam);
  65. BOOL OnOK (void);
  66. };
  67. #endif