Release 961117

Sun Nov 17 15:01:45 1996  Alexandre Julliard  <julliard@lrc.epfl.ch>

	* [graphics/bitblt.c] [graphics/x11drv/bitblt.c]
	Moved BitBlt operations to the new graphics driver
	interface. Implemented PatBlt32, BitBlt32 and StretchBlt32.

	* [memory/global.c]
	Unified MemManInfo() and GlobalMemoryStatus().

	* [objects/text.c]
	Fixed ExtTextOut() to always use physical coords for clip rect.

	* [windows/dialog.c]
	Implemented DlgDirSelectEx() and Win32 version of DlgDirSelect*.

	* [windows/event.c]
	Avoid busy-looping in EVENT_WaitXEvent when no timer is pending
	(thanks to Thomas Koenig).

	* [windows/painting.c]
	Moved update region clipping for CS_PARENTDC windows to BeginPaint().
	
	* [windows/scroll.c]
	Implemented Win32 version of ScrollWindow() and ScrollDC().

Tue Nov 12 09:52:17 1996  Marcus Meissner <msmeissn@cip.informatik.uni-erlangen.de>

	* [files/*.c] [win32/file.c]
	Some win32 filetime conversion functions added.
	Fixed behaviour with DOS drives pointing to UNIX /
	SetCurrentDirectory() may also get X:\xxx paths.
	Fixed FILE_Open when called from CreateFile().
	Added GetFileSize(), MapViewOfFile(), SetFileTime(), GetFileTime().

	* [misc/crtdll.c] [if1632/crtdll.spec]
	Added some new functions.

	* [if1632/user32.spec]
	Some thunks into win16 code added.

	* [win32/init.c]
	Added GetSystemInfo(), removed GetModuleFileName() stub.

	* [win32/code_page.c] [if1632/thunk.c]
	Added EnumSystemCodePages* (untested).

	* [objects/font.c] [if1632/thunk.c]
	Added EnumFontFamilies32*.
	
Mon Nov 11 14:50:24 1996  Huw D. M. Davies <h.davies1@physics.oxford.ac.uk>

	* [controls/menu.c] [windows/mdi.c]
	Don't delete the MDI `windows' menu if it's already been deleted.

	* [misc/exec.c]
	Notepad always calls WinHelp(.., HELP_QUIT, ...) at termination
 	and complains if it returns FALSE.

	* [windows/winpos.c]
	Get maximized MDI child's nonclient area redrawn after resize.

Thu Nov  7 13:32:34 1996  Lee Jaekil <juria@seodu.co.kr>

	* [memory/global.c]
	Use /proc filesystem for GlobalMemoryStatus() on Linux.

Mon Nov  4 18:30:00 1996  Alex Korobka <alex@trantor.pharm.sunysb.edu>

	* [windows/event.c]
	Added OffiX-style file drop handling. File paths must be
	DOS-mappable by Wine (via wine.conf).

	* [controls/combo.c]
        Added WM_GETTEXT handler.

	* [objects/palette.c]
	Added ResizePalette() (untested).

	* [objects/cursoricon.c]
	Implemented icon to cursor conversion.

	* [objects/color.c]
	Fixed crash on startup when no colorcells are writeable.

Mon Nov  4 00:49:41 1996  Ulrich Schmid  <uschmid@mail.hh.provi.de>

	* [rc/winerc.c]
	Added support for win32 output.

	* [library/libres.c] [include/libres.h] [loader/resource.c]
	Renamed LIBRES_FindResource to LIBRES_FindResource16.
	Added LIBRES_FindResource32.

Sun Nov 3 21:21:45 1996  Robert Pouliot <krynos@clic.net>

	* [loader/builtin.c] [if1632/Makefile.in] [if1632/wing.spec]
	Added the spec file for WinG, it's only stub for now, but it
	should be easy to do by someone with Windows programming
	knowledge. See: ftp.microsoft.com/SoftLib/MSLFILES/wing10.exe.

	* [if1632/crtdll.spec]
	Added some string and memory functions to make sfxed95.exe (of
 	Warcraft 2) almost work.
diff --git a/windows/win.c b/windows/win.c
index 0221627..f9b70ee 100644
--- a/windows/win.c
+++ b/windows/win.c
@@ -43,7 +43,7 @@
 static WORD wDragWidth = 4;
 static WORD wDragHeight= 3;
 
-extern HCURSOR16 CURSORICON_IconToCursor(HICON16);
+extern HCURSOR16 CURSORICON_IconToCursor(HICON16, BOOL32);
 extern HWND32 CARET_GetHwnd(void);
 extern BOOL32 WINPOS_ActivateOtherWindow(WND* pWnd);
 extern void   WINPOS_CheckActive(HWND32);
@@ -311,6 +311,8 @@
     HWND hwnd = wndPtr->hwndSelf;
     WND* pWnd,*pNext;
 
+    dprintf_win( stddeb, "WIN_DestroyWindow: %04x\n", wndPtr->hwndSelf );
+
 #ifdef CONFIG_IPC
     if (main_block)
 	DDE_DestroyWindow(wndPtr->hwndSelf);
@@ -659,7 +661,6 @@
     if (!(cs->style & WS_CHILD) && (rootWindow == DefaultRootWindow(display)))
     {
         XSetWindowAttributes win_attr;
-        Atom XA_WM_DELETE_WINDOW;
 
 	if (Options.managed && ((cs->style & (WS_DLGFRAME | WS_THICKFRAME)) ||
             (cs->dwExStyle & WS_EX_DLGMODALFRAME)))
@@ -689,9 +690,6 @@
                                         CWEventMask | CWOverrideRedirect |
                                         CWColormap | CWCursor | CWSaveUnder |
                                         CWBackingStore, &win_attr );
-	XA_WM_DELETE_WINDOW = XInternAtom( display, "WM_DELETE_WINDOW",
-					   False );
-	XSetWMProtocols( display, wndPtr->window, &XA_WM_DELETE_WINDOW, 1 );
 
         if ((wndPtr->flags & WIN_MANAGED) &&
             (cs->dwExStyle & WS_EX_DLGMODALFRAME))
@@ -2069,13 +2067,13 @@
  * recursively find a child that contains spDragInfo->pt point 
  * and send WM_QUERYDROPOBJECT
  */
-BOOL DRAG_QueryUpdate( HWND hQueryWnd, SEGPTR spDragInfo )
+BOOL16 DRAG_QueryUpdate( HWND hQueryWnd, SEGPTR spDragInfo, BOOL32 bNoSend )
 {
- BOOL		wParam,bResult = 0;
+ BOOL16		wParam,bResult = 0;
  POINT16        pt;
  LPDRAGINFO	ptrDragInfo = (LPDRAGINFO) PTR_SEG_TO_LIN(spDragInfo);
  WND 	       *ptrQueryWnd = WIN_FindWndPtr(hQueryWnd),*ptrWnd;
- RECT16		tempRect;	/* this sucks */
+ RECT16		tempRect;
 
  if( !ptrQueryWnd || !ptrDragInfo ) return 0;
 
@@ -2112,7 +2110,7 @@
                         ptrWnd->hwndSelf, ptrWnd->rectWindow.left, ptrWnd->rectWindow.top,
 			ptrWnd->rectWindow.right, ptrWnd->rectWindow.bottom );
             if( !(ptrWnd->dwStyle & WS_DISABLED) )
-	        bResult = DRAG_QueryUpdate(ptrWnd->hwndSelf, spDragInfo);
+	        bResult = DRAG_QueryUpdate(ptrWnd->hwndSelf, spDragInfo, bNoSend);
          }
 
 	 if(bResult) return bResult;
