diff src/w32fns.c @ 90573:858cb33ae39d

Merge from emacs--devo--0 Patches applied: * emacs--devo--0 (patch 357-381) - Merge from gnus--rel--5.10 - Update from CVS - Merge from erc--emacs--21 * gnus--rel--5.10 (patch 116-122) - Update from CVS - Merge from emacs--devo--0 Revision: emacs@sv.gnu.org/emacs--unicode--0--patch-98
author Miles Bader <miles@gnu.org>
date Thu, 03 Aug 2006 11:45:23 +0000
parents 138ce2701550 0bfda07cccbc
children 7f3f771c85fa
line wrap: on
line diff
--- a/src/w32fns.c	Thu Aug 03 00:41:54 2006 +0000
+++ b/src/w32fns.c	Thu Aug 03 11:45:23 2006 +0000
@@ -2067,6 +2067,7 @@
 {
   HWND hwnd;
   RECT rect;
+  Lisp_Object top, left;
 
   rect.left = rect.top = 0;
   rect.right = FRAME_PIXEL_WIDTH (f);
@@ -2082,12 +2083,17 @@
       w32_init_class (hinst);
     }
 
+  /* When called with RES_TYPE_NUMBER, w32_get_arg will return zero
+     for anything that is not a number and is not Qunbound.  */
+  left = w32_get_arg (Qnil, Qleft, "left", "Left", RES_TYPE_NUMBER);
+  top = w32_get_arg (Qnil, Qtop, "top", "Top", RES_TYPE_NUMBER);
+
   FRAME_W32_WINDOW (f) = hwnd
     = CreateWindow (EMACS_CLASS,
 		    f->namebuf,
 		    f->output_data.w32->dwStyle | WS_CLIPCHILDREN,
-		    CW_USEDEFAULT,
-		    SW_SHOW,
+		    EQ (left, Qunbound) ? CW_USEDEFAULT : XINT (left),
+		    EQ (top, Qunbound) ? CW_USEDEFAULT : XINT (top),
 		    rect.right - rect.left,
 		    rect.bottom - rect.top,
 		    NULL,