Release 980329

Sun Mar 29 15:18:57 1998  Uwe Bonnes <elektron.ikp.physik.tu-darmstadt.de>

	* [msdos/int21.c]
	More verbose Trace messages

Sun Mar 29 15:03:30 1998  Alexandre Julliard  <julliard@lrc.epfl.ch>

	* [loader/ne_image.c]
	Terminate relocation chains on 0 offset.

Sun Mar 29 02:35:45 1998  James Juran  <jrj120@psu.edu>

	* [windows/caret.c] [windows/class.c] [windows/clipboard.c]
	Fixed more USER32 ordinal numbers in function documentation.

Sat Mar 28 22:40:23 1997  Andreas Mohr <100.30936@germany.net>

	* [controls/desktop.c]
	Return 1 for WM_NCCREATE in DesktopWndProc.

	* [controls/menu.c]
	Fixed crash when destroying a top popup win that was only created
	but not shown.

	* [ole/typelib.c] [if1632/typelib.spec]
	Implemented OABuildVersion.

	* [windows/win.c]
	Finally fixed ugly bug in GetParent32 that affected window placement:
	Didn't return 0 for windows that have neither WS_POPUP nor
	WS_CHILD set. Now it acts exactly like Windows (at least I hope so ;)

Sat Mar 28 02:26:43 1998  Dimitrie O. Paun  <dimi@mail.cs.toronto.edu>

	* [DEVELOPERS-HINTS] [documentation/debug-msgs]
	Updated documentation on debug messages

	* [include/button.h] [controls/button.c] [include/windows.h]
	[include/combo.h] [controls/combo.c] [controls/commctrl.c]
	[controls/icontitle.c] [controls/listbox.c]	[controls/menu.c]
	[controls/scroll.c] [controls/widgets.c] 
	Changed some 16-bit code to 32-bit code. I am positive this will
	not break anything.

	* [controls/uitools.c] 
	Renamed the prefix of some functions from UITOOLS_ to UITOOLS95_
	to reflect the fact that they implement Win95 look. Maybe we will
	have a UITOOLS31_ in the future. Anyhow, the change is completely
	internal to this file.

	* [*/*.c]
	Changed a lot of [f]printf into appropriate debug messages.

Fri Mar 27 19:56:12 1998  Marcus Meissner <msmeissn@cip.informatik.uni-erlangen.de>
	* [documentation/status/]
	Added directdraw and directsound status.

	* [if1632/thunk.c][ole/*.c][win32/kernel32.c]
	Added some documentation.
	Moved FUNC004 to thunk.c since it seems to be a 16->32 thunk
	(calling conventions and the like still unknown).

Fri Mar 27 09:59:32 1998  Morten Eriksen  <mortene@pvv.org>

	* [loader/resource.c][windows/keyboard.c]
	Implemented CopyAcceleratorTable() and CreateAcceleratorTable().
	
	* [include/compobj.h][ole/compobj.c][relay32/ole32.spec]
	Added implementation of StringFromGUID2(). 

Tue Mar 26 23:12:05 1998  Eric Kohl <ekohl@abo.rhein-zeitung.de>

	* [misc/imagelist.c][relay32/comctl32.spec]
	Implemented new debugging interface.
	Added missing functions (some are empty stubs).
	Changed ordinals in comctl32.spec (now dll version 4.72 comatible).

	* [objects/oembitmaps.c][include/windows.h]
	  [include/bitmaps/*]
	Added missing restore bitmaps for Win95 look.
	Added missing Win95 cursors.

Thu Mar 26 10:18:20 1998  Douglas Ridgway  <ridgway@winehq.com>

	* [programs/view/Makefile.in] [programs/view/view.c]
	Fix compilation, Aldus placeable metafile loading.

	* [graphics/metafiledrv/init.c] [relay32/gdi32.spec] 
	  [objects/metafile.c]
	Implemented various 32 bit versions of regular metafile API.

	* [objects/enhmetafile.c]
	Implemented rendering of a couple of dozen records.

Tue Mar 24 20:06:39 1998  Matthew Becker <mbecker@glasscity.net>

	* [memory/*.c]
	Updated documentation for API manpages.

Mon Mar 23 09:09:00 1998  Alex Korobka <alex@pharm.sunysb.edu>

	* [misc/winsock.c]
	Fixed 32-bit DNS lookup.

Mon Mar 23 23:54:47 1998  Luiz Otavio L. Zorzella  <zorzella@nr.conexware.com>

	* [multimedia/init.c]
	New code for the initialization and gathering of information about
	the MIDI devices, for future use.

Thu Mar 19 00:59:29 1998  Jim Peterson <jspeter@nospam.birch.ee.vt.edu>

	* [windows/win.c]
	Eliminated inaccurate setting of cs->hMenu in
	WIN_CreateWindowEx, along with superfluous SetMenu32 call.

Mon Mar 16 17:40:53 1998  Petter Reinholdtsen <pere@td.org.uit.no>

	* [debugger/dbg.y] [debugger/Makefile.in] [Makefile.in]
	Install wine.sym in $(exec_prefix)/lib and make sure the debugger
	finds it.

Sun Mar 15 22:36:35 1998  Michael Veksler <mveksler@tx.technion.ac.il>

	* [dummy.c] [if1632/gdi.spec]
	Fixed stub declaration of GDI_532, so Hebrew-Word2 kind of works.
diff --git a/include/bitmaps/obm_restore_95 b/include/bitmaps/obm_restore_95
new file mode 100644
index 0000000..886f675
--- /dev/null
+++ b/include/bitmaps/obm_restore_95
@@ -0,0 +1,23 @@
+/* XPM */
+static char * obm_restore_95[] = {
+"16 14 6 1",
+" 	s button_highlight	c white",
+"+	s button_edge	c grey85",
+"X	s button_face	c grey75",
+"o	s button_shadow	c grey50",
+".	s button_text	c black",
+"O	s window_frame	c black",
+"               O",
+" +++++++++++++oO",
+" +XXX......XXXoO",
+" +XXX......XXXoO",
+" +XXX.XXXX.XXXoO",
+" +X......X.XXXoO",
+" +X......X.XXXoO",
+" +X.XXXX...XXXoO",
+" +X.XXXX.XXXXXoO",
+" +X.XXXX.XXXXXoO",
+" +X......XXXXXoO",
+" +XXXXXXXXXXXXoO",
+" ooooooooooooooO",
+"OOOOOOOOOOOOOOOO"};
diff --git a/include/bitmaps/obm_restored_95 b/include/bitmaps/obm_restored_95
new file mode 100644
index 0000000..4886e06
--- /dev/null
+++ b/include/bitmaps/obm_restored_95
@@ -0,0 +1,23 @@
+/* XPM */
+static char * obm_restored_95[] = {
+"16 14 6 1",
+" 	s button_highlight	c white",
+"+	s button_edge	c grey85",
+"X	s button_face	c grey75",
+"o	s button_shadow	c grey50",
+".	s button_text	c black",
+"O	s window_frame	c black",
+"OOOOOOOOOOOOOOO ",
+"Oooooooooooooo+ ",
+"OoXXXXXXXXXXXX+ ",
+"OoXXXX......XX+ ",
+"OoXXXX......XX+ ",
+"OoXXXX.XXXX.XX+ ",
+"OoXX......X.XX+ ",
+"OoXX......X.XX+ ",
+"OoXX.XXXX...XX+ ",
+"OoXX.XXXX.XXXX+ ",
+"OoXX.XXXX.XXXX+ ",
+"OoXX......XXXX+ ",
+"O++++++++++++++ ",
+"                "};
diff --git a/include/bitmaps/ocr_appstarting b/include/bitmaps/ocr_appstarting
new file mode 100644
index 0000000..2e4793c
--- /dev/null
+++ b/include/bitmaps/ocr_appstarting
@@ -0,0 +1,40 @@
+/* XPM */
+static char *ocr_appstarting[] = {
+" 32 32 3 1 0 0",
+" 	s None c None",
+".	s black c black",
+"X	s white c white",
+".                                ",
+"..          ..........           ",
+".X.         ..XXXXXX..           ",
+".XX.        ..........           ",
+".XXX.        .XXXXXX.            ",
+".XXXX.       .XXXXXX.            ",
+".XXXXX.      .XXX.XX.            ",
+".XXXXXX.     ..X.XX..            ",
+".XXXXXXX.     ..XX..             ",
+".XXXXXXXX.     ..X.              ",
+".XXXXX.....   ..XX..             ",
+".XX.XX.      ..XXXX..            ",
+".X. .XX.     .XX.XXX.            ",
+"..  .XX.     .X.X.XX.            ",
+".    .XX.    ..X.X.X.            ",
+"     .XX.   ..........           ",
+"      .XX.  ..XXXXXX..           ",
+"      .XX.  ..........           ",
+"       ..                        ",
+"                                 ",
+"                                 ",
+"                                 ",
+"                                 ",
+"                                 ",
+"                                 ",
+"                                 ",
+"                                 ",
+"                                 ",
+"                                 ",
+"                                 ",
+"                                 ",
+"                                 "
+};
+
diff --git a/include/bitmaps/ocr_help b/include/bitmaps/ocr_help
new file mode 100644
index 0000000..2fbbabd
--- /dev/null
+++ b/include/bitmaps/ocr_help
@@ -0,0 +1,40 @@
+/* XPM */
+static char *ocr_help[] = {
+" 32 32 3 1 0 0",
+" 	s None  c None",
+".	s black c black",
+"X	s white c white",
+".                               ",
+"..          XXXXXXX             ",
+".X.        X.......X            ",
+".XX.      X...XX....X           ",
+".XXX.    X...X  X....X          ",
+".XXXX.   X...X  X....X          ",
+".XXXXX.  X...X  X....X          ",
+".XXXXXX. X...X  X...X           ",
+".XXXXXXX.XXXXX X...X            ",
+".XXXXXXXX.    X...X             ",
+".XXXXX.....  X...X              ",
+".XX.XX.      X...X              ",
+".X. .XX.     X...X              ",
+"..  .XX.      XXX               ",
+".    .XX.    X...X              ",
+"     .XX.   X.....X             ",
+"      .XX.   X...X              ",
+"      .XX.    XXX               ",
+"       ..                       ",
+"                                ",
+"                                ",
+"                                ",
+"                                ",
+"                                ",
+"                                ",
+"                                ",
+"                                ",
+"                                ",
+"                                ",
+"                                ",
+"                                ",
+"                                "
+};
+
diff --git a/include/bitmaps/ocr_no b/include/bitmaps/ocr_no
new file mode 100644
index 0000000..1fe072f
--- /dev/null
+++ b/include/bitmaps/ocr_no
@@ -0,0 +1,38 @@
+/* XPM */
+static char *ocr_no[] = {
+"32 32 3 1 16 16",
+" 	s None c None",
+".	s white c white",
+"X	s black c black",
+"                                ",
+"                                ",
+"                                ",
+"                                ",
+"                                ",
+"                                ",
+"             ......             ",
+"           ..XXXXXX..           ",
+"          .XXXXXXXXXX.          ",
+"         .XXXX....XXXX.         ",
+"        .XXX..    ..XXX.        ",
+"       .XXXXX.      .XXX.       ",
+"       .XX.XXX.      .XX.       ",
+"      .XXX..XXX.     .XXX.      ",
+"      .XX.  .XXX.     .XX.      ",
+"      .XX.   .XXX.    .XX.      ",
+"      .XX.    .XXX.   .XX.      ",
+"      .XX.     .XXX.  .XX.      ",
+"      .XXX.     .XXX..XXX.      ",
+"       .XX.      .XXX.XX.       ",
+"       .XXX.      .XXXXX.       ",
+"        .XXX..    ..XXX.        ",
+"         .XXXX....XXXX.         ",
+"          .XXXXXXXXXX.          ",
+"           ..XXXXXX..           ",
+"             ......             ",
+"                                ",
+"                                ",
+"                                ",
+"                                ",
+"                                ",
+"                                "};
diff --git a/include/combo.h b/include/combo.h
index aa808dc..3b2e8e2 100644
--- a/include/combo.h
+++ b/include/combo.h
@@ -31,11 +31,11 @@
    UINT32  	dwStyle;
    HWND32  	hWndEdit;
    HWND32  	hWndLBox;
-   UINT16  	wState;
-   HFONT16 	hFont;
-   RECT16  	RectCombo;
-   RECT16  	RectEdit;
-   RECT16  	RectButton;
+   UINT32  	wState;
+   HFONT32 	hFont;
+   RECT32  	RectCombo;
+   RECT32  	RectEdit;
+   RECT32  	RectButton;
    INT32   	droppedWidth;		/* last two are not used unless set */
    INT32   	editHeight;		/* explicitly */
 } HEADCOMBO,*LPHEADCOMBO;
