Windows NT 4.0 source code leak
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

117 lines
3.2 KiB

4 years ago
  1. /***************************************************************************/
  2. /** Microsoft Windows **/
  3. /** Copyright(c) Microsoft Corp., 1994 **/
  4. /***************************************************************************/
  5. /****************************************************************************
  6. BugBoard.h
  7. Apr 94 JimH
  8. Main header file for BugBoard
  9. ****************************************************************************/
  10. #ifndef BUGBOARD_INC
  11. #define BUGBOARD_INC
  12. #define STRICT
  13. #include <windows.h>
  14. #include <winbase.h>
  15. #include <nddeapi.h>
  16. #include <shellapi.h>
  17. #include <time.h>
  18. //#include <stdio.h>
  19. #include <stdlib.h>
  20. #include "resource.h"
  21. #include "pdde.h"
  22. #include "resstr.h"
  23. #include "regentry.h"
  24. const int BUFSIZE = 4096 - sizeof(time_t);
  25. const int PWLEN = 20;
  26. const WORD TIMER_RECONNECT = 1;
  27. // Convenient way to turn a resource string into a const char *
  28. #define RS(n) ResString(hInst, n)
  29. // Global variables
  30. extern HINSTANCE hInst;
  31. extern HWND hMainWnd;
  32. extern BOOL bConnected; // is client currently connected?
  33. extern BOOL bEditing; // currently editing board?
  34. extern BOOL bServer; // am I a DDE server?
  35. extern BOOL bAuthenticated; // have I entered the correct password?
  36. extern BOOL bRestoreOnUpdate; // option selected?
  37. extern BOOL bSoundOnUpdate; //
  38. extern BOOL bIgnoreClose; // close, or was it just Esc pressed?
  39. extern int nConnections; // server displays connection count
  40. extern int nSelStart, nSelEnd; // change selection
  41. extern char *pBuf; // always points to BUGDATA.pBugString
  42. extern char *pOldBuf;
  43. extern char szPassword[PWLEN];
  44. extern char szMill[30]; // connectable form
  45. extern char szServerName[22]; // displayable form
  46. extern DDE *dde;
  47. extern DDEClient *ddeClient;
  48. extern DDEServer *ddeServer;
  49. extern const char szAppName[];
  50. extern const char szFileName[];
  51. extern const char szServer[], szTopic[], szNewBug[], szOldBug[], szPW[];
  52. extern const char szRegPath[], szRegX[], szRegY[], szRegRestore[];
  53. extern const char szRegServer[], szRegMill[], szRegSound[], szRegTime[];
  54. extern HSZ hszNewBug, hszOldBug, hszPW;
  55. // This is the data block that gets transferred between client and server
  56. typedef struct {
  57. time_t aclock;
  58. char pBugString[BUFSIZE];
  59. } BUGDATA;
  60. extern BUGDATA *pBugData;
  61. // Function prototypes
  62. long FAR PASCAL WndProc(HWND, UINT, WPARAM, LPARAM);
  63. BOOL CALLBACK Find(HWND, UINT, WPARAM, LPARAM);
  64. BOOL CALLBACK Password(HWND, UINT, WPARAM, LPARAM);
  65. void CheckNddeShare(void);
  66. void Code(char far *pstring);
  67. BOOL InitializeDDE(LPSTR lpszCmdLine);
  68. void InitializeMenu(HMENU hMenu);
  69. BOOL IsNddeActive(void);
  70. void OnEdit(HWND hWnd, LPARAM bValid);
  71. void OnTime(HWND hWnd, LPARAM bValid);
  72. void OnClose(HWND hWnd);
  73. void OnInitMenu(HMENU hMenu);
  74. void OnTimer(HWND hWnd, WORD wTimerID);
  75. void PositionWindow(HWND hWnd);
  76. void ReadFile(void);
  77. void SaveFile(void);
  78. void SetClientText(void);
  79. void SetServerText(void);
  80. #endif // BUGBOARD_INC