Annotation of mstools/samples/ddeml/server/server.h, revision 1.1.1.2

1.1       root        1: #include <windows.h>
                      2: #include <ddeml.h>
                      3: 
                      4: #define IDM_ABOUT 100
                      5: #define IDM_BLOCKALLCBS 200
                      6: #define IDM_ENABLEONECB 201
                      7: #define IDM_BLOCKNEXTCB 202
                      8: #define IDM_TERMNEXTCB  203
                      9: #define IDM_RUNAWAY     204
                     10: #define IDM_CHANGEDATA  205
                     11: #define IDM_RENDERDELAY 206
                     12: #define IDM_SETTOPIC    207
                     13: #define IDM_SETSERVER   208
                     14: #define IDM_UNBLOCKALLCBS 209
                     15: #define IDM_HELP        210
                     16: #define IDM_CONTEXT     211
                     17: #define IDM_APPOWNED    212
                     18: 
                     19: #define IDS_BADLENGTH   1
                     20: 
                     21: #define MAX_TOPIC       20
                     22: #define MAX_COMMENT     40
                     23: #define MAX_EXEC        40
                     24: #define CCHARS          80
                     25: #define CLINES          40
                     26: 
                     27: #define UM_CHGDATA      (WM_USER + 435)
                     28: 
                     29: #define CSYSTEMITEMS 4
                     30: #define CTESTITEMS  4
                     31: #define CTOPICS     2
                     32: 
                     33: #include "dialog.h"
                     34: 
                     35: /****** Structrues ******/
                     36: 
                     37: // predefined format list item
                     38: 
                     39: typedef struct {
                     40:     ATOM atom;
                     41:     PSTR sz;
                     42: } FORMATINFO;
                     43: #define CFORMATS 3
                     44: 
                     45: extern FORMATINFO aFormats[];
                     46: 
                     47: typedef struct _XFERINFO {
1.1.1.2 ! root       48:     UINT wType;
        !            49:     UINT wFmt;
1.1       root       50:     HCONV hConv;
                     51:     HSZ hszTopic;
                     52:     HSZ hszItem;
                     53:     HDDEDATA hData;
                     54:     DWORD lData1;
                     55:     DWORD lData2;
                     56: } XFERINFO;
                     57: typedef XFERINFO *PXFERINFO;
                     58: 
                     59: typedef struct _ITEMLIST {
                     60:     HSZ hszItem;
                     61:     HDDEDATA (*npfnCallback)(PXFERINFO, WORD);
                     62:     PSTR pszItem;
                     63: } ITEMLIST;
                     64: 
                     65: typedef struct _TOPICLIST {
                     66:     HSZ hszTopic;
                     67:     ITEMLIST *pItemList;
1.1.1.2 ! root       68:     UINT cItems;
1.1       root       69:     PSTR pszTopic;
                     70: } TOPICLIST;
                     71: 
                     72: typedef struct {    // used to passinfo to/from TextDataEntryDlgProc and
                     73:     HDDEDATA hDdeData;
1.1.1.2 ! root       74:     UINT wFmt;
1.1       root       75:     HSZ hszItem;
                     76: } XACT;
                     77: 
                     78: 
                     79: 
                     80: // GLOBALS
                     81: 
                     82: extern DWORD idInst;
                     83: extern CONVCONTEXT CCFilter;
                     84: extern HANDLE hInst;
                     85: extern HWND hwndServer;
                     86: extern RECT rcRand;
                     87: extern RECT rcCount;
                     88: extern RECT rcComment;
                     89: extern RECT rcExec;
                     90: extern RECT rcConnCount;
                     91: extern RECT rcRndrDelay;
                     92: extern RECT rcRunaway;
                     93: extern RECT rcAllBlock;
                     94: extern RECT rcNextAction;
                     95: extern RECT rcHugeSize;
                     96: extern RECT rcAppowned;
                     97: extern BOOL fAllBlocked;
                     98: extern BOOL fAllEnabled;
                     99: extern BOOL fEnableOneCB;
                    100: extern BOOL fBlockNextCB;
                    101: extern BOOL fTermNextCB;
                    102: extern BOOL fAppowned;
                    103: extern WORD cRunaway;
                    104: extern WORD RenderDelay;
                    105: extern DWORD count;
                    106: extern HSZ hszAppName;
                    107: extern CHAR szClass[];
                    108: extern CHAR szTopic[MAX_TOPIC];
                    109: extern CHAR szServer[MAX_TOPIC];
                    110: extern CHAR szComment[MAX_COMMENT];
                    111: extern CHAR szExec[MAX_EXEC];
                    112: extern CHAR *pszComment;
                    113: extern WORD seed;
                    114: extern WORD cyText;
                    115: extern WORD cServers;
                    116: extern HDDEDATA hDataHelp[CFORMATS];
                    117: extern HDDEDATA hDataCount[CFORMATS];
                    118: extern HDDEDATA hDataRand[CFORMATS];
                    119: extern HDDEDATA hDataHuge[CFORMATS];
                    120: extern DWORD cbHuge;
                    121: 
                    122: extern CHAR szDdeHelp[];
                    123: extern FORMATINFO aFormats[CFORMATS];
                    124: extern ITEMLIST SystemTopicItemList[CSYSTEMITEMS];
                    125: extern ITEMLIST TestTopicItemList[CTESTITEMS];
                    126: extern TOPICLIST topicList[CTOPICS];
                    127: 
                    128: 
                    129: // FUNCTIONS
                    130: 
                    131: 
                    132: BOOL InitApplication(HANDLE);
                    133: BOOL InitInstance(HANDLE, INT);