diff --git a/include/commctrl.h b/include/commctrl.h
index 38ea959..33404f5 100644
--- a/include/commctrl.h
+++ b/include/commctrl.h
@@ -9,6 +9,21 @@
 
 void WINAPI InitCommonControls(void);
 
+/* common control styles */
+
+#define CCS_TOP             0x00000001L
+#define CCS_NOMOVEY         0x00000002L
+#define CCS_BOTTOM          0x00000003L
+#define CCS_NORESIZE        0x00000004L
+#define CCS_NOPARENTALIGN   0x00000008L
+#define CCS_ADJUSTABLE      0x00000020L
+#define CCS_NODIVIDER       0x00000040L
+#define CCS_VERT            0x00000080L
+#define CCS_LEFT            (CCS_VERT|CCS_TOP)
+#define CCS_RIGHT           (CCS_VERT|CCS_BOTTOM)
+#define CCS_NOMOVEX         (CCS_VERT|CCS_NOMOVEY)
+
+
 /* StatusWindow */
 
 #define STATUSCLASSNAME16     "msctls_statusbar"
@@ -38,7 +53,6 @@
 #define SBT_RTLREADING        0x0400
 #define SBT_OWNERDRAW         0x1000
 
-#define CCS_BOTTOM            0x0003
 #define SBARS_SIZEGRIP        0x0100
 
 /* UpDown */
