home *** CD-ROM | disk | FTP | other *** search
/ QBasic & Borland Pascal & C / Delphi5.iso / C / Samples / CSAPE32.ARJ / SOURCE / OWLSCR / WINOBJ.C < prev    next >
Encoding:
C/C++ Source or Header  |  1990-10-04  |  16.6 KB  |  571 lines

  1. /*
  2.     winobj.c
  3.  
  4.     % generic window object
  5.  
  6.     3/17/88 by Ted.
  7.  
  8.     OWL 1.2
  9.     Copyright (c) 1988, by Oakland Group, Inc.
  10.     ALL RIGHTS RESERVED.
  11.  
  12.     Revision History:
  13.     -----------------
  14.      6/16/88 Ted    revised to have inheritance and class factory functions.
  15.      8/09/88 jmd    revised to use new object stuff
  16.      9/02/88 ted    fixed graphics cursor scrolling
  17.      9/02/88 ted    moved non-object functions out to winfuncs.c
  18.      9/12/88 jmd    Added in and out data to objects
  19.     11/17/88 ted    Added WIN_GO & mouse control default methods.
  20.     11/20/88 jmd    Added ID to obj struct
  21.     11/22/88 jmd    Changed unsingeds to burnts!
  22.     12/02/88 ted    Added REQ message handling for bdmouse
  23.      3/24/89 ted    Moved attribute and curstype into xdata, added SETFONT msg.
  24.      3/24/89 ted    Made win's pure objects. Eliminated win_CreateWin,
  25.                      wmgr_Destroy win by folding them into win_Class.
  26.      4/14/89 ted    Added WINM_CHILDCLOSE msg.
  27.      5/01/89 ted    Added break case for WINM msgs not used at this level.
  28.      5/28/89 jmd    added Shadow support
  29.      7/07/89 gam    changed NULL to FNULL where necessary.
  30.      7/25/89 ted    Added explode function call.
  31.      8/06/89 ted    Commented out null inits to save time and code.
  32.      8/08/89 jmd    Added size, pos, and top support.
  33.      8/10/89 jmd    Killed bob, added new messages to windows.
  34.      8/12/89 jdc    Added win_Close function stuff here
  35.      8/12/89 jdc    Added INIT message, added WHO message
  36.      8/13/89 jmd    removed GETEXPLODE message
  37.      8/16/89 jmd    Added initialization for nullfont and resize flags.
  38.      9/12/89 jmd    Fixed Shadow Clear color
  39.  
  40.     11/06/89 jmd    removed DoRaw macros
  41.     12/04/89 jmd    added cursor color
  42.     12/10/89 jmd    added win gofunc
  43.      1/08/89 ted    Added arg to win_MakeCurrent.
  44.      1/17/90 ted    Added shademsg args to _Expose functions.
  45.      3/27/90 ted    Fixed partial-cursor plotting bug, removed cubox win od element.
  46.      3/28/90 ted    Made show/hide cursor methods into functions in wincurso.c.
  47.      3/28/90 jmd    ansi-fied
  48.      8/24/90 jdc    added classhandle macros
  49.      9/23/90 ted    added check for null currmev.
  50.      9/24/90 jmd    removed gofunc, added aux message 
  51.                     added optional PAINT aux message
  52.     10/04/90 jmd    removed false comment from CLOSE case
  53. */
  54.  
  55. #include "oakhead.h"
  56. #include "disppriv.h"
  57. #include "bordobj.h"
  58. #include "winod.h"
  59.  
  60. OGLOBAL objreq_fptr winreq_loadfptr = objreq_Null;
  61. OGLOBAL objreq_fptr winreq_savefptr = objreq_Null;
  62. /* -------------------------------------------------------------------------- */
  63.  
  64. int win_Class(VOID *objdata, int msg, VOID *indata, VOID *outdata)
  65. /* 
  66.     win object dispatch function
  67. */
  68. {
  69.     win_od *wd;
  70.     win_type win;
  71.     win_xd *winxd;
  72.     ptd_struct *ptd;
  73.     ptd_struct inptd;    /* for use in inner-coordinate computations */
  74.     opbox inbox;        /* ditto; gets hooked in by ptd_SetInner */
  75.     opbox relbox;
  76.  
  77.     wd = (win_od *) objdata;
  78.     win = winod_GetSelf(wd); /* Note: no GP fault here because GETDATASIZE is never called */
  79.     winxd = win_getxd(win); oak_notused(winxd);/* Here for debugging reference */
  80.  
  81.     switch(msg) {
  82. /*    case OBJM_GETDATASIZE:    This class only exists to be inherited */
  83.  
  84.     case OBJM_WHO:
  85.         /* Identify ourselves */
  86.         return (*((int *) indata) == ID_WIN || *((int *) indata) == ID_BOB);
  87.  
  88.     case OBJM_OPEN:
  89.     /*
  90.         Open a new window in pixel coordinates, with a font spec.
  91.         Note: Called only from win_PixOpen, wmgr_Init, & wmgr_ListOpen which
  92.         is called from wmgr_Init. Therefore, it does not need to call
  93.         hard_Claim/Release for reentrancy protection because both of its
  94.         calling paths do it already.
  95.         Note: all inits to 0, FALSE, NULL, & FNULL are superfluous because
  96.         object structures are initted to 0's.
  97.     */
  98.     {
  99.         int i;
  100.  
  101.         /* Initialize win private object data */
  102.  
  103. #ifdef OAK_NULLNOT0
  104.         wd->current = FALSE;    /* init not current */
  105.         wd->cursunder = NULL;    /* init cursor under-buffer */
  106.  
  107.         bob_SetUbit0(win, 0);
  108.         bob_SetUbit1(win, 0);
  109.         bob_SetParentMove(win, TRUE); /* it's ok, the TRUE is negated by the macro */
  110.  
  111.         /* Initialize win xdata */
  112.  
  113.         win_SetParent(win, NULL);
  114.  
  115.         win_inboxp(win)->xmin = 0; win_inboxp(win)->ymin = 0;
  116.         win_inboxp(win)->xmax = 0; win_inboxp(win)->ymax = 0;
  117.         win_pixboxp(win)->xmin = 0; win_pixboxp(win)->ymin = 0;
  118.         win_pixboxp(win)->xmax = 0; win_pixboxp(win)->ymax = 0;
  119.  
  120.         win_setemployed(win, FALSE);
  121.         win_setabove(win, NULL);
  122.         win_setbelow(win, NULL);
  123.  
  124.         win_setcursx(win, 0);
  125.         win_setcursy(win, 0);
  126.  
  127.         win_SetMouse(win, FNULL);
  128.         win_SetDebounced(win, FALSE);
  129.         win_SetNextWin(win, NULL);
  130.         win_SetExplode(win, FNULL);
  131.  
  132.         win_setbd(win, NULL);
  133.  
  134.         win_setshadowx(win, 0);
  135.         win_setshadowy(win, 0);
  136.         win_SetShadowAttr(win, 0x00);
  137. #endif
  138.         obj_SetClassHandle(win, -1);
  139.  
  140.         win_setnullfont(win, TRUE);
  141.         win_SetParentClip(win, TRUE);
  142.  
  143.         win_setattribute(win, ATTR_NORMAL);
  144.         win_setcurstype(win, CURSOR_NORMAL);
  145.         win_setcurscolor(win, win_GetFgColor(win));
  146.  
  147.         win_setidmgr(win, disp_id());
  148.         win_SetCharSize(win, TRUE);
  149.         win_SetResize(win, TRUE);
  150.  
  151.         /* initialize LNF function handle array */
  152.         for (i = 0; i < WIN_FSYM_COUNT; i++) {
  153.             win_getxd(win)->handles[i] = -1;
  154.         }
  155.         /* send OPEN to bob superclass */
  156.         return(bob_Class(&(wd->bd), msg, indata, outdata));
  157.     }
  158.  
  159.     case OBJM_INIT:
  160.     {
  161.         winopendata_struct *wod = (winopendata_struct *) indata;
  162.            opbox *boxp;
  163.         ofont_type dfont;
  164.         odim width, height;
  165.  
  166.         boxp = wod->boxp;
  167.         
  168.         if (!disp_TextFree()) {
  169.             dfont = disp_GetDefFont();
  170.             width  = opbox_GetWidth(boxp);
  171.             height = opbox_GetHeight(boxp);
  172.             opcoord_GridRound(&boxp->xmin, &boxp->ymin, dfont);
  173.             /* Round up instead of down */
  174.             boxp->xmax = boxp->xmin + width  + ofont_GetWidth(dfont) - 1;
  175.             boxp->ymax = boxp->ymin + height + ofont_GetHeight(dfont) - 1;
  176.             opcoord_GridRound(&boxp->xmax, &boxp->ymax, dfont);
  177.         }
  178.         opbox_copy(win_pixboxp(win), boxp);
  179.         win_inboxp(win)->xmax = opbox_GetWidth(boxp);
  180.         win_inboxp(win)->ymax = opbox_GetHeight(boxp);
  181.  
  182.         /* Set up the font, underbuffer, etc. */
  183.         if (!win_SetFont(win, wod->font)) {
  184.             return(FALSE);
  185.         }
  186.         /* Put window into unemployed list (at the top) */
  187.         if (wod->list != NULL) {
  188.             win_ListAdd(wod->list, win);
  189.         }
  190.         break;
  191.     }
  192.  
  193.     case OBJM_CLOSE:
  194.     {
  195.         extern win_type vid_win;
  196.  
  197.         owl_Assert(win_Ok(win), OE_WC_WIN);
  198.  
  199.         hard_Claim();            /* Here for re-entrancy protection */
  200.  
  201.         /* Unemploy window first */
  202.         if (win_IsEmployed(win)) {
  203.             win_UnEmploy(win);
  204.         }
  205.         /* remove window from unemployed list */
  206.         win_ListRemove(win);
  207.  
  208.         /* Make sure vid_win ptr is NULL'ed out if vid_win is destroyed */
  209.         if (vid_win == win) {
  210.             vid_win = NULL;
  211.         }
  212.         /* Make sure backwin ptr is NULL'ed out if backwin is destroyed */
  213.         if (disp_GetBackWin() == win) {
  214.             wmgr_setbackwin(NULL);
  215.         }
  216.         /* Make sure the win is not still current after it is freed */
  217.         if (disp_GetCurrentWin() == win) {
  218.             win_MakeCurrent(NULL, NULL);
  219.         }
  220.         /* If mouse event window is being closed, make a note of that */
  221.         if (wmgr_currmev()->win == win) {
  222.             wmgr_currmev()->win = NULL;
  223.         }
  224.         if (wmgr_lastmev()->win == win) {
  225.             wmgr_lastmev()->win = NULL;
  226.         }
  227.         /* If wingo fromwin is being closed, make a note of that */
  228.         if (disp_GetFromWin() == win) {
  229.             wmgr_setfromwin(NULL);
  230.         }
  231.         /* Close the window's border if it has one */
  232.         bord_Close(win);
  233.  
  234.         /* Kill the Window's cursor under-buffer and font reference. */
  235.         win_SetFont(win, NULL);
  236.  
  237.         /* Kill the window's dmgr id so win_Ok will now fail on this win ptr */
  238.         win_setidmgr(win, 0);
  239.  
  240.         /* Notify the window's parent window that its child is closed */
  241.         owl_Assert(((win_GetParent(win) == NULL) || win_Ok(win_GetParent(win))), OE_WC_PARENT);
  242.         win_Do(win_GetParent(win), WINM_CHILDCLOSE, win, NULL);
  243.  
  244.         hard_Release();
  245.  
  246.         /* send CLOSE to bob superclass */
  247.         return(bob_Class(&(wd->bd), msg, indata, outdata));
  248.     }
  249.  
  250.     case OBJM_LOAD:
  251.         return((*winreq_loadfptr)(objdata, msg, indata, outdata));
  252.  
  253.     case OBJM_SAVE:
  254.         return((*winreq_savefptr)(objdata, msg, indata, outdata));
  255.  
  256.     case WINM_SETFONT:
  257.     /* set new font and initialize the cursor under-buffer etc. if needed. */
  258.     {
  259.         ofont_type font = (ofont_type)indata;
  260.  
  261.         win_setfontptr(win, font);
  262.         win_setnullfont(win, font == NULL);
  263.  
  264.         pmap_Close(wd->cursunder);
  265.  
  266.         win_setcudrawn(win, FALSE);
  267.         if (font == NULL || disp_hardcursor()) {
  268.             wd->cursunder = NULL;
  269.         }
  270.         else {
  271.             /* Allocate pixel map for saving under cursor */
  272.             wd->cursunder = pmap_Open(ofont_GetWidth(font), ofont_GetHeight(font));
  273.  
  274.             if (wd->cursunder == NULL) {
  275.                 return(FALSE);
  276.             }
  277.         }
  278.         break;
  279.     }
  280.     case WINM_SHADOW:
  281.         /* If the window subclass hasn't painted a shadow
  282.            clear the shadow area.
  283.         */
  284.         ptd = (ptd_struct *)indata;
  285.         if (ptd->emsgdata == NULL) {
  286.             ptd_Clear(ptd, disp_GetAttrBgColor(win_GetShadowAttr(ptd->win)));
  287.         }
  288.         /* no break: pass the message through to WINM_PAINT so it can  */
  289.         /*   take care of painting the border   */
  290.  
  291.     case WINM_DRAWCURSOR:    /* draw cursor if in this box */
  292.     case WINM_PAINT:
  293.     {
  294.         boolean dobord;    /* flag for whether to call border paint function. */
  295.         opbox cpmbox;    /* cursor box relative to cursunder pixmap */
  296.         opcoord cx, cy;    /* upper left of cursor rect before ptd clipping */
  297.  
  298.         ptd = (ptd_struct *)indata;
  299.         if (ptd_SetInner(ptd, &inptd, &inbox)) {
  300.             if (win_IsUserPaint(win)) {
  301.                 /* send paint message to aux func */
  302.                 if (msg == WINM_PAINT) {
  303.                     obj_DoAux(win, WINA_PAINT, (VOID *) &inptd, NULL);
  304.                 }
  305.                 else if (msg == WINM_SHADOW) {
  306.                     obj_DoAux(win, WINA_SHADOW, (VOID *) &inptd, NULL);
  307.                 }
  308.             }
  309.  
  310.             if (wd->current) {
  311.                 /* if we're current, paint our cursor */
  312.  
  313.                 win_GetCursorPixBox(win, &relbox);
  314.                 cx = relbox.xmin;
  315.                 cy = relbox.ymin;
  316.  
  317.                 if (opbox_clipbox(inptd.relboxp, &relbox)) {
  318.                     if (win_curshide(win) == 0) {
  319.                         if (wd->cursunder == NULL) {
  320.                             if (!win_cudrawn(win)) { /* Just draw text cursor */
  321.                                 ptd_DrawCursor(&inptd, win_GetCursorType(win));
  322.                             }
  323.                         }
  324.                         else { /* If graphics cursor, save under it before drawing it */
  325.                     /* Only save under & draw if cursor is not displayed - */
  326.                     /*   (was painted over or was not drawn) */
  327.                             if (!(msg == WINM_DRAWCURSOR && win_cudrawn(win))) {
  328.                                 opbox_copy(&cpmbox, &relbox);
  329.                                 opbox_trans(&cpmbox, -cx, -cy);
  330.                                 inptd.relboxp = &relbox;
  331.                                 ptd_ReadPixmap(&inptd, wd->cursunder, &cpmbox);
  332.                                 inptd.relboxp = &inbox;    /* restore to other temp. box */
  333.  
  334.                                 ptd_DrawCursor(&inptd, win_GetCursorType(win));
  335.                             }
  336.                         }
  337.                         win_setcudrawn(win, TRUE);
  338.                     }
  339.                     else {    /* curshide != 0 */
  340.                 /* If graphics cursor, and this is PAINT msg, the char paint will */
  341.                 /* already have overwritten it, and this needs to do nothing */
  342.                 /* If a DRAWCURSOR msg, this pixmap restore will paint over it */
  343.                          if (wd->cursunder == NULL) {
  344.                         /* If hardware cursor, this will turn it off. */
  345.                             ptd_EraseCursor(&inptd);
  346.                         }
  347.                         else {
  348.                             if (msg == WINM_DRAWCURSOR && win_cudrawn(win)) {
  349.                                 opbox_copy(&cpmbox, &relbox);
  350.                                 opbox_trans(&cpmbox, -cx, -cy);
  351.                                 inptd.relboxp = &relbox;
  352.                                 ptd_DrawPixmap(&inptd, wd->cursunder, &cpmbox);
  353.                                 inptd.relboxp = &inbox;    /* restore to other temp. box */
  354.                             }
  355.                         }
  356.                         win_setcudrawn(win, FALSE);
  357.                     }
  358.                 }
  359.             }
  360.             /* If it was clipped, that means some of it hung over into border */
  361.             dobord = !opbox_equal(inptd.relboxp, ptd->relboxp);
  362.         }
  363.         /* If it wasn't in win box at all, it must be in border */
  364.         else {
  365.             dobord = TRUE;
  366.         }
  367.  
  368.         /* Paint border */
  369.         if (dobord) {
  370.             bord_Do(win, (msg == WINM_SHADOW) ? BDM_SHADOW : BDM_DRAW, indata, NULL);
  371.         }
  372.         break;
  373.     }
  374.     case WINM_SHADOWSAVE:
  375.     case WINM_SAVE:        /* hide cursor if in this box */
  376.         /* If hardware cursor, this will turn it off. */
  377.         /* If graphics cursor, it will get overwritten or it doesn't need */
  378.         /* to be erased and this does nothing */
  379.         if (wd->current && win_curshide(win) == 0) {
  380.             ptd = (ptd_struct *)indata;
  381.             if (ptd_SetInner(ptd, &inptd, &inbox)) {
  382.                 win_GetCursorPixBox(win, &relbox);
  383.                 if (opbox_clipbox(inptd.relboxp, &relbox)) {
  384.                      if (wd->cursunder == NULL) {
  385.                         ptd_EraseCursor(&inptd);
  386.                     }
  387.                     win_setcudrawn(win, FALSE);
  388.                 }
  389.             }
  390.         }
  391.         break;
  392.  
  393.     case WINM_SCROLL:
  394.     {
  395.         opcoord nx, ny;
  396.  
  397.         ptd = (ptd_struct *)indata;
  398.         nx = ( (opoint *)(ptd->emsgdata) )->x;
  399.         ny = ( (opoint *)(ptd->emsgdata) )->y;
  400.         if (ptd_SetInner(ptd, &inptd, &inbox)) {
  401.             opbox_copy(&relbox, inptd.relboxp);
  402.  
  403.             if (nx == 0) {
  404.                 if (ny == 0) {
  405.                     break;        /* Do nothing if no scroll called for */
  406.                 }
  407.                 else if (disp_vtscroll()) {        /* Vertical Scroll */
  408.                     if (opbox_ScrollVtIn(&relbox, ny)) {
  409.                         ptd_ScrollBoxVt(&inptd, ny);
  410.                     }
  411.                 }
  412.             }
  413.             else {
  414.                 if (ny == 0 && disp_hzscroll()) {    /* Horizontal Scroll */
  415.                     if (opbox_ScrollHzIn(&relbox, nx)) {
  416.                         ptd_ScrollBoxHz(&inptd, nx);
  417.                     }
  418.                 }
  419.             /*  else nx and ny not zero - just repaint the whole box */
  420.             }
  421.             /* Call the window's paint function on the remaining box portion */
  422.             inptd.relboxp = &relbox;
  423.             win_Do(win, WINM_PAINT, &inptd, NULL);
  424.         }
  425.         break;
  426.     }
  427.     case WINM_CLEAR:
  428.         ptd = (ptd_struct *)indata;
  429.         if (ptd_SetInner(ptd, &inptd, &inbox)) {
  430.             ptd_Clear(&inptd, *((opixval *)inptd.emsgdata));
  431.         }
  432.         break;
  433.  
  434.     case WINM_GETINPOS:        /* return inbox same as win box */
  435.     {
  436.         inposdata_struct *ipd = (inposdata_struct *)outdata;
  437.  
  438.         win_GetPixBox(ipd->win, &ipd->inbox);
  439.         break;
  440.     }
  441.     case WINM_STARTCUR:
  442.         if (wd->current != TRUE) {
  443.             wd->current = TRUE;
  444.             if (win_curshide(win) == 0) {    /* turn cursor on */
  445.                 win_paintcursor((win_type)indata);
  446.             }
  447.             *((boolean *) outdata) = TRUE;
  448.         }
  449.         else {
  450.             *((boolean *) outdata) = FALSE;
  451.         }
  452.         break;
  453.  
  454.     case WINM_STOPCUR:
  455.         if (wd->current != FALSE) {
  456.             if (win_curshide(win) == 0) {    /* turn cursor off */
  457.                 win_inccurshide(win);
  458.                 win_paintcursor((win_type)indata);
  459.                 win_deccurshide(win);
  460.             }
  461.             wd->current = FALSE;
  462.             *((boolean *) outdata) = TRUE;
  463.         }
  464.         else {
  465.             *((boolean *) outdata) = FALSE;
  466.         }
  467.         break;
  468.  
  469.     case WINM_EXPLODE:
  470.         if (win_GetExplodeFptr(win) != FNULL) {
  471.             return((*win_GetExplodeFptr(win))(objdata, msg, indata, outdata));
  472.         }
  473.         break;
  474.  
  475.     case WINM_SETPOS:
  476.         /* move the window to a new location */
  477.         win_ReallySetPixPosition(win, ((opoint *)indata)->x, ((opoint *)indata)->y);
  478.         break;
  479.  
  480.     case WINM_SETSIZE:
  481.         /* change the size of the window */
  482.         win_ReallySetPixSize(win, (odim) ((opoint *)indata)->x, (odim) ((opoint *)indata)->y);
  483.         break;
  484.  
  485.     case WINM_PUTUNDER:
  486.         /* indata in a win_type, put the window under it (if NULL put it on top) */
  487.         win_ReallyPutUnder(win, (win_type) indata);
  488.         break;
  489.  
  490.     case WINM_UNEMPLOY:
  491.         /* a request to unemploy the window */
  492.         win_ReallyUnEmploy(win);
  493.         break;
  494.  
  495.     case WINM_GOREQ:        /* request to be go'ed */
  496.         *((int *)outdata) = win_Go(win);
  497.         break;
  498.  
  499.     case WINM_GO:
  500.         /* send a WINA_GO message to our aux func */
  501.         *((int *)outdata) = obj_DoAux(win, WINA_GO, NULL, NULL);
  502.         break;
  503.  
  504.     case WINM_PAINTREQ:
  505.         /* Paint a window (or employ it if it is unemployed) */
  506.         /* this is passed a bit flag via indata that tells
  507.            whether the border is to be painted or not.
  508.            indata can also be NULL which means paint the whole thing
  509.         */
  510.     
  511.         if (!win_IsEmployed(win)) {
  512.             if (indata == NULL || (*((unsigned *) indata) != WPD_SENTER)) {
  513.                 win_Employ(win);
  514.             }
  515.         }
  516.         else {
  517.             if (indata == NULL || (*((unsigned *) indata) & WPD_BORDER)) {
  518.                 bord_Paint(win);
  519.             }
  520.             else {
  521.                 win_Paint(win);
  522.             }
  523.         }
  524.         break;
  525.  
  526.     case WINM_GETFLDPOS:
  527.         /* get location of control within the window */
  528.         /* outdata is a (ocbox *) */
  529.         /* you should preset the ocbox before calling this message */
  530.         break;
  531.  
  532.     case WINM_SETFLDPOS:
  533.         /* pass control to location closest to curpos */
  534.         /* indata is a (winscp_struct *) */
  535.         break;
  536.  
  537.     case WINM_GETCHILDNO:
  538.         /* get the child number of a window (indata), 
  539.            -1 if window is not a child
  540.         */
  541.         /* indata is a (win_type), outdata is an (int *) */
  542.         *((int *)outdata) = -1;
  543.         break;
  544.  
  545.     case WINM_SETCURRCHILD:        /* set the window's current child */
  546.     case WINM_ISAVE:            /* initial save message */
  547.     case WINM_SCROLLREQ:        /* request for scrolling (from a border) */
  548.     case WINM_ICONREQ:
  549.     case WINM_CHILDCLOSE:        /* notification that a child has been closed */
  550.         break;    /* These messages are supported in a subclass or not at all */
  551.  
  552.     default:
  553.         /* pass other messages to bob superclass */
  554.         return(bob_Class(&(wd->bd), msg, indata, outdata));
  555.     }
  556.     return(TRUE);
  557. }
  558. /* -------------------------------------------------------------------------- */
  559.  
  560. void OWLPRIV win_paintcursor(win_type win)
  561. {
  562.     opbox cursbox;
  563.  
  564.     win_GetCursorPixBox(win, &cursbox);
  565.     if (win_clipbox(win, &cursbox)) {
  566.         win_ExposePixBox(win, &cursbox, WINM_DRAWCURSOR, NULL, WINM_DRAWCURSOR, NULL);
  567.     }
  568. }
  569. /* -------------------------------------------------------------------------- */
  570.  
  571.