home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / lbfix.zip / listbox.h < prev    next >
Text File  |  1994-05-18  |  21KB  |  448 lines

  1.  
  2. /* Program name: Listbox.C    Title: A List Box    Replacement        */
  3. /*                                    */
  4. /* OS/2    Developer Magazine, Issue:  May    '94, page 12                    */
  5. /* Author:  Mark Benge       IBM Corp.                    */
  6. /*        Matt Smith       Prominare Inc.                */
  7. /* Description:     Replacement for OS/2 List Box,    first of a series.    */
  8. /*                                    */
  9. /* Program Requirements:  OS/2 2.x                    */
  10. /*              IBM C    Set++                    */
  11. /*              WATCOM C 386/9.0                */
  12. /*              Borland C++ for OS/2                */
  13. /*              OS/2 Toolkit                    */
  14.  
  15. /* Copyright ╕ International Business Machines Corp. 1991-1994        */
  16. /* Copyright ╕ 1989-1994  Prominare Inc.  All Rights Reserved.        */
  17.  
  18. /* listbox.h       Created:    1993-10-08  Revised:    1994-02-28    */
  19.  
  20. /* List    Box Control Constant Definition    Header                */
  21.  
  22. /* Functions are defined with strong typing to insure correct usage    */
  23. /* within the final program and    correct    linkage                */
  24.  
  25. /************************************************************************/ /* 1.1 */
  26. /************************************************************************/ /* 1.1 */
  27. /*                                    */ /* 1.1 */
  28. /************************************************************************/ /* 1.1 */
  29. /*                                    */ /* 1.1 */
  30. /*     Additions for Version 1.1 of the    control    are denoted with    */ /* 1.1 */
  31. /*     comments    starting in column 76 with the 1.1 version number    */ /* 1.1 */
  32. /*                                    */ /* 1.1 */
  33. /************************************************************************/ /* 1.1 */
  34. /*                                    */ /* 1.1 */
  35. /************************************************************************/ /* 1.1 */
  36. /************************************************************************/ /* 1.1 */
  37.  
  38.  
  39. /* --- Memory Types ---------------------------------------------------    */
  40.  
  41. typedef    ULONG HHEAPMEM;
  42. #define    HALLOC_DEFAULT          0xffffffffUL
  43.  
  44. /* --- Internal    Structures --------------------------------------------    */
  45.  
  46. #define    USER_RESERVED       8       /* Control Reserved Memory Size    */
  47.  
  48. #define    QUCWP_WNDP (QWL_USER + 4)  /* Pointer to Internal Control Data    */
  49.  
  50. #define    CBLK_LIST       1024       /* List Array Block Size        */
  51.  
  52. typedef    struct _LISTITEM
  53.    {                   /* Structure    Size:  24 Bytes        */
  54.    PSZ         pszText;           /* Text Pointer            */
  55.    ULONG     cText;           /* Text Length            */
  56.    ULONG     ulHandle;           /* User Defined Handle        */
  57.    ULONG     fl;           /* Flags (Upper 16 bits old Flags)    */
  58.    LONG         cyItem;           /* Item Height            */
  59.    LONG         cxItem;           /* Item Width            */
  60.    } LISTITEM ;
  61.  
  62. typedef    LISTITEM *PLISTITEM;
  63.  
  64. #define    LI_CLEAR       0x00000000UL
  65. #define    LI_SELECTED       0x00000001UL
  66. #define    LI_FOCUS       0x00000002UL
  67. #define    LI_CHECKED       0x00000004UL                       /* 1.1 */
  68. #define    LI_INSERTED       0x00001000UL
  69. #define    LI_SELECTEDPREV       0x00000010UL
  70. #define    LI_SELECTEDOLD       0x00010000UL
  71. #define    LI_FOCUSOLD       0x00020000UL
  72. #define    LI_CHECKEDOLD       0x00040000UL                       /* 1.1 */
  73. #define    LI_INSERTEDOLD       0x10000000UL
  74. #define    LI_SELECTEDPREVOLD 0x00100000UL
  75.  
  76. typedef    struct _LISTCOL
  77.    {
  78.    HHEAPMEM  hHeap;           /* Heap Handle            */
  79.    PLISTITEM *apli;           /* List Item    Array Pointer        */
  80.    } LISTCOL ;
  81.  
  82. typedef    LISTCOL    *PLISTCOL;
  83.  
  84. typedef    struct _LISTBOXWIN
  85.    {
  86.          /***********************************************************/
  87.          /*    Window Management                    */
  88.          /***********************************************************/
  89.    HHEAPMEM  hHeap;           /* Heap Handle            */
  90.    HAB         hAB;           /* Anchor Block Handle        */
  91.    HWND         hWnd;           /* Control Window Handle        */
  92.    HWND         hwndOwner;           /* Owner Window Handle        */
  93.    HWND         hwndParent;       /* Parent Window Handle        */
  94.    HPOINTER  hptr;           /* Selection    Mouse Pointer        */
  95.          /***********************************************************/
  96.          /*    Styles/ID                        */
  97.          /***********************************************************/
  98.    ULONG     flStyle;           /* Style Flags            */
  99.    ULONG     flStyleExt;       /* Extended Style Flags        */ /* 1.1 */
  100.    ULONG     id;           /* Window ID                */
  101.          /***********************************************************/
  102.          /*    Flags                            */
  103.          /***********************************************************/
  104.    BOOL         fFocus;           /* Focus Flag            */
  105.    BOOL         fDblClk;           /* Mouse Double Click Flag        */
  106.    BOOL         fCapture;           /* Mouse Capture Flag        */
  107.    BOOL         fTimer;           /* Mouse Capture Flag        */
  108.    BOOL         fVisible;           /* List Box Visible Flag        */
  109.    BOOL         fDelaySort;       /* Delay Sort Flag            */
  110.    BOOL         fFocusShown;       /* FocusShown Flag            */
  111.          /***********************************************************/
  112.          /*    Window Display                        */
  113.          /***********************************************************/
  114.    LONG         cx;           /* List Box Width            */
  115.    LONG         cy;           /* List Box Height            */
  116.    LONG         cxWindow;           /* List Box Width  (Actual)        */
  117.    LONG         cyWindow;           /* List Box Height (Actual)        */
  118.    LONG         lClrBackground;       /* Background Colour            */
  119.    LONG         lClrBorder;       /* Border Colour            */
  120.    LONG         lClrHilite;       /* Hilite Colour            */
  121.    LONG         lClrHiliteBackground; /* Hilite Background    Colour        */
  122.    LONG         lClrList;           /* List Colour            */
  123.    LONG         lClrText;           /* Text Colour            */
  124.    LONG         lClrListIndex;       /* List Colour            */
  125.    LONG         lClrTextIndex;       /* Text Colour            */
  126.    RECTL     rcl;           /* Window Rectangle            */
  127.    RECTL     rclCorner;           /* Scroll Corner Rectangle        */
  128.    RECTL     rclAdjusted;       /* Adjusted Top Rectangle        */
  129.    POINTL    aptlOutside[5];       /* Border Points Array        */
  130.    POINTL    aptlInside[5];       /* Border Points Array        */
  131.    LONG         cptl;           /* Border Points Array Count        */
  132.          /***********************************************************/
  133.          /*    Scroll Bars                        */
  134.          /***********************************************************/
  135.    SWP         aswp[4];           /* Scroll Bar Position Array        */
  136.    HWND         hwndScrollBottom;       /* Bottom Scroll Bar    Window Handle    */
  137.    HWND         hwndScrollLeft;       /* Left Scroll Bar Window Handle    */
  138.    HWND         hwndScrollRight;       /* Right Scroll Bar Window Handle    */
  139.    HWND         hwndScrollTop;       /* Top Scroll Bar Window Handle    */
  140.    LONG         cxScroll;           /* Vertical Scroll Bar Width        */
  141.    LONG         cyScroll;           /* Horizontal Scroll    Bar Height    */
  142.          /***********************************************************/
  143.          /*    Scroll Bar Indices                    */
  144.          /***********************************************************/
  145.    LONG         cHorzScroll;       /* Horizontal Scroll    Count        */
  146.    LONG         cVertScroll;       /* Vertical Scroll Count        */
  147.    LONG         iHorzScroll;       /* Horizontal Scroll    Position    */
  148.    LONG         iVertScroll;       /* Vertical Scroll Position        */
  149.          /***********************************************************/
  150.          /*    Indices                            */
  151.          /***********************************************************/
  152.    LONG         iAnchor;           /* Anchor Item Index            */
  153.    LONG         iAnchorLast;       /* Last Anchor Item Index        */
  154.    LONG         iFocus;           /* Focus Item Index            */
  155.    LONG         iFocusLast;       /* Last Focus Item Index        */
  156.    LONG         iSelected;           /* Selected Item Index        */
  157.    LONG         iSelectedLast;       /* Last Selected Item Index        */
  158.          /***********************************************************/
  159.          /*    List Box Limits                        */
  160.          /***********************************************************/
  161.    LONG         cCharsPage;       /* Characters per Page        */
  162.    LONG         cLinesPage;       /* Lines per    Page            */
  163.    LONG         cxItem;           /* Longest Horizontal Item        */
  164.    LONG         cyItem;           /* Item Height            */
  165.    LONG         xChar;           /* Character    Width            */
  166.    LONG         yAscender;           /* Character    Ascender Height        */
  167.          /***********************************************************/
  168.          /*    List Box List                        */
  169.          /***********************************************************/
  170.    PLISTCOL  plc;           /* List Column Array            */
  171.    LONG         cColumns;           /* Columns Count            */
  172.    LONG         cItems;           /* Items Count            */
  173.    BOOL         fDirty;           /* Dirty Update Flag            */
  174.          /***********************************************************/ /* 1.1 */
  175.          /*    Sound Support                        */ /* 1.1 */
  176.          /***********************************************************/ /* 1.1 */
  177.    HMODULE   hmodSnd;           /* Sound Support DLL    Handle        */ /* 1.1 */
  178.    ULONG     (*    EXPENTRY pfnLoadWaveFile)(HWND hWnd, PSZ pszWaveFile);       /* 1.1 */
  179.    VOID         (*    EXPENTRY pfnUnloadWave)(HWND hWnd, ULONG hSound);       /* 1.1 */
  180.    VOID         (*    EXPENTRY pfnPlayWave)(ULONG hSound);               /* 1.1 */
  181.    CHAR         szSClkWAV[CCHMAXPATH];/* Single Click Wave    File        */ /* 1.1 */
  182.    ULONG     ulSClkWAV;           /* Single Click Wave    File Handle    */ /* 1.1 */
  183.    CHAR         szDClkWAV[CCHMAXPATH];/* Double Click Wave    File        */ /* 1.1 */
  184.    ULONG     ulDClkWAV;           /* Double Click Wave    File Handle    */ /* 1.1 */
  185.          /***********************************************************/ /* 1.1 */
  186.          /*    Check Box Support                    */ /* 1.1 */
  187.          /***********************************************************/ /* 1.1 */
  188.    HBITMAP   hbm;           /* Check Mark Bitmap    Handle        */ /* 1.1 */
  189.    BOOL         fEnableCheckboxes;       /* Check Box    Enable Flag        */ /* 1.1 */
  190.    RECTL     rclChecked;       /* Checked Bitmap Rectangle        */ /* 1.1 */
  191.    RECTL     rclUnChecked;       /* Unchecked    Bitmap Rectangle    */ /* 1.1 */
  192.    LONG         xTextOffset;       /* Text Offset            */ /* 1.1 */
  193.    LONG         cyHalfBitmap;       /* Bitmap Half Height        */ /* 1.1 */
  194.    } LISTBOXWIN    ;
  195.  
  196. typedef    LISTBOXWIN *PLISTBOXWIN;
  197.  
  198. #define    SWP_VERT       0
  199. #define    SWP_HORZ       1
  200.  
  201. #define    IDT_SCROLL    512
  202.  
  203. #if defined(VERSION_100)                           /* 1.1 */
  204.  
  205. typedef    struct _LISTBOXCDATA
  206.    {
  207.    ULONG    cb;               /* Structure    Size            */
  208.    ULONG    ulVersion;           /* Structure    Version    NUmber        */
  209.    ULONG    cItems;           /* Items Count            */
  210.    BYTE        abList[1];           /* Array List Start            */
  211.    } LISTBOXCDATA ;
  212.  
  213. typedef    LISTBOXCDATA *PLISTBOXCDATA;
  214.  
  215. #define    LBV_100        10000UL       /* Control Data Version Number    */
  216.  
  217. #else                                       /* 1.1 */
  218.                                        /* 1.1 */
  219. typedef    struct _LISTBOXCDATA1                           /* 1.1 */
  220.    {                                       /* 1.1 */
  221.    ULONG    cItems;           /* Items Count            */ /* 1.1 */
  222.    BYTE        abList[1];           /* Array List Start            */ /* 1.1 */
  223.    } LISTBOXCDATA1 ;                               /* 1.1 */
  224.                                        /* 1.1 */
  225. typedef    struct _LISTBOXCDATA2                           /* 1.1 */
  226.    {                                       /* 1.1 */
  227.    ULONG    flExtStyles;       /* Extended Styles            */ /* 1.1 */
  228.    ULONG    cItems;           /* Items Count            */ /* 1.1 */
  229.    ULONG    cSounds;           /* Sounds Count            */ /* 1.1 */
  230.    BYTE        abList[1];           /* Array List Start            */ /* 1.1 */
  231.    } LISTBOXCDATA2 ;                               /* 1.1 */
  232.                                        /* 1.1 */
  233. typedef    union                                   /* 1.1 */
  234.    {                                       /* 1.1 */
  235.    LISTBOXCDATA1 lbcd1_0;       /* List Box Control Data Version 1.0    */ /* 1.1 */
  236.    LISTBOXCDATA2 lbcd1_1;       /* List Box Control Data Version 1.1    */ /* 1.1 */
  237.    } LISTBOXVDATA ;                               /* 1.1 */
  238.                                        /* 1.1 */
  239. typedef    struct _LISTBOXCDATA                           /* 1.1 */
  240.    {                                       /* 1.1 */
  241.    ULONG    cb;           /* Structure    Size            */ /* 1.1 */
  242.    ULONG    ulVersion;       /* Structure    Version    Number        */ /* 1.1 */
  243.    LISTBOXVDATA    vdata;           /* Version Specific Data Union    */ /* 1.1 */
  244.    } LISTBOXCDATA ;                               /* 1.1 */
  245.                                        /* 1.1 */
  246. typedef    LISTBOXCDATA *PLISTBOXCDATA;                       /* 1.1 */
  247.                                        /* 1.1 */
  248. #define    LBV_100       0x00010000UL       /* Control Data Version Number    */ /* 1.1 */
  249. #define    LBV_110       0x000100a0UL       /* Control Data Version Number    */ /* 1.1 */
  250.                                        /* 1.1 */
  251. #endif                                       /* 1.1 */
  252.  
  253. /************************************************************************/
  254. /************************************************************************/
  255. /*                                    */
  256. /*     Class Definition                            */
  257. /*                                    */
  258. /************************************************************************/
  259. /************************************************************************/
  260.  
  261. #define    CLASS_LISTBOX  "ListBoxWindow"
  262.  
  263. /************************************************************************/
  264. /************************************************************************/
  265. /*                                    */
  266. /*     Inline Macros                            */
  267. /*                                    */
  268. /************************************************************************/
  269. /************************************************************************/
  270.  
  271. #define    SaveSelectState(iCol, iSelected)  { if ( plbw->flStyle & LS_OWNERDRAW )\
  272.    if (    (plbw->plc[iCol].apli[iSelected]->fl & LI_SELECTED) && fItemVisible(plbw, iSelected) )\
  273.        plbw->plc[iCol].apli[iSelected]->fl |= LI_SELECTEDPREV;\
  274.    else\
  275.        plbw->plc[iCol].apli[iSelected]->fl &= ~LI_SELECTEDPREV;    }
  276.  
  277. /************************************************************************/
  278. /************************************************************************/
  279. /*                                    */
  280. /*     Extended    Messages                        */
  281. /*                                    */
  282. /************************************************************************/
  283. /************************************************************************/
  284.  
  285. #define    LMX_CALCLINECOUNT      0x0180UL
  286. #define    LMX_CALCSIZE           0x0181UL
  287. #define    LMX_COPY           0x0182UL
  288. #define    LMX_CUT               0x0183UL
  289. #define    LMX_PASTE           0x0184UL
  290. #define    LMX_QUERYITEMCOUNT     0x0185UL
  291. #define    LMX_QUERYITEMRECT      0x0186UL
  292. #define    LMX_QUERYSELECTLIST    0x0187UL
  293. #define    LMX_RESETLIST           0x0188UL
  294. #define    LMX_SELECTALL           0x0189UL
  295. #define    LMX_SELECTITEMBITMAP   0x018aUL
  296. #define    LMX_SETARRAY           0x018bUL
  297. #define    LMX_SETARRAYHANDLES    0x018cUL
  298. #define    LMX_SETITEMBITMAPS     0x018dUL
  299. #define    LMX_SETITEMCOUNT       0x018eUL
  300. #define    LMX_SORT           0x018fUL
  301. #define    LMX_SETARRAYITEMS      0x0190UL
  302. #define    LMX_ADDARRAY           0x0191UL
  303.  
  304. #define    LMX_SETCHECK           0x0192UL                       /* 1.1 */
  305. #define    LMX_QUERYCHECK           0x0193UL                       /* 1.1 */
  306. #define    LMX_SETCHECKARRAY      0x0194UL                       /* 1.1 */
  307. #define    LMX_QUERYCHECKARRAY    0x0195UL                       /* 1.1 */
  308.  
  309. #define    LMXM_SETSOUNDEVENT     0x0196UL                       /* 1.1 */
  310. #define    LMXM_QUERYSOUNDEVENT   0x0197UL                       /* 1.1 */
  311.  
  312. /************************************************************************/ /* 1.1 */
  313. /************************************************************************/ /* 1.1 */
  314. /*                                    */ /* 1.1 */
  315. /*     Sound Events                            */ /* 1.1 */
  316. /*                                    */ /* 1.1 */
  317. /************************************************************************/ /* 1.1 */
  318. /************************************************************************/ /* 1.1 */
  319.  
  320. #define    LSND_SINGLECLICK     1                       /* 1.1 */
  321. #define    LSND_DOUBLECLICK     2                       /* 1.1 */
  322.  
  323. /************************************************************************/ /* 1.1 */
  324. /************************************************************************/ /* 1.1 */
  325. /*                                    */ /* 1.1 */
  326. /*     Check Boxes                            */ /* 1.1 */
  327. /*                                    */ /* 1.1 */
  328. /************************************************************************/ /* 1.1 */
  329. /************************************************************************/ /* 1.1 */
  330.  
  331. #define    IDB_CHECKMARKS         512                       /* 1.1 */
  332.  
  333. /************************************************************************/ /* 1.1 */
  334. /************************************************************************/ /* 1.1 */
  335. /*                                    */ /* 1.1 */
  336. /*     Style Extensions                            */ /* 1.1 */
  337. /*                                    */ /* 1.1 */
  338. /************************************************************************/ /* 1.1 */
  339. /************************************************************************/ /* 1.1 */
  340.  
  341. #define    LSXS_CHECKBOX         0x00000001UL                   /* 1.1 */
  342.  
  343. /************************************************************************/ /* 1.1 */
  344. /************************************************************************/ /* 1.1 */
  345. /*                                    */ /* 1.1 */
  346. /*     Notification Extensions                        */ /* 1.1 */
  347. /*                                    */ /* 1.1 */
  348. /************************************************************************/ /* 1.1 */
  349. /************************************************************************/ /* 1.1 */
  350.  
  351. #define    LNX_CHECKED         256UL                       /* 1.1 */
  352.  
  353. /************************************************************************/
  354. /************************************************************************/
  355. /*                                    */
  356. /*     Prototypes                            */
  357. /*                                    */
  358. /************************************************************************/
  359. /************************************************************************/
  360.  
  361. /* --- EventMgr.C Prototype Definitions    -------------------------------    */
  362.  
  363. MRESULT    mrNotifyOwner(PLISTBOXWIN plbw,    ULONG ulNotification);
  364.  
  365. /* --- HeapMgr.C Prototype Definitions --------------------------------    */
  366.  
  367. HHEAPMEM HeapAlloc(ULONG cbInitial, ULONG cbNewBlks);
  368. VOID     HeapRelease(HHEAPMEM hHeap);
  369. ULONG     HeapSize(HHEAPMEM hHeap);
  370.  
  371. VOID     HeapStatus(HHEAPMEM hHeap, PULONG pcBlocks, PULONG pulSize,
  372.             PULONG pulUsed, PULONG pulFree, PULONG pulUnused, PULONG pulOverhead);
  373. VOID     HeapDisplayStatus(HHEAPMEM hHeap);
  374.  
  375. PVOID     HeapMalloc(HHEAPMEM hHeap, ULONG cbSize);
  376. PVOID     HeapCalloc(HHEAPMEM hHeap, ULONG cItems, ULONG    cbSize);
  377. PVOID     HeapRealloc(HHEAPMEM hHeap, PVOID pv, ULONG cbSize);
  378. VOID     HeapFree(HHEAPMEM hHeap, PVOID    pv);
  379.  
  380. /* --- ListBox.C Prototype Definitions --------------------------------    */
  381.  
  382. BOOL EXPENTRY fRegisterListBox(HAB hAB);
  383. VOID UpdateScrollBars(PLISTBOXWIN plbw);
  384. VOID DrawSelection(PLISTBOXWIN plbw, LONG iItem);
  385. VOID DrawItemSelection(PLISTBOXWIN plbw, LONG iItem);
  386. BOOL fItemVisible(PLISTBOXWIN plbw, LONG iItem);
  387. LONG lItemFromPoint(PLISTBOXWIN    plbw, LONG y);
  388. MRESULT    EXPENTRY ScrollBarWndProc(HWND hWnd, ULONG msg,    MPARAM mp1, MPARAM mp2);
  389. MRESULT    EXPENTRY ListBoxWndProc(HWND hWnd, ULONG msg, MPARAM mp1, MPARAM mp2);
  390.  
  391. /* --- ListMgr.C Prototype Definitions --------------------------------    */
  392.  
  393. LONG lSetItemText(HHEAPMEM hHeap, HWND hWnd, PLISTITEM pli, PSZ    pszText);
  394. VOID SaveExtendedState(PLISTBOXWIN plbw);
  395. VOID RestoreExtendedState(PLISTBOXWIN plbw);
  396. BOOL fSelectMultipleItem(PLISTBOXWIN plbw, LONG    iCol, LONG iSelected, BOOL fSelect);
  397. BOOL fSelectItem(PLISTBOXWIN plbw, LONG    iCol, LONG iItem, BOOL fSelect);
  398. VOID SelectExtendedItems(PLISTBOXWIN plbw, LONG    iCol, LONG iSelected);
  399. VOID SetControlDataList(PLISTBOXWIN plbw, ULONG    cItems,    PBYTE pb);
  400. MRESULT    EXPENTRY mrBaseListHandler(HWND    hWnd, ULONG msg, MPARAM    mp1, MPARAM mp2);
  401. MRESULT    EXPENTRY mrExtendedListHandler(HWND hWnd, ULONG    msg, MPARAM mp1, MPARAM    mp2);
  402. MRESULT    EXPENTRY mrChkBoxHandler(HWND hWnd, ULONG msg, MPARAM mp1,       /* 1.1 */
  403.                  MPARAM    mp2);                   /* 1.1 */
  404.  
  405. /* --- SndMgr.C    Prototype Definitions ---------------------------------    */ /* 1.1 */
  406.  
  407. VOID LoadSoundSupport(PLISTBOXWIN plbw);                   /* 1.1 */
  408. VOID PlaySound(PLISTBOXWIN plbw, ULONG ulSound);               /* 1.1 */
  409. VOID UnloadSoundSupport(PLISTBOXWIN plbw);                   /* 1.1 */
  410. VOID SetControlDataSounds(PLISTBOXWIN plbw, ULONG cItems, ULONG    cSounds,   /* 1.1 */
  411.               PBYTE    pb);                       /* 1.1 */
  412. MRESULT    EXPENTRY mrSoundHandler(HWND hWnd, ULONG msg, MPARAM mp1,       /* 1.1 */
  413.                 MPARAM mp2);                   /* 1.1 */
  414.  
  415. /* --- TraffMgr.C Prototype Definitions    -------------------------------    */
  416.  
  417. LONG lGetPresParam(HWND    hWnd, ULONG ulID1, ULONG ulID2,    LONG lDefault);
  418. BOOL fAddHorzScroll(HWND hWnd, PLISTBOXWIN plbw);
  419. VOID MeasureItem(PLISTBOXWIN plbw, LONG    lMaxBaselineExt);
  420. VOID SizeListBox(PLISTBOXWIN plbw);
  421. VOID FocusChange(PLISTBOXWIN plbw, LONG    iFocus,    BOOL fSet);
  422. VOID RemoveFocus(PLISTBOXWIN plbw);
  423. VOID SetFocus(PLISTBOXWIN plbw,    LONG iFocus);
  424. VOID DrawItemSelection(PLISTBOXWIN plbw, LONG iItem);
  425. BOOL fDecodeChkSelect(PLISTBOXWIN plbw,    MPARAM mp1);               /* 1.1 */
  426. BOOL fDecodeMouse(PLISTBOXWIN plbw, MPARAM mp1);
  427. BOOL fDecodeExtendedMouse(PLISTBOXWIN plbw, MPARAM mp1,    BOOL fBlock);
  428. VOID LineUp(PLISTBOXWIN    plbw);
  429. VOID LineDown(PLISTBOXWIN plbw);
  430. VOID DragUp(PLISTBOXWIN    plbw);
  431. VOID DragDown(PLISTBOXWIN plbw);
  432.  
  433. /************************************************************************/ /* 1.1 */
  434. /************************************************************************/ /* 1.1 */
  435. /*                                    */ /* 1.1 */
  436. /*     Sound DLL Support                        */ /* 1.1 */
  437. /*                                    */ /* 1.1 */
  438. /************************************************************************/ /* 1.1 */
  439. /************************************************************************/ /* 1.1 */
  440.  
  441. ULONG EXPENTRY LoadWaveFile(HWND hWnd, PSZ pszWaveFile);           /* 1.1 */
  442. VOID  EXPENTRY UnloadWave(HWND hWnd, ULONG hSound);               /* 1.1 */
  443. VOID  EXPENTRY PlayWave(ULONG hSound);                       /* 1.1 */
  444.  
  445. #define    ORD_LOADWAVEFILE     1                       /* 1.1 */
  446. #define    ORD_PLAYWAVE         2                       /* 1.1 */
  447. #define    ORD_UNLOADWAVE         3                       /* 1.1 */
  448.