@@ -117,19 +131,19 @@
 typedef struct _IMAGELIST *HIMAGELIST;
 #endif  /* __WINE__ */
 
-#define CLR_NONE      0xFFFFFFFF
-#define CLR_DEFAULT   0x00000000
-#define CLR_HILIGHT   CLR_DEFAULT
+#define CLR_NONE         0xFFFFFFFF
+#define CLR_DEFAULT      0xFF000000
+#define CLR_HILIGHT      CLR_DEFAULT
 
-#define ILC_MASK       0x0001
-#define ILC_COLOR      0x0000
-#define ILC_COLORDDB   0x00FE
-#define ILC_COLOR4     0x0004
-#define ILC_COLOR8     0x0008
-#define ILC_COLOR16    0x0010
-#define ILC_COLOR24    0x0018
-#define ILC_COLOR32    0x0020
-#define ILC_PALETTE    0x0800
+#define ILC_MASK         0x0001
+#define ILC_COLOR        0x0000
+#define ILC_COLORDDB     0x00FE
+#define ILC_COLOR4       0x0004
+#define ILC_COLOR8       0x0008
+#define ILC_COLOR16      0x0010
+#define ILC_COLOR24      0x0018
+#define ILC_COLOR32      0x0020
+#define ILC_PALETTE      0x0800  /* no longer supported by M$ */
 
 #define ILD_NORMAL       0x0000
 #define ILD_TRANSPARENT  0x0001
@@ -146,6 +160,10 @@
 
 #define INDEXTOOVERLAYMASK(i)  ((i)<<8)
 
+#define ILCF_MOVE        (0x00000000)
+#define ILCF_SWAP        (0x00000001)
+
+
 typedef struct _IMAGEINFO
 {
     HBITMAP32 hbmImage;
@@ -156,20 +174,48 @@
 } IMAGEINFO;
 
 
+typedef struct _IMAGELISTDRAWPARAMS
+{ 
+    DWORD       cbSize; 
+    HIMAGELIST  himl; 
+    INT32       i; 
+    HDC32       hdcDst; 
+    INT32       x; 
+    INT32       y; 
+    INT32       cx; 
+    INT32       cy; 
+    INT32       xBitmap;        // x offest from the upperleft of bitmap 
+    INT32       yBitmap;        // y offset from the upperleft of bitmap 
+    COLORREF    rgbBk; 
+    COLORREF    rgbFg; 
+    UINT32      fStyle; 
+    DWORD       dwRop; 
+} IMAGELISTDRAWPARAMS, *LPIMAGELISTDRAWPARAMS; 
+
+ 
 INT32      WINAPI ImageList_Add(HIMAGELIST,HBITMAP32,HBITMAP32);
 INT32      WINAPI ImageList_AddMasked(HIMAGELIST,HBITMAP32,COLORREF);
-
+BOOL32     WINAPI ImageList_BeginDrag(HIMAGELIST,INT32,INT32,INT32);
+BOOL32     WINAPI ImageList_Copy(HIMAGELIST,INT32,HIMAGELIST,INT32,INT32);
 HIMAGELIST WINAPI ImageList_Create(INT32,INT32,UINT32,INT32,INT32);
 BOOL32     WINAPI ImageList_Destroy(HIMAGELIST);
-
+BOOL32     WINAPI ImageList_DragEnter(HWND32,INT32,INT32);
+BOOL32     WINAPI ImageList_DragLeave(HWND32); 
+BOOL32     WINAPI ImageList_DragMove(INT32,INT32);
+BOOL32     WINAPI ImageList_DragShowNolock (BOOL32 bShow);
 BOOL32     WINAPI ImageList_Draw(HIMAGELIST,INT32,HDC32,INT32,INT32,UINT32);
-
+BOOL32     WINAPI ImageList_DrawEx(HIMAGELIST,INT32,HDC32,INT32,INT32,INT32,
+                                   INT32,COLORREF,COLORREF,UINT32);
+BOOL32     WINAPI ImageList_DrawIndirect(IMAGELISTDRAWPARAMS*); 
+HIMAGELIST WINAPI ImageList_Duplicate(HIMAGELIST);
+BOOL32     WINAPI ImageList_EndDrag (VOID);
 COLORREF   WINAPI ImageList_GetBkColor(HIMAGELIST);