1.1.1.2 ! root      134: INT FAR DoDialog(LPSTR lpTemplateName, DLGPROC lpDlgProc, LPARAM param, BOOL fRememberFocus);
1.1       root      135: LONG  APIENTRY MainWndProc(HWND, UINT, WPARAM, LONG);
                    136: BOOL  APIENTRY About(HWND, UINT, WPARAM, LONG);
                    137: BOOL  APIENTRY RenderDelayDlgProc(HWND, UINT, WPARAM, LONG);
                    138: BOOL  APIENTRY SetTopicDlgProc(HWND, UINT, WPARAM, LONG);
                    139: BOOL  APIENTRY SetServerDlgProc(HWND, UINT, WPARAM, LONG);
                    140: BOOL  APIENTRY ContextDlgProc(HWND, UINT, WPARAM, LONG);
                    141: VOID PaintServer(HWND hwnd);
                    142: VOID DrawTextLine(HDC hdc, RECT *prcClip, RECT *prcText, PSTR psz);
1.1.1.2 ! root      143: HDDEDATA CALLBACK DdeCallback(UINT wType, UINT wFmt, HCONV hConv, HSZ hszTopic,
1.1       root      144:         HSZ hszItem, HDDEDATA hData, DWORD lData1, DWORD lData2);
                    145: HDDEDATA TopicListXfer(PXFERINFO pXferInfo, WORD iFmt);
                    146: HDDEDATA ItemListXfer(PXFERINFO pXferInfo, WORD iFmt);
                    147: HDDEDATA sysFormatsXfer(PXFERINFO pXferInfo, WORD iFmt);
                    148: HDDEDATA TestRandomXfer(PXFERINFO pXferInfo, WORD iFmt);
                    149: HDDEDATA TestCountXfer(PXFERINFO pXferInfo, WORD iFmt);
                    150: HDDEDATA TestHugeXfer(PXFERINFO pXferInfo, WORD iFmt);
                    151: HDDEDATA HelpXfer(PXFERINFO pXferInfo, WORD iFmt);
                    152: VOID Hszize(VOID);
                    153: VOID UnHszize(VOID);
                    154: VOID Delay(DWORD delay, BOOL fModal);
                    155: 
                    156: 

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.