ReactOS 0.4.15-dev-8131-g4988de4
dde.h File Reference
#include <windef.h>
Include dependency graph for dde.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  DDEACK
 
struct  DDEDATA
 
struct  DDEADVISE
 
struct  DDEPOKE
 

Macros

#define WM_DDE_INITIATE   0x3E0
 
#define WM_DDE_TERMINATE   0x3E1
 
#define WM_DDE_ADVISE   0x3E2
 
#define WM_DDE_UNADVISE   0x3E3
 
#define WM_DDE_ACK   0x3E4
 
#define WM_DDE_DATA   0x3E5
 
#define WM_DDE_REQUEST   0x3E6
 
#define WM_DDE_POKE   0x3E7
 
#define WM_DDE_EXECUTE   0x3E8
 
#define WM_DDE_LAST   WM_DDE_EXECUTE
 
#define WM_DDE_FIRST   WM_DDE_INITIATE
 

Functions

BOOL WINAPI DdeSetQualityOfService (HWND hwndClient, CONST SECURITY_QUALITY_OF_SERVICE *pqosNew, PSECURITY_QUALITY_OF_SERVICE pqosPrev)
 
BOOL WINAPI ImpersonateDdeClientWindow (HWND hWndClient, HWND hWndServer)
 
LPARAM WINAPI PackDDElParam (UINT, UINT_PTR, UINT_PTR)
 
BOOL WINAPI UnpackDDElParam (UINT, LPARAM, PUINT_PTR, PUINT_PTR)
 
BOOL WINAPI FreeDDElParam (UINT, LPARAM)
 
LPARAM WINAPI ReuseDDElParam (LPARAM, UINT, UINT, UINT_PTR, UINT_PTR)
 

Macro Definition Documentation

◆ WM_DDE_ACK

#define WM_DDE_ACK   0x3E4

Definition at line 41 of file dde.h.

◆ WM_DDE_ADVISE

#define WM_DDE_ADVISE   0x3E2

Definition at line 39 of file dde.h.

◆ WM_DDE_DATA

#define WM_DDE_DATA   0x3E5

Definition at line 42 of file dde.h.

◆ WM_DDE_EXECUTE

#define WM_DDE_EXECUTE   0x3E8

Definition at line 45 of file dde.h.

◆ WM_DDE_FIRST

#define WM_DDE_FIRST   WM_DDE_INITIATE

Definition at line 47 of file dde.h.

◆ WM_DDE_INITIATE

#define WM_DDE_INITIATE   0x3E0

Definition at line 37 of file dde.h.

◆ WM_DDE_LAST

#define WM_DDE_LAST   WM_DDE_EXECUTE

Definition at line 46 of file dde.h.

◆ WM_DDE_POKE

#define WM_DDE_POKE   0x3E7

Definition at line 44 of file dde.h.

◆ WM_DDE_REQUEST

#define WM_DDE_REQUEST   0x3E6

Definition at line 43 of file dde.h.

◆ WM_DDE_TERMINATE

#define WM_DDE_TERMINATE   0x3E1

Definition at line 38 of file dde.h.

◆ WM_DDE_UNADVISE

#define WM_DDE_UNADVISE   0x3E3

Definition at line 40 of file dde.h.

Function Documentation

◆ DdeSetQualityOfService()

BOOL WINAPI DdeSetQualityOfService ( HWND  hwndClient,
CONST SECURITY_QUALITY_OF_SERVICE pqosNew,
PSECURITY_QUALITY_OF_SERVICE  pqosPrev 
)

◆ FreeDDElParam()

BOOL WINAPI FreeDDElParam ( UINT  msg,
LPARAM  lParam 
)

Definition at line 147 of file ddemisc.c.