-
+HIMAGELIST WINAPI ImageList_GetDragImage(POINT32*,POINT32*);
+HICON32    WINAPI ImageList_GetIcon(HIMAGELIST,INT32,UINT32);
 BOOL32     WINAPI ImageList_GetIconSize(HIMAGELIST,INT32*,INT32*);
 INT32      WINAPI ImageList_GetImageCount(HIMAGELIST);
 BOOL32     WINAPI ImageList_GetImageInfo(HIMAGELIST,INT32,IMAGEINFO*);
-
+BOOL32     WINAPI ImageList_GetImageRect (HIMAGELIST,INT32,LPRECT32);
 HIMAGELIST WINAPI ImageList_LoadImage32A(HINSTANCE32,LPCSTR,INT32,INT32,
                                          COLORREF,UINT32,UINT32);
 HIMAGELIST WINAPI ImageList_LoadImage32W(HINSTANCE32,LPCWSTR,INT32,INT32,
@@ -177,15 +223,21 @@
 #define    ImageList_LoadImage WINELIB_NAME_AW(ImageList_LoadImage)
 HIMAGELIST WINAPI ImageList_Merge(HIMAGELIST,INT32,HIMAGELIST,INT32,INT32,INT32);
 
+BOOL32     WINAPI ImageList_Remove(HIMAGELIST,INT32);
 BOOL32     WINAPI ImageList_Replace(HIMAGELIST,INT32,HBITMAP32,HBITMAP32);
 INT32      WINAPI ImageList_ReplaceIcon(HIMAGELIST,INT32,HICON32);
 
 COLORREF   WINAPI ImageList_SetBkColor(HIMAGELIST,COLORREF);
-
+BOOL32     WINAPI ImageList_SetDragCursorImage(HIMAGELIST,INT32,INT32,INT32);
+BOOL32     WINAPI ImageList_SetIconSize (HIMAGELIST,INT32,INT32);
+BOOL32     WINAPI ImageList_SetImageCount (HIMAGELIST,INT32);
 BOOL32     WINAPI ImageList_SetOverlayImage(HIMAGELIST,INT32,INT32);
 
 #define ImageList_AddIcon(himl,hicon) ImageList_ReplaceIcon(himl,-1,hicon)
+#define ImageList_ExtractIcon(hi,himl,i) ImageList_GetIcon(himl,i,0)
 #define ImageList_LoadBitmap(hi,lpbmp,cx,cGrow,crMask) \
   ImageList_LoadImage(hi,lpbmp,cx,cGrow,crMask,IMAGE_BITMAP,0)
+#define ImageList_RemoveAll(himl) ImageList_Remove(himl,-1)
+
 
 #endif  /* __WINE_COMMCTRL_H */
diff --git a/include/commdlg.h b/include/commdlg.h
index f33a3ad..e5ca4f6 100644
--- a/include/commdlg.h
+++ b/include/commdlg.h
@@ -174,7 +174,8 @@
 
 #pragma pack(1)
 
-typedef struct {
+typedef struct 
+{
 	DWORD			lStructSize;
 	HWND16			hwndOwner;          /* caller's window handle   */
 	HDC16          	        hDC;                /* printer DC/IC or NULL    */
@@ -195,8 +196,27 @@
 	short			nSizeMin WINE_PACKED;   /* minimum pt size allowed & */
 	short			nSizeMax WINE_PACKED;   /* max pt size allowed if    */
 							/* CF_LIMITSIZE is used      */
-	} CHOOSEFONT;
-typedef CHOOSEFONT *LPCHOOSEFONT;
+} CHOOSEFONT, *LPCHOOSEFONT;
+
+typedef struct
+{
+	UINT32  	lStructSize; 
+	HWND32 		hwndOwner; 
+	HDC32  		hDC; 
+	LPLOGFONT32A    lpLogFont; 
+	INT32		iPointSize; 
+	UINT32		Flags; 
+	COLORREF	rgbColors; 
+	LPARAM		lCustData; 
+	WNDPROC32 	lpfnHook; 
+	LPCSTR		lpTemplateName; 
+	HINSTANCE32	hInstance; 
+	LPSTR		lpszStyle; 
+	UINT16		nFontType; 
+	UINT16	___MISSING_ALIGNMENT__; 
+	INT32   	nSizeMin; 
+	INT32		nSizeMax; 
+} CHOOSEFONT32A, *PCHOOSEFONT32A;
 
 #pragma pack(4)
 
diff --git a/include/compobj.h b/include/compobj.h
index d5f833a..6925b1e 100644
--- a/include/compobj.h
+++ b/include/compobj.h
@@ -24,6 +24,10 @@
 
 OLESTATUS WINAPI WINE_StringFromCLSID(const CLSID *id, LPSTR);
 
+OLESTATUS WINAPI StringFromGUID2(const REFGUID *id, LPOLESTR32 *str, INT32 cmax);
+// #define StringFromGUID2 WINELIB_NAME(StringFromGUID2)
+
+
 #ifdef INITGUID
 #define DEFINE_GUID(name, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) \
         const GUID name =\
diff --git a/include/debug.h b/include/debug.h
index cde1891..d601ff4 100644
--- a/include/debug.h
+++ b/include/debug.h
@@ -6,97 +6,112 @@
 
 /* Definitions for channels identifiers */
 #define dbch_accel 0
-#define dbch_aspi 1
-#define dbch_atom 2
-#define dbch_bitblt 3
-#define dbch_bitmap 4
-#define dbch_caret 5
-#define dbch_cdaudio 6
-#define dbch_class 7
-#define dbch_clipboard 8
-#define dbch_clipping 9
-#define dbch_combo 10
-#define dbch_comm 11
-#define dbch_commdlg 12
-#define dbch_console 13
-#define dbch_crtdll 14
-#define dbch_cursor 15
-#define dbch_dc 16
-#define dbch_dde 17
-#define dbch_ddeml 18
-#define dbch_ddraw 19
-#define dbch_dialog 20
-#define dbch_dll 21
-#define dbch_dosfs 22
-#define dbch_driver 23
-#define dbch_dsound 24
-#define dbch_edit 25
-#define dbch_event 26
-#define dbch_exec 27
-#define dbch_file 28
-#define dbch_fixup 29
-#define dbch_font 30
-#define dbch_gdi 31
-#define dbch_global 32
-#define dbch_graphics 33
-#define dbch_heap 34
-#define dbch_hook 35
-#define dbch_icon 36
-#define dbch_int 37
-#define dbch_int21 38
-#define dbch_key 39
-#define dbch_keyboard 40
-#define dbch_ldt 41
-#define dbch_listbox 42
-#define dbch_local 43
-#define dbch_mci 44
-#define dbch_mcianim 45
-#define dbch_mciwave 46
-#define dbch_mdi 47
-#define dbch_menu 48
-#define dbch_message 49
-#define dbch_metafile 50
-#define dbch_midi 51
-#define dbch_mmaux 52
-#define dbch_mmio 53
-#define dbch_mmsys 54
-#define dbch_mmtime 55
-#define dbch_module 56
-#define dbch_msg 57
-#define dbch_nonclient 58
-#define dbch_ole 59
-#define dbch_palette 60
-#define dbch_profile 61
-#define dbch_progress 62
-#define dbch_prop 63
-#define dbch_reg 64
-#define dbch_region 65
-#define dbch_relay 66
-#define dbch_resource 67
-#define dbch_scroll 68
-#define dbch_selector 69
-#define dbch_sem 70
-#define dbch_sendmsg 71
-#define dbch_shm 72
-#define dbch_static 73
-#define dbch_stress 74
-#define dbch_string 75
-#define dbch_task 76
-#define dbch_text 77
-#define dbch_thunk 78
-#define dbch_timer 79
-#define dbch_toolhelp 80
-#define dbch_tweak 81
-#define dbch_uitools 82
-#define dbch_updown 83
-#define dbch_ver 84
-#define dbch_virtual 85
-#define dbch_vxd 86
-#define dbch_win 87
-#define dbch_win16drv 88
-#define dbch_win32 89
-#define dbch_winsock 90
-#define dbch_x11 91
+#define dbch_advapi 1
+#define dbch_aspi 2
+#define dbch_atom 3
+#define dbch_bitblt 4
+#define dbch_bitmap 5
+#define dbch_caret 6
+#define dbch_cd 7
+#define dbch_cdaudio 8
+#define dbch_class 9
+#define dbch_clipboard 10
+#define dbch_clipping 11
+#define dbch_combo 12
+#define dbch_comm 13
+#define dbch_commdlg 14
+#define dbch_console 15
+#define dbch_crtdll 16
+#define dbch_cursor 17
+#define dbch_dc 18
+#define dbch_dde 19
+#define dbch_ddeml 20
+#define dbch_ddraw 21
+#define dbch_debug 22
+#define dbch_dialog 23
+#define dbch_dll 24
+#define dbch_dosfs 25
+#define dbch_driver 26
+#define dbch_dsound 27
+#define dbch_edit 28
+#define dbch_event 29
+#define dbch_exec 30
+#define dbch_file 31
+#define dbch_fixup 32
+#define dbch_font 33
+#define dbch_gdi 34
+#define dbch_global 35
+#define dbch_graphics 36
+#define dbch_heap 37
+#define dbch_hook 38
+#define dbch_icon 39
+#define dbch_imagelist 40
+#define dbch_int 41
+#define dbch_int21 42
+#define dbch_int31 43
+#define dbch_key 44
+#define dbch_keyboard 45
+#define dbch_ldt 46
+#define dbch_listbox 47
+#define dbch_local 48
+#define dbch_mci 49
+#define dbch_mcianim 50
+#define dbch_mciwave 51
+#define dbch_mdi 52
+#define dbch_menu 53
+#define dbch_message 54
+#define dbch_metafile 55
+#define dbch_midi 56
+#define dbch_mmaux 57
+#define dbch_mmio 58
+#define dbch_mmsys 59
+#define dbch_mmtime 60
+#define dbch_module 61
+#define dbch_mpr 62
+#define dbch_msg 63
+#define dbch_nonclient 64
+#define dbch_ntdll 65
+#define dbch_ole 66
+#define dbch_palette 67
+#define dbch_print 68
+#define dbch_profile 69
+#define dbch_progress 70
+#define dbch_prop 71
+#define dbch_reg 72
+#define dbch_region 73
+#define dbch_relay 74
+#define dbch_resource 75
+#define dbch_scroll 76
+#define dbch_security 77
+#define dbch_selector 78
+#define dbch_sem 79
+#define dbch_sendmsg 80
+#define dbch_shell 81
+#define dbch_shm 82
+#define dbch_sound 83
+#define dbch_static 84
+#define dbch_stress 85
+#define dbch_string 86
+#define dbch_task 87
+#define dbch_text 88
+#define dbch_thread 89
+#define dbch_thunk 90
+#define dbch_timer 91
+#define dbch_toolhelp 92
+#define dbch_tweak 93
+#define dbch_uitools 94
+#define dbch_updown 95
+#define dbch_ver 96
+#define dbch_virtual 97
+#define dbch_vxd 98
+#define dbch_win 99
+#define dbch_win16drv 100
+#define dbch_win32 101
+#define dbch_wing 102
+#define dbch_winsock 103
+#define dbch_wnet 104
+#define dbch_x11 105
+#define dbch_x11drv 106
 /* Definitions for classes identifiers */
 #define dbcl_fixme 0
 #define dbcl_err 1
diff --git a/include/debugdefs.h b/include/debugdefs.h
index 93f5096..6189cf5 100644
--- a/include/debugdefs.h
+++ b/include/debugdefs.h
@@ -4,7 +4,7 @@
 #include "debugtools.h"
 #endif
 
-#define DEBUG_CHANNEL_COUNT 92
+#define DEBUG_CHANNEL_COUNT 107
 #ifdef DEBUG_RUNTIME
 short debug_msg_enabled[][DEBUG_CLASS_COUNT] = {
 {1, 1, 0, 0},
@@ -99,14 +99,31 @@
 {1, 1, 0, 0},
 {1, 1, 0, 0},
 {1, 1, 0, 0},
+{1, 1, 0, 0},
+{1, 1, 0, 0},
+{1, 1, 0, 0},
+{1, 1, 0, 0},
+{1, 1, 0, 0},
+{1, 1, 0, 0},
+{1, 1, 0, 0},
+{1, 1, 0, 0},
+{1, 1, 0, 0},
+{1, 1, 0, 0},
+{1, 1, 0, 0},
+{1, 1, 0, 0},
+{1, 1, 0, 0},
+{1, 1, 0, 0},
+{1, 1, 0, 0},
 };
 const char* debug_ch_name[] = {
 "accel",
+"advapi",
 "aspi",
 "atom",
 "bitblt",
 "bitmap",
 "caret",
+"cd",
 "cdaudio",
 "class",
 "clipboard",
@@ -121,6 +138,7 @@
 "dde",
 "ddeml",
 "ddraw",
+"debug",
 "dialog",
 "dll",
 "dosfs",
@@ -138,8 +156,10 @@
 "heap",
 "hook",
 "icon",
+"imagelist",
 "int",
 "int21",
+"int31",
 "key",
 "keyboard",
 "ldt",
@@ -158,10 +178,13 @@
 "mmsys",
 "mmtime",
 "module",
+"mpr",
 "msg",
 "nonclient",
+"ntdll",
 "ole",
 "palette",
+"print",
 "profile",
 "progress",
 "prop",
@@ -170,15 +193,19 @@
 "relay",
 "resource",
 "scroll",
+"security",
 "selector",
 "sem",
 "sendmsg",
+"shell",
 "shm",
+"sound",
 "static",
 "stress",
 "string",
 "task",
 "text",
+"thread",
 "thunk",
 "timer",
 "toolhelp",
@@ -191,8 +218,11 @@
 "win",
 "win16drv",
 "win32",
+"wing",
 "winsock",
+"wnet",
 "x11",
+"x11drv",
 };
 const char* debug_cl_name[] = {
 "fixme",
diff --git a/include/debugtools.h b/include/debugtools.h
index b133809..8dec4ac 100644
--- a/include/debugtools.h
+++ b/include/debugtools.h
@@ -3,10 +3,10 @@
 #define __WINE_DEBUGTOOLS_H
 
 #include <stdio.h>
+#include "debugstr.h"
 
 #define DEBUG_RUNTIME
-#define stddeb  stdout
-#define stdnimp stdout
+#define stddeb  stderr
 
 #define DEBUG_CLASS_COUNT 4
 
@@ -31,8 +31,7 @@
   (dbg_ch_index(ch) >=0 && dbg_cl_index(cl) >= 0 && \
    debug_msg_enabled[dbg_ch_index(ch)][dbg_cl_index(cl)])
 
-#define DPRINTF(format, args...) \
-  fprintf(stddeb, format, ## args)
+#define DPRINTF(format, args...) fprintf(stddeb, format, ## args)
 
 #define DPRINTF_(cl, ch, format, args...) \
   if(!DEBUGGING(cl, ch)) ; \
@@ -43,6 +42,9 @@
 #define FIXME(ch, fmt, args...) DPRINTF_(fixme, ch, fmt, ## args)
 #define ERR(ch, fmt, args...)   DPRINTF_(err, ch, fmt, ## args)
 
+#define DUMP(format, args...)   DPRINTF(format, ## args)
+#define MSG(format, args...)    fprintf(stderr, format, ## args)
+
 #define FIXME_ON(ch)  DEBUGGING(fixme, ch)
 #define ERR_ON(ch)    DEBUGGING(err, ch)
 #define WARN_ON(ch)   DEBUGGING(warn, ch)
diff --git a/include/heap.h b/include/heap.h
index 82f26e2..2ad3098 100644
--- a/include/heap.h
+++ b/include/heap.h
@@ -44,4 +44,26 @@
 /* Use this one only when you own the lock! */
 #define SYSTEM_LOCK_COUNT() (HEAP_SystemLock->RecursionCount)
 
+
+typedef struct
+{
+    LPVOID lpData;
+    DWORD cbData;
+    BYTE cbOverhead;
+    BYTE iRegionIndex;
+    WORD wFlags;
+    union {
+        struct {
+            HANDLE32 hMem;
+            DWORD dwReserved[3];
+        } Block;
+        struct {
+            DWORD dwCommittedSize;
+            DWORD dwUnCommittedSize;
+            LPVOID lpFirstBlock;
+            LPVOID lpLastBlock;
+        } Region;
+    } Foo;
+} PROCESS_HEAP_ENTRY, *LPPROCESS_HEAP_ENTRY;
+
 #endif  /* __WINE_HEAP_H */
diff --git a/include/imagelist.h b/include/imagelist.h
index 891322b..362ce4b 100644
--- a/include/imagelist.h
+++ b/include/imagelist.h
@@ -9,20 +9,24 @@
  
 struct _IMAGELIST
 {
-    HANDLE32  hHeap;
     HBITMAP32 hbmImage;
     HBITMAP32 hbmMask;
+    HBRUSH32  hbrushBlend25;
+    HBRUSH32  hbrushBlend50;
     COLORREF  clrBk;
+    INT32     cInitial;
     INT32     cGrow;
     INT32     cMaxImage;
     INT32     cCurImage;
     INT32     cx;
     INT32     cy;
     UINT32    flags;
-    INT32     nOvlIdx[4];
+    UINT32    uBitsPixel;
+    INT32     nOvlIdx[15];
 };
  
 typedef struct _IMAGELIST *HIMAGELIST;
  
  
 #endif  /* __WINE_IMAGELIST_H */
+
diff --git a/include/metafiledrv.h b/include/metafiledrv.h
index e89d091..b82ac98 100644
--- a/include/metafiledrv.h
+++ b/include/metafiledrv.h
@@ -9,6 +9,7 @@
 #include "gdi.h"
 
 /* FIXME: SDK docs says these should be 1 and 2 */
+/*  DR 980322: most wmf's have 1, so I think 0 and 1 is correct */
 #define METAFILE_MEMORY 0
 #define METAFILE_DISK   1
 
diff --git a/include/mmsystem.h b/include/mmsystem.h
index be29f5f..f293176 100644
--- a/include/mmsystem.h
+++ b/include/mmsystem.h
@@ -481,6 +481,8 @@
 #define MOM_CLOSE       MM_MOM_CLOSE
 #define MOM_DONE        MM_MOM_DONE
 
+/* device ID for MIDI mapper */
+
 #define MIDIMAPPER     (-1)
 #define MIDI_MAPPER    (-1)
 
diff --git a/include/multimedia.h b/include/multimedia.h
new file mode 100644
index 0000000..8c62070
--- /dev/null
+++ b/include/multimedia.h
@@ -0,0 +1,81 @@
+/*****************************************************************************
+ * Copyright 1998, Luiz Otavio L. Zorzella
+ *
+ * File:      multimedia.h
+ * Purpose:   multimedia declarations
+ *
+ *****************************************************************************
+ */
+#ifndef __WINE_MULTIMEDIA_H 
+#define __WINE_MULTIMEDIA_H
+
+#include "mmsystem.h"
+
+#define MAX_MIDIINDRV 	(1)
+/* For now I'm making 16 the maximum number of midi devices one can
+ * have. This should be more than enough for everybody. But as a purist,
+ * I intend to make it unbounded in the future, as soon as I figure
+ * a good way to do so.
+ */
+#define MAX_MIDIOUTDRV 	(16)
+#define MAX_MCIMIDIDRV 	(1)
+
+#if defined (linux)
+#define __HAS_SOUNDCARD_H__
+#include <sys/soundcard.h>
+#elif defined (__FreeBSD__)
+#define __HAS_SOUNDCARD_H__
+#include <machine/soundcard.h>
+#include <sys/errno.h>
+#endif
+
+#if defined (__HAS_SOUNDCARD_H__)
+
+#define MIDI_DEV "/dev/sequencer"
+
+#ifdef SOUND_VERSION
+#define IOCTL(a,b,c)		ioctl(a,b,&c)
+#else
+#define IOCTL(a,b,c)		(c = ioctl(a,b,c) )
+#endif
+
+typedef struct {
+	int		unixdev;
+	int		state;
+	DWORD		bufsize;
+	MIDIOPENDESC	midiDesc;
+	WORD		wFlags;
+	LPMIDIHDR 	lpQueueHdr;
+	DWORD		dwTotalPlayed;
+} LINUX_MIDIIN;
+
+typedef struct {
+	int		unixdev;
+	int		state;
+	DWORD		bufsize;
+	MIDIOPENDESC	midiDesc;
+	WORD		wFlags;
+	LPMIDIHDR 	lpQueueHdr;
+	DWORD		dwTotalPlayed;
+} LINUX_MIDIOUT;
+
+typedef struct {
+	int	nUseCount;          /* Incremented for each shared open */
+	BOOL16	fShareable;         /* TRUE if first open was shareable */
+	WORD	wNotifyDeviceID;    /* MCI device ID with a pending notification */
+	HANDLE16 hCallback;         /* Callback handle for pending notification */
+	HMMIO16	hFile;	            /* mmio file handle open as Element		*/
+	DWORD	dwBeginData;
+	DWORD	dwTotalLen;
+	WORD	wFormat;
+	WORD	nTracks;
+	WORD	nTempo;
+	MCI_OPEN_PARMS16 openParms;
+/* 	MIDIHDR	MidiHdr; */
+	HLOCAL16	hMidiHdr;
+	WORD	dwStatus;
+} LINUX_MCIMIDI;
+
+#endif
+
+#endif /* __WINE_MULTIMEDIA_H */
diff --git a/include/neexe.h b/include/neexe.h
index c5c263f..ff83390 100644
--- a/include/neexe.h
+++ b/include/neexe.h
@@ -31,9 +31,7 @@
     WORD  e_oemid;      /* 24: OEM identifier (for e_oeminfo) */
     WORD  e_oeminfo;    /* 26: OEM information; e_oemid specific */
     WORD  e_res2[10];   /* 28: Reserved words */
-    WORD  e_lfanew;     /* 3c: Offset to extended header */
-    WORD  e_xxx;        /* 3e: Wine internal pad (some programs expect
-                         *     this to be 0) */
+    DWORD e_lfanew;     /* 3c: Offset to extended header */
 } IMAGE_DOS_HEADER,*LPIMAGE_DOS_HEADER;
 
 #define	IMAGE_DOS_SIGNATURE	0x5A4D		/* MZ */
diff --git a/include/peexe.h b/include/peexe.h
index 78adf3b..848ed94 100644
--- a/include/peexe.h
+++ b/include/peexe.h
@@ -59,41 +59,42 @@
 	 * Standard fields.
 	 */
 
-	WORD	Magic;
-	BYTE	MajorLinkerVersion;
-	BYTE	MinorLinkerVersion;
-	DWORD	SizeOfCode;
-	DWORD	SizeOfInitializedData;
-	DWORD	SizeOfUninitializedData;
-	DWORD	AddressOfEntryPoint;
-	DWORD	BaseOfCode;
-	DWORD	BaseOfData;
+	WORD	Magic;				/* 00 */
+	BYTE	MajorLinkerVersion;		/* 02 */
+	BYTE	MinorLinkerVersion;		/* 03 */
+	DWORD	SizeOfCode;			/* 04 */
+	DWORD	SizeOfInitializedData;		/* 08 */
+	DWORD	SizeOfUninitializedData;	/* 0C */
+	DWORD	AddressOfEntryPoint;		/* 10 */
+	DWORD	BaseOfCode;			/* 14 */
+	DWORD	BaseOfData;			/* 18 */
 
 	/*
 	 * NT additional fields.
 	 */
 
-	DWORD	ImageBase;
-	DWORD	SectionAlignment;
-	DWORD	FileAlignment;
-	WORD	MajorOperatingSystemVersion;
-	WORD	MinorOperatingSystemVersion;
-	WORD	MajorImageVersion;
-	WORD	MinorImageVersion;
-	WORD	MajorSubsystemVersion;
-	WORD	MinorSubsystemVersion;
-	DWORD	Reserved1;
-	DWORD	SizeOfImage;
-	DWORD	SizeOfHeaders;
-	DWORD	CheckSum;
-	WORD	Subsystem;
-	WORD	DllCharacteristics;
-	DWORD	SizeOfStackReserve;
-	DWORD	SizeOfStackCommit;
-	DWORD	SizeOfHeapReserve;
-	DWORD	SizeOfHeapCommit;
-	DWORD	LoaderFlags;
-	DWORD	NumberOfRvaAndSizes;
+	DWORD	ImageBase;			/* 1C */
+	DWORD	SectionAlignment;		/* 20 */
+	DWORD	FileAlignment;			/* 24 */
+	WORD	MajorOperatingSystemVersion;	/* 28 */
+	WORD	MinorOperatingSystemVersion;	/* 2A */
+	WORD	MajorImageVersion;		/* 2C */
+	WORD	MinorImageVersion;		/* 2E */
+	WORD	MajorSubsystemVersion;		/* 30 */
+	WORD	MinorSubsystemVersion;		/* 32 */
+	DWORD	Reserved1;			/* 34 */
+	DWORD	SizeOfImage;			/* 38 */
+	DWORD	SizeOfHeaders;			/* 3C */
+	DWORD	CheckSum;			/* 40 */
+	WORD	Subsystem;			/* 44 */
+	WORD	DllCharacteristics;		/* 46 */
+	DWORD	SizeOfStackReserve;		/* 48 */
+	DWORD	SizeOfStackCommit;		/* 4C */
+	DWORD	SizeOfHeapReserve;		/* 50 */
+	DWORD	SizeOfHeapCommit;		/* 54 */
+	DWORD	LoaderFlags;			/* 58 */
+	DWORD	NumberOfRvaAndSizes;		/* 5C */
+						/* 60: */
 	IMAGE_DATA_DIRECTORY DataDirectory[IMAGE_NUMBEROF_DIRECTORY_ENTRIES];
 } IMAGE_OPTIONAL_HEADER,*LPIMAGE_OPTIONAL_HEADER;
 
@@ -140,9 +141,9 @@
 #define	IMAGE_SUBSYSTEM_POSIX_CUI	7
 
 typedef struct _IMAGE_NT_HEADERS {
-	DWORD			Signature;
-	IMAGE_FILE_HEADER	FileHeader;
-	IMAGE_OPTIONAL_HEADER	OptionalHeader;
+	DWORD			Signature;	/* 00: PE\0\0 */
+	IMAGE_FILE_HEADER	FileHeader;	/* 04: Fileheader */
+	IMAGE_OPTIONAL_HEADER	OptionalHeader;	/* 18: Optional Header */
 } IMAGE_NT_HEADERS,*LPIMAGE_NT_HEADERS;
 
 
@@ -161,19 +162,20 @@
 #define	IMAGE_SIZEOF_SHORT_NAME	8
 
 typedef struct _IMAGE_SECTION_HEADER {
-	BYTE	Name[IMAGE_SIZEOF_SHORT_NAME];
+	BYTE	Name[IMAGE_SIZEOF_SHORT_NAME];	/* 00: */
 	union {
-		DWORD	PhysicalAddress;
-		DWORD	VirtualSize;
+		DWORD	PhysicalAddress;	/* 04: */
+		DWORD	VirtualSize;		/* 04: */
 	} Misc;
-	DWORD	VirtualAddress;
-	DWORD	SizeOfRawData;
-	DWORD	PointerToRawData;
-	DWORD	PointerToRelocations;
-	DWORD	PointerToLinenumbers;
-	WORD	NumberOfRelocations;
-	WORD	NumberOfLinenumbers;
-	DWORD	Characteristics;
+	DWORD	VirtualAddress;			/* 08: */
+	DWORD	SizeOfRawData;			/* 0C: */
+	DWORD	PointerToRawData;		/* 10: */
+	DWORD	PointerToRelocations;		/* 14: */
+	DWORD	PointerToLinenumbers;		/* 18: */
+	WORD	NumberOfRelocations;		/* 1C: */
+	WORD	NumberOfLinenumbers;		/* 1E: */
+	DWORD	Characteristics;		/* 20: */
+						/* 24: */
 } IMAGE_SECTION_HEADER,*LPIMAGE_SECTION_HEADER;
 
 #define	IMAGE_SIZEOF_SECTION_HEADER 40
diff --git a/include/version.h b/include/version.h
index 8f5202a..4fcacf6 100644
--- a/include/version.h
+++ b/include/version.h
@@ -1 +1 @@
-#define WINE_RELEASE_INFO "Wine release 980315"
+#define WINE_RELEASE_INFO "Wine release 980329"
diff --git a/include/windows.h b/include/windows.h
index 5944f83..21bf27d 100644
--- a/include/windows.h
+++ b/include/windows.h
@@ -817,6 +817,8 @@
 #define IDIGNORE            5
 #define IDYES               6
 #define IDNO                7
+#define IDCLOSE             8
+#define IDHELP              9      
 
 
 typedef struct
@@ -2495,6 +2497,9 @@
 #define IDC_SIZENESW     MAKEINTRESOURCE(32643)
 #define IDC_SIZEWE       MAKEINTRESOURCE(32644)
 #define IDC_SIZENS       MAKEINTRESOURCE(32645)
+#define IDC_NO           MAKEINTRESOURCE(32648)
+#define IDC_APPSTARTING  MAKEINTRESOURCE(32650)
+#define IDC_HELP         MAKEINTRESOURCE(32651)
 
 /* OEM Resource Ordinal Numbers */
 #define OBM_CLOSE           32754
@@ -2559,6 +2564,9 @@
 #define OCR_SIZENS          32645
 #define OCR_SIZEALL         32646
 #define OCR_ICOCUR          32647
+#define OCR_NO              32648
+#define OCR_APPSTARTING     32650
+#define OCR_HELP            32651  /* only defined in wine */
 
 #define OIC_SAMPLE          32512
 #define OIC_HAND            32513
diff --git a/include/winsock.h b/include/winsock.h
index 63a1878..f8bf7ef 100644
--- a/include/winsock.h
+++ b/include/winsock.h
@@ -518,7 +518,9 @@
 #define WSMSG_ASYNC_PROTOBYNUM  0x0020
 #define WSMSG_ASYNC_SERVBYNAME  0x0100
 #define WSMSG_ASYNC_SERVBYPORT  0x0200
-#define WSMSG_ASYNC_WIN32	0x1000
+#define WSMSG_ASYNC_RQMASK	0x0fff
+
+#define WSMSG_WIN32_AOP		0x1000
 #define WSMSG_DEAD_AOP		0x8000
 
 typedef struct __sop	/* WSAAsyncSelect() control struct */