DebuggerApp.h 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109
  1. /*
  2. ===========================================================================
  3. Doom 3 GPL Source Code
  4. Copyright (C) 1999-2011 id Software LLC, a ZeniMax Media company.
  5. This file is part of the Doom 3 GPL Source Code (?Doom 3 Source Code?).
  6. Doom 3 Source Code is free software: you can redistribute it and/or modify
  7. it under the terms of the GNU General Public License as published by
  8. the Free Software Foundation, either version 3 of the License, or
  9. (at your option) any later version.
  10. Doom 3 Source Code 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. You should have received a copy of the GNU General Public License
  15. along with Doom 3 Source Code. If not, see <http://www.gnu.org/licenses/>.
  16. In addition, the Doom 3 Source Code is also subject to certain additional terms. You should have received a copy of these additional terms immediately following the terms and conditions of the GNU General Public License which accompanied the Doom 3 Source Code. If not, please request a copy in writing from id Software at the address below.
  17. If you have questions concerning this license or the applicable additional terms, you may contact in writing id Software LLC, c/o ZeniMax Media Inc., Suite 120, Rockville, Maryland 20850 USA.
  18. ===========================================================================
  19. */
  20. #ifndef DEBUGGERAPP_H_
  21. #define DEBUGGERAPP_H_
  22. #include "../../sys/win32/win_local.h"
  23. #include "../../framework/sync/Msg.h"
  24. #ifndef REGISTRYOPTIONS_H_
  25. #include "../common/RegistryOptions.h"
  26. #endif
  27. #ifndef DEBUGGERWINDOW_H_
  28. #include "DebuggerWindow.h"
  29. #endif
  30. #ifndef DEBUGGERMESSAGES_H_
  31. #include "DebuggerMessages.h"
  32. #endif
  33. #ifndef DEBUGGERCLIENT_H_
  34. #include "DebuggerClient.h"
  35. #endif
  36. // These were changed to static by ID so to make it easy we just throw them
  37. // in this header
  38. const int MAX_MSGLEN = 1400;
  39. class rvDebuggerApp
  40. {
  41. public:
  42. rvDebuggerApp ( );
  43. bool Initialize ( HINSTANCE hInstance );
  44. int Run ( void );
  45. rvRegistryOptions& GetOptions ( void );
  46. rvDebuggerClient& GetClient ( void );
  47. rvDebuggerWindow& GetWindow ( void );
  48. HINSTANCE GetInstance ( void );
  49. bool TranslateAccelerator ( LPMSG msg );
  50. protected:
  51. rvRegistryOptions mOptions;
  52. rvDebuggerWindow* mDebuggerWindow;
  53. HINSTANCE mInstance;
  54. rvDebuggerClient mClient;
  55. HACCEL mAccelerators;
  56. private:
  57. bool ProcessNetMessages ( void );
  58. bool ProcessWindowMessages ( void );
  59. };
  60. ID_INLINE HINSTANCE rvDebuggerApp::GetInstance ( void )
  61. {
  62. return mInstance;
  63. }
  64. ID_INLINE rvDebuggerClient& rvDebuggerApp::GetClient ( void )
  65. {
  66. return mClient;
  67. }
  68. ID_INLINE rvRegistryOptions& rvDebuggerApp::GetOptions ( void )
  69. {
  70. return mOptions;
  71. }
  72. ID_INLINE rvDebuggerWindow& rvDebuggerApp::GetWindow ( void )
  73. {
  74. assert ( mDebuggerWindow );
  75. return *mDebuggerWindow;
  76. }
  77. extern rvDebuggerApp gDebuggerApp;
  78. #endif // DEBUGGERAPP_H_