Release 980315

Sun Mar 15 03:46:50 1998  Dimitrie O. Paun  <dimi@mail.cs.toronto.edu>

	* [*/*]
	Fixed some dprintf_ such that there is one and only one
	new line for each dprintf and that new line occurs at the end.
	Transformed some fprintfs into proper debug statements.
	Removed much redundancy from most of the debug statements. The
	redundancy appeared because now the component and function
	name is output automatically. Most debug statements also used to
	output the name of the function.
	All these changes prepared the source to switch completely to
	the new debugging interface.
	For more info, refer to ./documentation/debug-msg

Sat Mar 14 19:45:23 1997  Andreas Mohr <100.30936@germany.net>

	* [misc/shell.c] [if1632/kernel.spec]
	Changed parameters of FUNC004() to fix a crash.
	Not sure if this fix is correct (doc wanted).

	* [windows/user.c] [if1632/user.spec] [include/user.h]
	Implemented UserSeeUserDo.

	* [msdos/int21.c] [include/msdos.h]
	Added "GET LIST OF LISTS" (INT 21/52h).

Sat Mar 14 15:48:02 1998  Douglas Ridgway <ridgway@gmcl.com>

	* [include/windows.h] [relay32/gdi32.spec] [objects/enhmetafile.c]
	Beginnings of enhanced metafile support.

Fri Mar 13 20:53:09 1998  John Richardson <jrichard@zko.dec.com>

	* [win32/console.c]
	Restart interrupted console writes.

Fri Mar 13 18:59:24 1998  Matthew Becker <mbecker@glasscity.net>

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

	* [windows/dce.c]
	ReleaseDC16: Fixed cast.

	* [include/windows.h] [memory/virtual.c]
	VirtualQuery{Ex} should return DWORD instead of BOOL32.

Fri Mar 13 13:03:06 1998  Marcus Meissner <msmeissn@cip.informatik.uni-erlangen.de>

	* [README][documentation/status/]
	README updated, added lzexpand,version and multimedia
	status notes to new documentation/status directory.

	* [ole/*.c][if1632/typelib.spec]
	Added typelib stubs, several small additions and fixes.

	* [loader/pe_image.c]
	Fixed a small bug (fixup_imports got passed the wrong hModule in a
	remapcase).

	* [loader/signal.c][if1632/signal.c][misc/winsock_dns.c]
	  [loader/module.c]
	Fixed some recursive debugger crashes (caused by invalid FS).

	* [misc/registry.c]
	Two bugs fixed.

Fri Mar 13 04:55:01 1998  David Lee Lambert <lamber45@egr.msu.edu>

	* [include/winnt.h] [include/winnls.h]
	Moved LANG_xxx flags to winnls.h

	* [include/winnls.h]
	Added flags for GetDateFormat(); fixed validity of
	LOCALE_SYSTEM_DEFAULT.

	* [include/windows.h] 
	Added GetTimeFormat() prototypes.

	* [ole/ole2nls.c]
	Implemented ASCII date- and time-functions,  using an
	optimized common core;  added stubs for Unicode versions;  
	started work on a Unicode core.

	* [AUTHORS]
	Added my name.

Mon Mar  9 20:10:15 1998  Eric Kohl <ekohl@abo.rhein-zeitung.de>

	* [relay32/comctl32.spec] [include/imagelist.h]
	  [include/commctrl.h] [misc/imagelist.c] [misc/Makefile.in]
	First attempt at implementing ImageLists.

Sun Mar  8 20:19:49 1998  Uwe Bonnes  <bon@elektron.ikp.physik.tu-darmstadt.de>

	* [files/dos_fs.c] [configure.in]
	Try to get FileTimeToLocalFileTime,FileTimeToSystemTime and
	SystemTimeToFileTime right.
	Use timegm() where available.

	* [misc/lstr.c]
	Fix an off by one error in FormatMessage and handle the case 
	when args = NULL (used by programs to get the length of the 
	string).

	* [win32/console.c]
	Actual display a per-process Title string, better working
	attempt for WriteConsole32W and ReadConsole32W.

Fri Mar  6 20:33:45 1998  Slaven Rezic  <eserte@cs.tu-berlin.de>

	* [include/config.h.in][configure.in][multimedia/audio.c]
	  [multimedia/dsound.c]
	Added check for FreeBSD sound system.

Sun Mar  1 17:40:10 1998  Jason Schonberg <schon@mti.sgi.com>

	* [controls/edit.c] [include/ole.h] [include/shlobj.h]
	Removed final commas in enum types.

Mon Feb 23 07:52:18 1998  Luiz Otavio L. Zorzella  <zorzella@nr.conexware.com>

	* [multimedia/time.c]
	Workaround to avoid infinite recursion inside timeGetTime.

	* [multimedia/audio.c]
	WODM_GETNUMDEVS and WIDM_GETNUMDEVS only return 1 now if the
	SOUND_DEV can be opened, or if it's busy.
diff --git a/objects/cursoricon.c b/objects/cursoricon.c
index db23574..f1bb32b 100644
--- a/objects/cursoricon.c
+++ b/objects/cursoricon.c
@@ -289,7 +289,7 @@
     BITMAPINFO *bmi;
     HDC32 hdc;
 
-    dprintf_info(cursor,"CreateFromResource: %08x (%u bytes), ver %08x, %ix%i %s %s\n",
+    TRACE(cursor,"%08x (%u bytes), ver %08x, %ix%i %s %s\n",
                         (unsigned)bits, cbSize, (unsigned)dwVersion, width, height,
                                   bIcon ? "icon" : "cursor", cFlag ? "mono" : "" );
     if (dwVersion == 0x00020000)
@@ -440,22 +440,21 @@
 }
 
 
- /**********************************************************************
- *          CreateIconFromResource          (USER32)
+/**********************************************************************
+ *          CreateIconFromResource          (USER32.???)
+ * FIXME:
+ *  	bon@elektron.ikp.physik.tu-darmstadt.de 971130: Test with weditres
+ *	showed only blank layout. Couldn't determine if this is a problem
+ *	with CreateIconFromResource32 or the application. The application
+ *	windows behaves strange (no redraw) before CreateIconFromResource32
  */
 HICON32 WINAPI CreateIconFromResource32( LPBYTE bits, UINT32 cbSize,
                                            BOOL32 bIcon, DWORD dwVersion)
-/*FIXME: bon@elektron.ikp.physik.tu-darmstadt.de 971130: Test with weditres
-	 showed only blank layout. Couldn't determine if this is a problem
-	 with CreateIconFromResource32 or the application. The application
-	 windows behaves strange (no redraw) before  CreateIconFromResource32
-*/
 {
     HICON32 ret;
     ret = CreateIconFromResourceEx16( bits, cbSize, bIcon, dwVersion, 0,0,0);
-    fprintf(stdnimp,"CreateIconFromResource3 probably only a stub\n");
-    dprintf_info(icon, 
-	"CreateIconFromResource32 %s at %p size %d winver %d return 0x%04x\n",
+    FIXME(icon,"probably only a stub\n");
+    TRACE(icon, "%s at %p size %d winver %d return 0x%04x\n",
                  (bIcon)?"Icon":"Cursor",bits,cbSize,bIcon,ret);
     return ret;
 }
@@ -637,7 +636,7 @@
            COLORREF       col;
            CURSORICONINFO cI;
 
-	   dprintf_info(icon, "IconToCursor:[%04x] %ix%i %ibpp (bogus %ibps)\n", 
+	   TRACE(icon, "[%04x] %ix%i %ibpp (bogus %ibps)\n", 
 		hIcon, pIcon->nWidth, pIcon->nHeight, pIcon->bBitsPerPixel, pIcon->nWidthBytes );
 
 	   xor_width = BITMAP_GetBitsWidth( pIcon->nWidth, bpp );
@@ -704,10 +703,10 @@
 HCURSOR16 WINAPI LoadCursor16( HINSTANCE16 hInstance, SEGPTR name )
 {
     if (HIWORD(name))
-        dprintf_info(cursor, "LoadCursor16: %04x '%s'\n",
+        TRACE(cursor, "%04x '%s'\n",
                         hInstance, (char *)PTR_SEG_TO_LIN( name ) );
     else
-        dprintf_info(cursor, "LoadCursor16: %04x %04x\n",
+        TRACE(cursor, "%04x %04x\n",
                         hInstance, LOWORD(name) );
 
     return CURSORICON_Load16( hInstance, name,
@@ -721,10 +720,10 @@
 HICON16 WINAPI LoadIcon16( HINSTANCE16 hInstance, SEGPTR name )
 {
     if (HIWORD(name))
-        dprintf_info(icon, "LoadIcon: %04x '%s'\n",
+        TRACE(icon, "%04x '%s'\n",
                       hInstance, (char *)PTR_SEG_TO_LIN( name ) );
     else
-        dprintf_info(icon, "LoadIcon: %04x %04x\n",
+        TRACE(icon, "%04x %04x\n",
                       hInstance, LOWORD(name) );
 
     return CURSORICON_Load16( hInstance, name,
@@ -743,7 +742,7 @@
 {
     CURSORICONINFO info = { { xHotSpot, yHotSpot }, nWidth, nHeight, 0, 1, 1 };
 
-    dprintf_info(cursor, "CreateCursor: %dx%d spot=%d,%d xor=%p and=%p\n",
+    TRACE(cursor, "%dx%d spot=%d,%d xor=%p and=%p\n",
                     nWidth, nHeight, xHotSpot, yHotSpot, lpXORbits, lpANDbits);
     return CreateCursorIconIndirect( hInstance, &info, lpANDbits, lpXORbits );
 }
@@ -759,7 +758,7 @@
 {
     CURSORICONINFO info = { { xHotSpot, yHotSpot }, nWidth, nHeight, 0, 1, 1 };
 
-    dprintf_info(cursor, "CreateCursor: %dx%d spot=%d,%d xor=%p and=%p\n",
+    TRACE(cursor, "%dx%d spot=%d,%d xor=%p and=%p\n",
                     nWidth, nHeight, xHotSpot, yHotSpot, lpXORbits, lpANDbits);
     return CreateCursorIconIndirect( MODULE_HANDLEtoHMODULE16( hInstance ),
                                      &info, lpANDbits, lpXORbits );
@@ -775,7 +774,7 @@
 {
     CURSORICONINFO info = { { 0, 0 }, nWidth, nHeight, 0, bPlanes, bBitsPixel};
 
-    dprintf_info(icon, "CreateIcon: %dx%dx%d, xor=%p, and=%p\n",
+    TRACE(icon, "%dx%dx%d, xor=%p, and=%p\n",
                   nWidth, nHeight, bPlanes * bBitsPixel, lpXORbits, lpANDbits);
     return CreateCursorIconIndirect( hInstance, &info, lpANDbits, lpXORbits );
 }
@@ -790,7 +789,7 @@
 {
     CURSORICONINFO info = { { 0, 0 }, nWidth, nHeight, 0, bPlanes, bBitsPixel};
 
-    dprintf_info(icon, "CreateIcon: %dx%dx%d, xor=%p, and=%p\n",
+    TRACE(icon, "%dx%dx%d, xor=%p, and=%p\n",
                   nWidth, nHeight, bPlanes * bBitsPixel, lpXORbits, lpANDbits);
     return CreateCursorIconIndirect( MODULE_HANDLEtoHMODULE16( hInstance ),
                                      &info, lpANDbits, lpXORbits );
@@ -831,7 +830,7 @@
  */
 HICON16 WINAPI CopyIcon16( HINSTANCE16 hInstance, HICON16 hIcon )
 {
-    dprintf_info(icon, "CopyIcon16: %04x %04x\n", hInstance, hIcon );
+    TRACE(icon, "%04x %04x\n", hInstance, hIcon );
     return CURSORICON_Copy( hInstance, hIcon );
 }
 
@@ -843,7 +842,7 @@
 {
   HTASK16 hTask = GetCurrentTask ();
   TDB* pTask = (TDB *) GlobalLock16 (hTask);
-    dprintf_info(icon, "CopyIcon32: %04x\n", hIcon );
+    TRACE(icon, "%04x\n", hIcon );
   return CURSORICON_Copy( pTask->hInstance, hIcon );
 }
 
@@ -853,7 +852,7 @@
  */
 HCURSOR16 WINAPI CopyCursor16( HINSTANCE16 hInstance, HCURSOR16 hCursor )
 {
-    dprintf_info(cursor, "CopyCursor16: %04x %04x\n", hInstance, hCursor );
+    TRACE(cursor, "%04x %04x\n", hInstance, hCursor );
     return CURSORICON_Copy( hInstance, hCursor );
 }
 
@@ -872,7 +871,7 @@
  */
 BOOL32 WINAPI DestroyIcon32( HICON32 hIcon )
 {
-    dprintf_info(icon, "DestroyIcon: %04x\n", hIcon );
+    TRACE(icon, "%04x\n", hIcon );
     /* FIXME: should check for OEM icon here */
     return (FreeResource16( hIcon ) == 0);
 }
@@ -892,7 +891,7 @@
  */
 BOOL32 WINAPI DestroyCursor32( HCURSOR32 hCursor )
 {
-    dprintf_info(cursor, "DestroyCursor: %04x\n", hCursor );
+    TRACE(cursor, "%04x\n", hCursor );
     /* FIXME: should check for OEM cursor here */
     return (FreeResource16( hCursor ) == 0);
 }
@@ -1119,13 +1118,16 @@
 
 /***********************************************************************
  *           SetCursor32    (USER32.471)
+ * RETURNS:
+ *	A handle to the previous cursor shape.
  */
-HCURSOR32 WINAPI SetCursor32( HCURSOR32 hCursor )
-{
+HCURSOR32 WINAPI SetCursor32(
+	         HCURSOR32 hCursor /* Handle of cursor to show */
+) {
     HCURSOR32 hOldCursor;
 
     if (hCursor == hActiveCursor) return hActiveCursor;  /* No change */
-    dprintf_info(cursor, "SetCursor: %04x\n", hCursor );
+    TRACE(cursor, "%04x\n", hCursor );
     hOldCursor = hActiveCursor;
     hActiveCursor = hCursor;
     /* Change the cursor shape only if it is visible */
@@ -1153,7 +1155,7 @@
  */
 BOOL32 WINAPI SetCursorPos32( INT32 x, INT32 y )
 {
-    dprintf_info(cursor, "SetCursorPos: x=%d y=%d\n", x, y );
+    TRACE(cursor, "x=%d y=%d\n", x, y );
     TSXWarpPointer( display, rootWindow, rootWindow, 0, 0, 0, 0, x, y );
     return TRUE;
 }
@@ -1173,7 +1175,7 @@
  */
 INT32 WINAPI ShowCursor32( BOOL32 bShow )
 {
-    dprintf_info(cursor, "ShowCursor: %d, count=%d\n",
+    TRACE(cursor, "%d, count=%d\n",
                     bShow, CURSOR_ShowCount );
 
     EnterCriticalSection( &X11DRV_CritSection );
@@ -1262,7 +1264,7 @@
         else
             MouseButtonsStates[2] = FALSE;
     }
-    dprintf_info(cursor, "GetCursorPos: ret=%d,%d\n", pt->x, pt->y );
+    TRACE(cursor, "ret=%d,%d\n", pt->x, pt->y );
 }
 
 
@@ -1320,7 +1322,7 @@
 	    if( entry ) retVal = entry->wResId;
 	}
     }
-    else dprintf_warn(cursor, "IconId: invalid resource directory\n");
+    else WARN(cursor, "invalid resource directory\n");
     return retVal;
 }
 
@@ -1360,7 +1362,7 @@
 {
     LPBYTE lpDir = (LPBYTE)GlobalLock16(hResource);
 
-    dprintf_info(cursor, "GetIconID: hRes=%04x, entries=%i\n",
+    TRACE(cursor, "hRes=%04x, entries=%i\n",
                     hResource, lpDir ? ((CURSORICONDIR*)lpDir)->idCount : 0);
 
     switch(resType)
@@ -1438,7 +1440,7 @@
 {
     LPBYTE bits = (LPBYTE)LockResource16( hResource );
 
-    dprintf_info(cursor,"LoadIconHandler: hRes=%04x\n",hResource);
+    TRACE(cursor,"hRes=%04x\n",hResource);
 
     return CURSORICON_CreateFromResource( 0, 0, bits, 0, TRUE, 
 		      bNew ? 0x00030000 : 0x00020000, 0, 0, LR_DEFAULTCOLOR );
@@ -1576,7 +1578,7 @@
     HDC32 hMemDC = CreateCompatibleDC32 (hdc);
     BOOL32 result = FALSE;
 
-    dprintf_fixme(icon, "DrawIconEx32: part stub.\n");
+    FIXME(icon, "part stub.\n");
 
     if (hMemDC && ptr)
     {