148{
149 switch (msg)
150 {
151 case WM_DDE_ACK:
152 case WM_DDE_ADVISE:
153 case WM_DDE_DATA:
154 case WM_DDE_POKE:
155 /* first check if it's a global handle */
156 if (!GlobalHandle( (LPVOID)lParam )) return TRUE;
157 return !GlobalFree( (HGLOBAL)lParam );
158
159 default:
160 return TRUE;
161 }
162}
#define msg(x)
Definition: auth_time.c:54
LPARAM lParam
Definition: combotst.c:139
#define WM_DDE_DATA
Definition: dde.h:42
#define WM_DDE_POKE
Definition: dde.h:44
#define WM_DDE_ADVISE
Definition: dde.h:39
#define WM_DDE_ACK
Definition: dde.h:41
#define TRUE
Definition: types.h:120
HGLOBAL NTAPI GlobalHandle(LPCVOID pMem)
Definition: heapmem.c:705
HGLOBAL NTAPI GlobalFree(HGLOBAL hMem)
Definition: heapmem.c:611

Referenced by post_dde_message(), ReuseDDElParam(), test_FreeDDElParam(), test_PackDDElParam(), WDML_HandleAdviseReply(), WDML_HandleExecuteReply(), WDML_HandleIncomingData(), WDML_HandlePokeReply(), WDML_HandleRequestReply(), WDML_HandleUnadviseReply(), WDML_PostAck(), and WDML_ServerHandleUnadvise().

◆ ImpersonateDdeClientWindow()

BOOL WINAPI ImpersonateDdeClientWindow ( HWND  hWndClient,
HWND  hWndServer 
)

Definition at line 221 of file ddemisc.c.

222{
223 FIXME("(%p %p): stub\n", hWndClient, hWndServer);
224 return FALSE;
225}
#define FIXME(fmt,...)
Definition: debug.h:114
#define FALSE
Definition: types.h:117

Referenced by DdeImpersonateClient().

◆ PackDDElParam()

LPARAM WINAPI PackDDElParam ( UINT  msg,
UINT_PTR  uiLo,
UINT_PTR  uiHi 
)

Definition at line 63 of file ddemisc.c.

64{
65 HGLOBAL hMem;
67
68 switch (msg)
69 {
70 case WM_DDE_ACK:
71 case WM_DDE_ADVISE:
72 case WM_DDE_DATA:
73 case WM_DDE_POKE:
74 if (!(hMem = GlobalAlloc(GMEM_DDESHARE, sizeof(UINT_PTR) * 2)))
75 {
76 ERR("GlobalAlloc failed\n");
77 return 0;
78 }
79 if (!(params = GlobalLock(hMem)))
80 {
81 ERR("GlobalLock failed (%p)\n", hMem);
82 return 0;
83 }
84 params[0] = uiLo;
85 params[1] = uiHi;
86 GlobalUnlock(hMem);
87 return (LPARAM)hMem;
88
89 case WM_DDE_EXECUTE:
90 return uiHi;
91
92 default:
93 return MAKELONG(uiLo, uiHi);
94 }
95}
#define ERR(fmt,...)
Definition: debug.h:113
#define WM_DDE_EXECUTE
Definition: dde.h:45
GLenum const GLfloat * params
Definition: glext.h:5645
LPVOID NTAPI GlobalLock(HGLOBAL hMem)
Definition: heapmem.c:755
BOOL NTAPI GlobalUnlock(HGLOBAL hMem)
Definition: heapmem.c:1190
HGLOBAL NTAPI GlobalAlloc(UINT uFlags, SIZE_T dwBytes)
Definition: heapmem.c:368
unsigned __int3264 UINT_PTR
Definition: mstsclib_h.h:274
#define MAKELONG(a, b)
Definition: typedefs.h:249
#define GMEM_DDESHARE
Definition: winbase.h:298
LONG_PTR LPARAM
Definition: windef.h:208

Referenced by dde_server_wndproc(), dde_server_wndprocA(), dde_server_wndprocW(), DdePostAdvise(), ReuseDDElParam(), test_msg_client(), test_PackDDElParam(), unpack_dde_message(), WDML_ClientQueueAdvise(), WDML_ClientQueuePoke(), WDML_ClientQueueRequest(), WDML_ClientQueueUnadvise(), and WDML_PostAck().

