Release 940714

Thu Jul 14 17:50:45 1994  Bob Amstadt  (bob@pooh)

	* [Configure]
	Autodetects Linux version (if running Linux).

	* [loader/signal.c]
	New signals for Linux.

	* [loader/ldtlib.c]
	New structure field in sys call.

Sun Jul 10 19:31:34 1994  Olaf Flebbe  (olaf@dragon)

        * [load/resource.c] 
          fixed Memory (Resource) Leak.

        * [load/main.c] 
          fixed a printf.

Tue Jul 12 18:50:34 1994  Alexandre Julliard  (julliard@lamisun.epfl.ch)

	* [controls/desktop.c]
	Implemented desktop wallpaper (only 16 colors for now).

	* [controls/menu.c] [windows/nonclient.c]
	Preliminary work to allow multi-line menus.

	* [misc/main.c]
	No backing store on desktop window (not useful).

	* [objects/text.c]
	A few fixes to DrawText() to make underlines under mnemonic
	letters to look better.

	* [windows/graphics.c]
	More fixes to GRAPH_DrawArc(), and some fixes to Polygon().
	Implemented PolyPolygon() (partially working).

	* [windows/winpos.c]
	New function WINPOS_SendNCCalcSize().
	Cleaned up SetWindowPos() and added preliminary support for
	multi-line menus.

Mon Jul 11 19:15:51 1994  Miguel de Icaza  (miguel@sphinx)

	* [controls/edit.c]
	Changes to work as a library.

	* [if1632/callback.c] 
	Ifdefed module.

	* [if1632/relay.c]
	Changes to allow linking with WineLib.

	* [include/windows.h]
	Added macro WINELIB_UNIMP

	* [loader/library.c]
	When compiling WineLib, GetProcAddress is not implemented yet.

	* [loader/main.c]
	Added empty InitDLL when using WineLib.

	* [loader/ne_image.c]
	Some parts of the loader are needed for WineLib, ifdefed correctly

	* [misc/{audio.c,mcicda.c,mmaux.c,mmsystem.c]
	Disable compilation of module when compiling WineLib.

	* [toolkit/heap.c]
	Fixed small bug.  When passed an invalid handle WineLib would
	crash, now return NULL.

	* [toolkit/winmain.c]
	Call CreateNewTask in _WinMain.

Sun Jul 10 09:08:02 1994  David Metcalfe <david@prism.demon.co.uk>

	* [controls/edit.c] [controls/widget.c]
	More changes to improve compatibility with Windows' edit
	control.  Finished off tab stop support.

Mon Jul 11 21:05:02 MET DST 1994  Erik Bos <erik@hacktic.nl>

	* [if1632/relay.c]
	# of ordinals in shell.dll changed to 103.

	* [loader/signal.c]
	sti, cli will now be ignored.

	* [objects/brush.c]
	Added stub for GetSysColorBrush().
diff --git a/controls/menu.c b/controls/menu.c
index 7b05747..5e3dee5 100644
--- a/controls/menu.c
+++ b/controls/menu.c
@@ -156,7 +156,7 @@
 									hwnd, lppop->Width, lppop->Height);
 #endif
 			SetWindowPos(hwnd, 0, 0, 0, lppop->Width + 2, lppop->Height, 
-									SWP_NOZORDER | SWP_NOMOVE);
+									SWP_NOZORDER | SWP_NOMOVE | SWP_NOACTIVATE );
 #ifdef DEBUG_MENU
 			printf("PopupMenuWndProc // End of WM_SHOWWINDOW !\n");
 #endif
@@ -1135,7 +1135,7 @@
 #endif
 	hOldFont = SelectObject(hDC, GetStockObject(SYSTEM_FONT));
 	lppop->CheckWidth = 0;
-	LineHeight = OldHeight = SYSMETRICS_CYMENU + 2;
+	LineHeight = OldHeight = SYSMETRICS_CYMENU + 1;
 	SetRect(&rect, lprect->left, lprect->top, 0, lprect->top + LineHeight);
 	lpitem2 = lppop->firstItem;
 	while (lpitem != NULL) {
@@ -1202,6 +1202,29 @@
 
 
 /***********************************************************************
+ *           MENU_GetMenuBarHeight
+ *
+ * Compute the size of the menu bar height. Used by NC_HandleNCCalcSize().
+ */
+WORD MENU_GetMenuBarHeight( HWND hwnd, WORD menubarWidth )
+{
+    HDC hdc;
+    RECT rectBar;
+    WND *wndPtr;
+    LPPOPUPMENU lppop;
+
+    if (!(lppop = PopupMenuGetWindowAndStorage( hwnd, &wndPtr ))) return 0;
+    if (!wndPtr) return 0;
+    hdc = GetDC( hwnd );
+    SetRect( &rectBar, 0, 0, menubarWidth, SYSMETRICS_CYMENU );
+    MenuBarCalcSize( hdc, &rectBar, lppop );
+    ReleaseDC( hwnd, hdc );
+    printf( "MENU_GetMenuBarHeight: returning %d\n", lppop->Height );
+    return lppop->Height;
+}
+
+
+/***********************************************************************
  *           FindMenuItem
  */
 LPMENUITEM FindMenuItem(HMENU hMenu, WORD nPos, WORD wFlags)
@@ -1844,7 +1867,7 @@
 			}
 		}
 	else {
-		ShowWindow(lppop->hWnd, SW_SHOW);
+		ShowWindow(lppop->hWnd, SW_SHOWNOACTIVATE);
 		}
 	if (!lppop->BarFlag) {
 		PopupMenuCalcSize(lppop->hWnd);
@@ -1853,7 +1876,7 @@
 			x, y, lppop->Width, lppop->Height); 
 #endif
 		SetWindowPos(lppop->hWnd, 0, x, y, lppop->Width + 2, lppop->Height, 
-			SWP_NOZORDER);
+			SWP_NOACTIVATE | SWP_NOZORDER);
 		}
 	SetFocus(lppop->hWnd);
 	if (!MenuHasFocus) {
@@ -2208,7 +2231,7 @@
 #endif
 	if (GetCapture() == hWnd) ReleaseCapture();
 	if (wndPtr->window != 0) {
-		flags = SWP_NOZORDER | SWP_NOMOVE | SWP_NOSIZE | SWP_FRAMECHANGED;
+		flags = SWP_NOZORDER | SWP_NOACTIVATE | SWP_NOMOVE | SWP_NOSIZE | SWP_FRAMECHANGED;
 /*		if (!IsWindowVisible(hWnd)) flags |= SWP_NOREDRAW; */
 		flags |= SWP_NOREDRAW;
 		if (hMenu == 0) {