Jump to content

DrgQueryDraginfoPtrFromDragitem: Difference between revisions

From EDM2
Created page with "This function is called to obtain a pointer to the DRAGINFO structure associated with a given DRAGITEM structure. ==Syntax== DrgQueryDraginfoPtrFromDragitem(pditem) ==Parameters== ;pditem (PDRAGITEM) - input: Pointer to a DRAGITEM structure whose corresponding DRAGINFO is to be returned. ==Returns== ;pDraginfo (PDRAGINFO) - returns: Pointer to the DRAGINFO structure for the specified pditem. :: A return value of NULL indicates that a DRAGITEM structure was not found...."
 
Line 68: Line 68:
* [[DrgAccessDraginfo]]
* [[DrgAccessDraginfo]]
* [[DrgQueryDraginfoPtr]]
* [[DrgQueryDraginfoPtr]]
* [[DrgQueryDraginfoPtrFromDragitem]]
 


[[Category:Drg]]
[[Category:Drg]]

Revision as of 00:21, 8 April 2025

This function is called to obtain a pointer to the DRAGINFO structure associated with a given DRAGITEM structure.

Syntax

DrgQueryDraginfoPtrFromDragitem(pditem)

Parameters

pditem (PDRAGITEM) - input
Pointer to a DRAGITEM structure whose corresponding DRAGINFO is to be returned.

Returns

pDraginfo (PDRAGINFO) - returns
Pointer to the DRAGINFO structure for the specified pditem.
A return value of NULL indicates that a DRAGITEM structure was not found.

Example Code

#define INCL_WINSTDDRAG
#include <os2.h>

PDRAGINFO pdinfo;    /* Pointer to a DRAGINFO structure */
PDRAGITEM pdragitem; /* Pointer to a DRAGITEM structure */

pdinfo=DrgQueryDraginfoPtrFromDragitem(pdragitem);
if (pdinfo) {
.
.
.
}

Related Functions


This function determines whether a particular window has allocated a DRAGINFO structure.

Syntax

DrgQueryDraginfoPtrFromHwnd(hwndSource)

Parameters

hwndSource (HWND) - input
Handle of the window whose associated DRAGINFO pointer is to be returned.

Returns

pDraginfo (PDRAGINFO) - returns
Pointer to the DRAGINFO structure allocated by the window specified by hwndSource.
If the return value is NULL, the DRAGINFO structure has not been allocated.

Remarks

The application can gain access to the structure DRAGINFO by calling DrgAccessDraginfo.

Example Code

#define INCL_WINSTDDRAG
#include <os2.h>

HWND      hwndWindow; /* Window handle                     */
PDRAGINFO pinfo;      /* Pointer to a DRAGINFO structure */

pdinfo=DrgQueryDraginfoPtrFromHwnd(hwndWindow);
If (pdinfo) {
.
.
.
}

Related Functions