| 1 | /* $Id: header.h,v 1.10 2000-04-18 16:04:55 cbratschi Exp $ */
|
|---|
| 2 |
|
|---|
| 3 | /*
|
|---|
| 4 | * Header window definitions
|
|---|
| 5 | *
|
|---|
| 6 | * Copyright 1998 Eric Kohl
|
|---|
| 7 | * Copyright 1999 Christoph Bratschi
|
|---|
| 8 | *
|
|---|
| 9 | */
|
|---|
| 10 |
|
|---|
| 11 | #ifndef __WINE_HEADER_H_
|
|---|
| 12 | #define __WINE_HEADER_H_
|
|---|
| 13 |
|
|---|
| 14 | typedef struct
|
|---|
| 15 | {
|
|---|
| 16 | INT cxy;
|
|---|
| 17 | HBITMAP hbm;
|
|---|
| 18 | LPWSTR pszText;
|
|---|
| 19 | INT cchTextMax;
|
|---|
| 20 | INT fmt;
|
|---|
| 21 | LPARAM lParam;
|
|---|
| 22 | INT iImage;
|
|---|
| 23 | INT iOrder; /* see documentation of HD_ITEM */
|
|---|
| 24 | UINT type;
|
|---|
| 25 | LPVOID pvFilter;
|
|---|
| 26 |
|
|---|
| 27 | BOOL bDown; /* is item pressed? (used for drawing) */
|
|---|
| 28 | RECT rect; /* bounding rectangle of the item */
|
|---|
| 29 | } HEADER_ITEM;
|
|---|
| 30 |
|
|---|
| 31 |
|
|---|
| 32 | typedef struct
|
|---|
| 33 | {
|
|---|
| 34 | COMCTL32_HEADER header;
|
|---|
| 35 |
|
|---|
| 36 | UINT uNumItem; /* number of items (columns) */
|
|---|
| 37 | INT nHeight; /* height of the header (pixels) */
|
|---|
| 38 | HFONT hFont; /* handle to the current font */
|
|---|
| 39 | HCURSOR hcurArrow; /* handle to the arrow cursor */
|
|---|
| 40 | HCURSOR hcurDivider; /* handle to a cursor (used over dividers) <-|-> */
|
|---|
| 41 | HCURSOR hcurDivopen; /* handle to a cursor (used over dividers) <-||-> */
|
|---|
| 42 | BOOL bCaptured; /* Is the mouse captured? */
|
|---|
| 43 | BOOL bPressed; /* Is a header item pressed (down)? */
|
|---|
| 44 | BOOL bTracking; /* Is in tracking mode? */
|
|---|
| 45 | BOOL bTrackOpen;
|
|---|
| 46 | BOOL bDragDrop;
|
|---|
| 47 | BOOL bTimer;
|
|---|
| 48 | INT iMoveItem; /* index of tracked item. (Tracking mode) */
|
|---|
| 49 | INT xTrackOffset; /* distance between the right side of the tracked item and the cursor */
|
|---|
| 50 | INT xOldTrack; /* track offset (see above) after the last WM_MOUSEMOVE */
|
|---|
| 51 | INT nOldWidth; /* width of a sizing item after the last WM_MOUSEMOVE */
|
|---|
| 52 | INT iHotItem; /* index of hot item (cursor is over this item) */
|
|---|
| 53 | INT xBmpMargin;
|
|---|
| 54 |
|
|---|
| 55 | HIMAGELIST himl; /* handle to a image list (may be 0) */
|
|---|
| 56 | HIMAGELIST dragImage;
|
|---|
| 57 | POINT dragStart;
|
|---|
| 58 | POINT dragPos;
|
|---|
| 59 | INT iDragItem;
|
|---|
| 60 | HEADER_ITEM *items; /* pointer to array of HEADER_ITEM's */
|
|---|
| 61 | } HEADER_INFO;
|
|---|
| 62 |
|
|---|
| 63 | extern LRESULT HEADER_DeleteItem(HWND hwnd,WPARAM wParam);
|
|---|
| 64 | extern DWORD HEADER_GetExpandedColumnTextWidth(HWND hwnd,INT iItem);
|
|---|
| 65 | extern LRESULT HEADER_GetItem(HWND hwnd,WPARAM wParam,LPARAM lParam,BOOL unicode);
|
|---|
| 66 | extern LRESULT HEADER_GetItemCount(HWND hwnd);
|
|---|
| 67 | extern LRESULT HEADER_GetItemRect(HWND hwnd,WPARAM wParam,LPARAM lParam);
|
|---|
| 68 | extern LRESULT HEADER_InsertItem(HWND hwnd,WPARAM wParam,LPARAM lParam,BOOL unicode);
|
|---|
| 69 | extern LRESULT HEADER_SetItem(HWND hwnd,WPARAM wParam,LPARAM lParam,BOOL unicode);
|
|---|
| 70 | extern LRESULT HEADER_SetOrderArray(HWND hwnd,WPARAM wParam,LPARAM lParam);
|
|---|
| 71 | extern LRESULT HEADER_GetOrderArray(HWND hwnd,WPARAM wParam,LPARAM lParam);
|
|---|
| 72 | extern LRESULT HEADER_Layout(HWND hwnd,WPARAM wParam,LPARAM lParam);
|
|---|
| 73 |
|
|---|
| 74 | extern VOID HEADER_Register (VOID);
|
|---|
| 75 | extern VOID HEADER_Unregister (VOID);
|
|---|
| 76 |
|
|---|
| 77 | #endif /* __WINE_HEADER_H_ */
|
|---|