@@ -2125,7 +2123,9 @@
 
  ptrDragInfo->hScope = hQueryWnd;
 
- bResult = SendMessage16( hQueryWnd ,WM_QUERYDROPOBJECT ,
+ bResult = ( bNoSend ) 
+	   ? ptrQueryWnd->dwExStyle & WS_EX_ACCEPTFILES
+	   : SendMessage16( hQueryWnd ,WM_QUERYDROPOBJECT ,
                           (WPARAM16)wParam ,(LPARAM) spDragInfo );
  if( !bResult ) 
       ptrDragInfo->pt = pt;
@@ -2191,7 +2191,7 @@
  short	 	dragDone = 0;
  HCURSOR16	hCurrentCursor = 0;
  HWND		hCurrentWnd = 0;
- WORD	        btemp;
+ BOOL16		b;
 
  lpDragInfo = (LPDRAGINFO) GlobalLock16(hDragInfo);
  spDragInfo = (SEGPTR) WIN16_GlobalLock16(hDragInfo);
@@ -2208,7 +2208,7 @@
 
  if(hCursor)
    {
-	if( !(hDragCursor = CURSORICON_IconToCursor(hCursor)) )
+	if( !(hDragCursor = CURSORICON_IconToCursor(hCursor, FALSE)) )
 	  {
 	   GlobalFree16(hDragInfo);
 	   return 0L;
@@ -2244,7 +2244,7 @@
     /* update DRAGINFO struct */
     dprintf_msg(stddeb,"drag: lpDI->hScope = %04x\n",lpDragInfo->hScope);
 
-    if( (btemp = (WORD)DRAG_QueryUpdate(hwndScope, spDragInfo)) > 0 )
+    if( (b = DRAG_QueryUpdate(hwndScope, spDragInfo, FALSE)) > 0 )
 	 hCurrentCursor = hCursor;
     else
         {
@@ -2254,7 +2254,7 @@
     if( hCurrentCursor )
         SetCursor(hCurrentCursor);
 
-    dprintf_msg(stddeb,"drag: got %04x\n",btemp);
+    dprintf_msg(stddeb,"drag: got %04x\n", b);
 
     /* send WM_DRAGLOOP */
     SendMessage16( hWnd, WM_DRAGLOOP, (WPARAM16)(hCurrentCursor != hBummer) ,