-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy patha_graf_handle.c
58 lines (52 loc) · 1.88 KB
/
a_graf_handle.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
#include "gem_aesP.h"
/** returns important information regarding the
* physical workstation currently in use by the AES.
*
* @param wcell pointer to a short int which will contain (on function exit)
* the width of the current system character set. \n
* [option CHECK_NULLPTR] \a wcell may be NULL
* @param hcell pointer to a short int which will contain (on function exit)
* the height of the current system character set. \n
* [option CHECK_NULLPTR] \a hcell may be NULL
* @param wbox pointer to a short int which will contain (on function exit)
* the width of the minimum bounding box of a BOXCHAR character. \n
* [option CHECK_NULLPTR] \a wbox may be NULL
* @param hbox pointer to a short int which will contain (on function exit)
* the height of the minimum bounding box of a BOXCHAR character. \n
* [option CHECK_NULLPTR] \a hbox may be NULL
* @param global_aes global AES array
*
* @return the VDI handle for the current physical workstation used
* by the AES which is required to open a virtual screen
* workstation.
*
* @since All AES versions.
*
* @sa v_opnvwk()
*
* @note There is currently no defined method of handling an error
* generated by this function.
*
*/
short
mt_graf_handle (short *wcell, short *hcell, short *wbox, short *hbox, short *global_aes)
{
#if !(CHECK_NULLPTR)
short *ptr;
#endif
AES_PARAMS(77,0,5,0,0);
AES_TRAP(aes_params);
#if CHECK_NULLPTR
if (wcell) *wcell = aes_intout[1];
if (hcell) *hcell = aes_intout[2];
if (wbox) *wbox = aes_intout[3];
if (hbox) *hbox = aes_intout[4];
#else
ptr = &aes_intout[1];
*wcell = *(ptr ++); /* [1] */
*hcell = *(ptr ++); /* [2] */
*wbox = *(ptr ++); /* [3] */
*hbox = *(ptr); /* [4] */
#endif
return aes_intout[0];
}