aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorEli Zaretskii2006-07-22 11:31:55 +0000
committerEli Zaretskii2006-07-22 11:31:55 +0000
commit48b62d105b88f2fa6544181c63034a87a026f633 (patch)
tree6c0eee73305fcf0984cfb8bb35ace846051666aa /src
parent04437a8fe88d416bd6bb3ae5cd8ac42fbd58d962 (diff)
downloademacs-48b62d105b88f2fa6544181c63034a87a026f633.tar.gz
emacs-48b62d105b88f2fa6544181c63034a87a026f633.zip
(w32_createwindow): If `left' and/or `top' frame parameters are bound to some
values, use that instead of CW_USEDEFAULT.
Diffstat (limited to 'src')
-rw-r--r--src/w32fns.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/w32fns.c b/src/w32fns.c
index 66cac34b2d9..68fcced88c2 100644
--- a/src/w32fns.c
+++ b/src/w32fns.c
@@ -2066,6 +2066,7 @@ w32_createwindow (f)
2066{ 2066{
2067 HWND hwnd; 2067 HWND hwnd;
2068 RECT rect; 2068 RECT rect;
2069 Lisp_Object top, left;
2069 2070
2070 rect.left = rect.top = 0; 2071 rect.left = rect.top = 0;
2071 rect.right = FRAME_PIXEL_WIDTH (f); 2072 rect.right = FRAME_PIXEL_WIDTH (f);
@@ -2081,12 +2082,17 @@ w32_createwindow (f)
2081 w32_init_class (hinst); 2082 w32_init_class (hinst);
2082 } 2083 }
2083 2084
2085 /* When called with RES_TYPE_NUMBER, w32_get_arg will return zero
2086 for anything that is not a number and is not Qunbound. */
2087 left = w32_get_arg (Qnil, Qleft, "left", "Left", RES_TYPE_NUMBER);
2088 top = w32_get_arg (Qnil, Qtop, "top", "Top", RES_TYPE_NUMBER);
2089
2084 FRAME_W32_WINDOW (f) = hwnd 2090 FRAME_W32_WINDOW (f) = hwnd
2085 = CreateWindow (EMACS_CLASS, 2091 = CreateWindow (EMACS_CLASS,
2086 f->namebuf, 2092 f->namebuf,
2087 f->output_data.w32->dwStyle | WS_CLIPCHILDREN, 2093 f->output_data.w32->dwStyle | WS_CLIPCHILDREN,
2088 CW_USEDEFAULT, 2094 EQ (left, Qunbound) ? CW_USEDEFAULT : XINT (left),
2089 SW_SHOW, 2095 EQ (top, Qunbound) ? CW_USEDEFAULT : XINT (top),
2090 rect.right - rect.left, 2096 rect.right - rect.left,
2091 rect.bottom - rect.top, 2097 rect.bottom - rect.top,
2092 NULL, 2098 NULL,