◆ ReuseDDElParam()

LPARAM WINAPI ReuseDDElParam ( LPARAM  lParam,
UINT  msgIn,
UINT  msgOut,
UINT_PTR  uiLo,
UINT_PTR  uiHi 
)

Definition at line 171 of file ddemisc.c.

173{
175
176 switch (msgIn)
177 {
178 case WM_DDE_ACK:
179 case WM_DDE_ADVISE:
180 case WM_DDE_DATA:
181 case WM_DDE_POKE:
182 switch(msgOut)
183 {
184 case WM_DDE_ACK:
185 case WM_DDE_ADVISE:
186 case WM_DDE_DATA:
187 case WM_DDE_POKE:
188 if (!lParam) return 0;
189 if (!(params = GlobalLock( (HGLOBAL)lParam )))
190 {
191 ERR("GlobalLock failed\n");
192 return 0;
193 }
194 params[0] = uiLo;
195 params[1] = uiHi;
196 TRACE("Reusing pack %08lx %08lx\n", uiLo, uiHi);
198 return lParam;
199
200 case WM_DDE_EXECUTE:
201 FreeDDElParam( msgIn, lParam );
202 return uiHi;
203
204 default:
205 FreeDDElParam( msgIn, lParam );
206 return MAKELPARAM(uiLo, uiHi);
207 }
208
209 default:
210 return PackDDElParam( msgOut, uiLo, uiHi );
211 }
212}
LPARAM WINAPI PackDDElParam(UINT msg, UINT_PTR uiLo, UINT_PTR uiHi)
Definition: ddemisc.c:63
BOOL WINAPI FreeDDElParam(UINT msg, LPARAM lParam)
Definition: ddemisc.c:147
#define TRACE(s)
Definition: solgame.cpp:4
#define MAKELPARAM(l, h)
Definition: winuser.h:4008

Referenced by dde_server_wndproc(), dde_server_wndprocA(), dde_server_wndprocW(), WDML_PostAck(), and WDML_ServerHandleRequest().

◆ UnpackDDElParam()

BOOL WINAPI UnpackDDElParam ( UINT  msg,
LPARAM  lParam,
PUINT_PTR  uiLo,
PUINT_PTR  uiHi 
)

Definition at line 105 of file ddemisc.c.

107{
109
110 switch (msg)
111 {
112 case WM_DDE_ACK:
113 case WM_DDE_ADVISE:
114 case WM_DDE_DATA:
115 case WM_DDE_POKE:
116 if (!lParam || !(params = GlobalLock((HGLOBAL)lParam)))
117 {
118 if (uiLo) *uiLo = 0;
119 if (uiHi) *uiHi = 0;
120 return FALSE;
121 }
122 if (uiLo) *uiLo = params[0];
123 if (uiHi) *uiHi = params[1];
125 return TRUE;
126
127 case WM_DDE_EXECUTE:
128 if (uiLo) *uiLo = 0;
129 if (uiHi) *uiHi = lParam;
130 return TRUE;
131
132 default:
133 if (uiLo) *uiLo = LOWORD(lParam);
134 if (uiHi) *uiHi = HIWORD(lParam);
135 return TRUE;
136 }
137}
#define LOWORD(l)
Definition: pedump.c:82
#define HIWORD(l)
Definition: typedefs.h:247

Referenced by dde_msg_client_wndproc(), dde_server_wndproc(), dde_server_wndprocA(), dde_server_wndprocW(), hook_dde_client_wndprocA(), hook_dde_client_wndprocW(), post_dde_message(), test_PackDDElParam(), test_UnpackDDElParam(), WDML_HandleAdviseReply(), WDML_HandleExecuteReply(), WDML_HandleIncomingData(), WDML_HandlePokeReply(), WDML_HandleRequestReply(), WDML_HandleUnadviseReply(), WDML_ServerNameProc(), WDML_ServerQueueAdvise(), WDML_ServerQueuePoke(), WDML_ServerQueueRequest(), and WDML_ServerQueueUnadvise().