diff options
| author | David Reitter | 2009-05-26 18:14:14 +0000 |
|---|---|---|
| committer | David Reitter | 2009-05-26 18:14:14 +0000 |
| commit | 15891144c8d701999997dedfc6c843ebcd145c3d (patch) | |
| tree | 533114cb8ae41127045f662b2b487d71ebefefce /src/nsfns.m | |
| parent | f2872f04a46404e026afce21904248cbb664bc8c (diff) | |
| download | emacs-15891144c8d701999997dedfc6c843ebcd145c3d.tar.gz emacs-15891144c8d701999997dedfc6c843ebcd145c3d.zip | |
Ensure NS frames remain hidden when invisible
* nsterm.m (ns_raise_frame): only raise frame if visible.
(x_make_frame_visible): move frame to front rather than calling
ns_raise_frame().
(keyDown:) do not swallow events that aren't re-sent if frame
isn't key window.
(drawRect:) do not set visibility/iconified flags because
drawRect may be called by NSView even if the frame is hidden.
* nsfns.m (Fx_create_frame): follow other ports in
determining visibility; default to t. Ensure async_visible is set.
Diffstat (limited to 'src/nsfns.m')
| -rw-r--r-- | src/nsfns.m | 21 |
1 files changed, 14 insertions, 7 deletions
diff --git a/src/nsfns.m b/src/nsfns.m index 01ffcf1181c..5d944593f56 100644 --- a/src/nsfns.m +++ b/src/nsfns.m | |||
| @@ -1317,13 +1317,20 @@ be shared by the new frame. */) | |||
| 1317 | 1317 | ||
| 1318 | if (! f->output_data.ns->explicit_parent) | 1318 | if (! f->output_data.ns->explicit_parent) |
| 1319 | { | 1319 | { |
| 1320 | tem = x_get_arg (dpyinfo, parms, Qvisibility, 0, 0, RES_TYPE_BOOLEAN); | 1320 | tem = x_get_arg (dpyinfo, parms, Qvisibility, 0, 0, RES_TYPE_SYMBOL); |
| 1321 | if (EQ (tem, Qunbound)) | 1321 | if (EQ (tem, Qunbound)) |
| 1322 | tem = Qnil; | 1322 | tem = Qt; |
| 1323 | 1323 | x_set_visibility (f, tem, Qnil); | |
| 1324 | x_set_visibility (f, tem, Qnil); | 1324 | if (EQ (tem, Qicon)) |
| 1325 | if (EQ (tem, Qt)) | 1325 | x_iconify_frame (f); |
| 1326 | [[FRAME_NS_VIEW (f) window] makeKeyWindow]; | 1326 | else if (! NILP (tem)) |
| 1327 | { | ||
| 1328 | x_make_frame_visible (f); | ||
| 1329 | f->async_visible = 1; | ||
| 1330 | [[FRAME_NS_VIEW (f) window] makeKeyWindow]; | ||
| 1331 | } | ||
| 1332 | else | ||
| 1333 | f->async_visible = 0; | ||
| 1327 | } | 1334 | } |
| 1328 | 1335 | ||
| 1329 | if (FRAME_HAS_MINIBUF_P (f) | 1336 | if (FRAME_HAS_MINIBUF_P (f) |