Release 960818
Sun Aug 18 12:17:54 1996 Alexandre Julliard <julliard@lrc.epfl.ch>
* [files/drive.c]
Added 'Filesystem' option in drives configuration.
* [files/dos_fs.c]
Added handling of case-insensitive filesystems.
* [memory/selector.c] [include/stackframe.h]
Removed MAKE_SEGPTR.
* [misc/commdlg.c] [multimedia/mcistring.c]
Replaced MAKE_SEGPTR by the SEGPTR_* macros.
* [objects/bitblt.c] [windows/graphics.c]
Use an intermediary pixmap to avoid some BadMatch errors on
XGetImage().
Sun Aug 18 09:21:27 1996 Albrecht Kleine <kleine@ak.sax.de>
* [windows/message.c]
Added handling of WM_NC...mouse messages in JOURNALRECORD hook.
* [misc/ver.c]
Fixed a bad string result in VerQueryValue[16|32A|32W].
Fri Aug 16 19:55:04 1996 Marcus Meissner <msmeissn@cip.informatik.uni-erlangen.de>
* [if1632/crtdll.spec] [misc/crtdll.c]
More additions to get win95 programs further down the road.
* [if1632/kernel.spec] [loader/module.c]
GetModuleName() added.
LoadModule(): params->showCmd can be NULL.
* [if1632/kernel32.spec] [if1632/thunk.c]
ThunkConnect32() stub added.
* [loader/resource.c]
Entries include lastentry.
* [misc/shell.c] [files/file.c]
Made progman work again.
Fri Aug 16 09:00:00 1996 Alex Korobka <alex@phm30.pharm.sunysb.edu>
* [windows/defwnd.c] [windows/winpos.c] [windows/painting.c]
Icon painting fixes.
* [windows/winpos.c] [windows/painting.c]
Enforce and follow hrgnUpdate more closely to cut down on
redundant RedrawWindow() calls.
* [windows/event.c]
Process ConfigureNotify only for managed windows.
* [windows/winpos.c]
Do not redraw parent if the window was hidden before SetWindowPos().
* [windows/nonclient.c]
Omit some nonclient decoration painting for managed windows.
* [controls/menu.c] [windows/mdi.c] [windows/nonclient.c]
Implemented WM_NEXTMENU.
* [controls/listbox.c]
Multicolumn listboxes return WVR_VREDRAW on WM_NCCALCSIZE.
* [misc/shell.c]
Added .ICO file handling to ExtractIcon().
diff --git a/windows/win.c b/windows/win.c
index 63e8564..95e7923 100644
--- a/windows/win.c
+++ b/windows/win.c
@@ -224,7 +224,11 @@
HWND hwndRet;
WND *pWnd = pWndDesktop;
- /* Note: the desktop window never gets WM_PAINT messages */
+ /* Note: the desktop window never gets WM_PAINT messages
+ * The real reason why is because Windows DesktopWndProc
+ * does ValidateRgn inside WM_ERASEBKGND handler.
+ */
+
pWnd = hwnd ? WIN_FindWndPtr( hwnd ) : pWndDesktop->child;
for ( ; pWnd ; pWnd = pWnd->next )
@@ -265,7 +269,7 @@
* Send a WM_PARENTNOTIFY to all ancestors of the given window, unless
* the window has the WS_EX_NOPARENTNOTIFY style.
*/
-void WIN_SendParentNotify( HWND32 hwnd, WORD event, WORD idChild, LONG lValue )
+void WIN_SendParentNotify(HWND32 hwnd, WORD event, WORD idChild, LPARAM lValue)
{
LPPOINT16 lppt = (LPPOINT16)&lValue;
WND *wndPtr = WIN_FindWndPtr( hwnd );
@@ -274,10 +278,7 @@
/* if lValue contains cursor coordinates they have to be
* mapped to the client area of parent window */
- if (bMouse) MapWindowPoints16(0, hwnd, lppt, 1);
-#ifndef WINELIB32
- else lValue = MAKELONG( LOWORD(lValue), idChild );
-#endif
+ if (bMouse) MapWindowPoints16( 0, hwnd, lppt, 1 );
while (wndPtr)
{
@@ -291,12 +292,8 @@
}
wndPtr = wndPtr->parent;
-#ifdef WINELIB32
SendMessage32A( wndPtr->hwndSelf, WM_PARENTNOTIFY,
MAKEWPARAM( event, idChild ), lValue );
-#else
- SendMessage16( wndPtr->hwndSelf, WM_PARENTNOTIFY, event, (LPARAM)lValue);
-#endif
}
}
@@ -364,7 +361,6 @@
BOOL32 WIN_CreateDesktopWindow(void)
{
CLASS *class;
- HDC hdc;
HWND hwndDesktop;
dprintf_win(stddeb,"Creating desktop window\n");
@@ -415,11 +411,7 @@
WINPROC_SetProc( &pWndDesktop->winproc, (WNDPROC16)class->winproc, 0 );
EVENT_RegisterWindow( pWndDesktop );
SendMessage32A( hwndDesktop, WM_NCCREATE, 0, 0 );
- if ((hdc = GetDC( hwndDesktop )) != 0)
- {
- SendMessage32A( hwndDesktop, WM_ERASEBKGND, hdc, 0 );
- ReleaseDC( hwndDesktop, hdc );
- }
+ pWndDesktop->flags |= WIN_NEEDS_ERASEBKGND;
return TRUE;
}
@@ -705,7 +697,7 @@
wndPtr->rectClient.top ));
}
- WIN_SendParentNotify( hwnd, WM_CREATE, wndPtr->wIDmenu, (LONG)hwnd );
+ WIN_SendParentNotify( hwnd, WM_CREATE, wndPtr->wIDmenu, (LPARAM)hwnd );
if (!IsWindow(hwnd)) return 0;
/* Show the window, maximizing or minimizing if needed */
@@ -904,7 +896,7 @@
SWP_NOZORDER | SWP_NOMOVE | SWP_NOSIZE );
if ((hwnd == GetCapture()) || IsChild( hwnd, GetCapture() ))
ReleaseCapture();
- WIN_SendParentNotify( hwnd, WM_DESTROY, wndPtr->wIDmenu, (LONG)hwnd );
+ WIN_SendParentNotify( hwnd, WM_DESTROY, wndPtr->wIDmenu, (LPARAM)hwnd );
CLIPBOARD_DisOwn( hwnd );
@@ -1543,8 +1535,29 @@
return (wndPtr && (wndPtr->dwStyle & WS_VISIBLE));
}
-
-
+/***********************************************************************
+ * WIN_IsWindowDrawable
+ *
+ * hwnd is drawable when it is visible, all parents are not
+ * minimized, and it is itself not minimized unless we are
+ * trying to draw icon and the default class icon is set.
+ */
+BOOL32 WIN_IsWindowDrawable( WND* wnd , BOOL32 icon )
+{
+ HWND hwnd= wnd->hwndSelf;
+ BOOL32 yes = TRUE;
+
+ while(wnd && yes)
+ {
+ if( wnd->dwStyle & WS_MINIMIZE )
+ if( wnd->hwndSelf != hwnd ) break;
+ else if( icon && wnd->class->hIcon ) break;
+
+ yes = yes && (wnd->dwStyle & WS_VISIBLE);
+ wnd = wnd->parent; }
+ return (!wnd && yes);
+}
+
/*******************************************************************
* GetTopWindow (USER.229)
*/
@@ -1824,8 +1837,8 @@
}
else
{
- RedrawWindow32( hWnd, 0, 0, RDW_INVALIDATE | RDW_ERASE |
- RDW_UPDATENOW | RDW_FRAME );
+ PAINT_RedrawWindow( hWnd, 0, 0, RDW_INVALIDATE | RDW_ERASE |
+ RDW_UPDATENOW | RDW_FRAME, 0 );
wndPtr->flags &= ~WIN_NCACTIVATED;
}
return TRUE;