emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] trunk r115416: * frame.h (SET_FRAME_VISIBLE): Now an inlin


From: Paul Eggert
Subject: [Emacs-diffs] trunk r115416: * frame.h (SET_FRAME_VISIBLE): Now an inline function.
Date: Sun, 08 Dec 2013 05:59:31 +0000
User-agent: Bazaar (2.6b2)

------------------------------------------------------------
revno: 115416
revision-id: address@hidden
parent: address@hidden
committer: Paul Eggert <address@hidden>
branch nick: trunk
timestamp: Sat 2013-12-07 21:59:27 -0800
message:
  * frame.h (SET_FRAME_VISIBLE): Now an inline function.
  
  The macro didn't conform to C99 due to type mismatch,
  which caused compilation failure with Sun C 5.12,
  and it was confusing anyway.  Include window.h to declare
  redisplay_other_windows.
modified:
  src/ChangeLog                  changelog-20091113204419-o5vbwnq5f7feedwu-1438
  src/frame.h                    frame.h-20091113204419-o5vbwnq5f7feedwu-229
=== modified file 'src/ChangeLog'
--- a/src/ChangeLog     2013-12-08 03:07:11 +0000
+++ b/src/ChangeLog     2013-12-08 05:59:27 +0000
@@ -1,3 +1,11 @@
+2013-12-08  Paul Eggert  <address@hidden>
+
+       * frame.h (SET_FRAME_VISIBLE): Now an inline function.
+       The macro didn't conform to C99 due to type mismatch,
+       which caused compilation failure with Sun C 5.12,
+       and it was confusing anyway.  Include window.h to declare
+       redisplay_other_windows.
+
 2013-12-08  Stefan Monnier  <address@hidden>
 
        * window.c (set_window_buffer): Update mode line (bug#16084).

=== modified file 'src/frame.h'
--- a/src/frame.h       2013-12-01 22:33:13 +0000
+++ b/src/frame.h       2013-12-08 05:59:27 +0000
@@ -25,6 +25,7 @@
 
 #include "dispextern.h"
 #include "termhooks.h"
+#include "window.h"
 
 INLINE_HEADER_BEGIN
 
@@ -956,10 +957,14 @@
    if some changes were applied to it while it wasn't visible (and hence
    wasn't redisplayed).  */
 
-#define SET_FRAME_VISIBLE(f, v)                                        \
-  (((f)->visible == 0 || ((f)->visible == 2)) && ((v) == 1)    \
-   ? redisplay_other_windows () : 0,                           \
-   (f)->visible = (eassert (0 <= (v) && (v) <= 2), (v)))
+INLINE void
+SET_FRAME_VISIBLE (struct frame *f, int v)
+{
+  eassert (0 <= v && v <= 2);
+  if (v == 1 && f->visible != 1)
+    redisplay_other_windows ();
+  f->visible = v;
+}
 
 /* Set iconify of frame F.  */
 


reply via email to

[Prev in Thread] Current Thread [Next in Thread]