emacs-diffs
[Top][All Lists]
Advanced

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

feature/pgtk 3e20d50 2/2: Revert #if changes


From: Yuuki Harano
Subject: feature/pgtk 3e20d50 2/2: Revert #if changes
Date: Sat, 13 Nov 2021 02:45:11 -0500 (EST)

branch: feature/pgtk
commit 3e20d50fc5a8fc94b571e140a696ccd65040e6c1
Author: Yuuki Harano <masm+github@masm11.me>
Commit: Yuuki Harano <masm+github@masm11.me>

    Revert #if changes
    
    I changed some "#ifdef"s to "#if defined"s by mistake, so I reverted them.
    
    * src/alloc.c: Reverted.
    (garbage_collect): Reverted.
    * src/emacs.c (main): Reverted.
    * src/image.c (xpm_load_image): Reverted.
    (image_disable_image): Reverted.
    (image_build_heuristic_mask): Reverted.
---
 src/alloc.c |  4 ++--
 src/emacs.c |  2 +-
 src/image.c | 12 ++++++------
 3 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/src/alloc.c b/src/alloc.c
index 2d25f82..9388cf1 100644
--- a/src/alloc.c
+++ b/src/alloc.c
@@ -96,7 +96,7 @@ along with GNU Emacs.  If not, see 
<https://www.gnu.org/licenses/>.  */
 #include <unistd.h>
 #include <fcntl.h>
 
-#if defined(USE_GTK)
+#ifdef USE_GTK
 # include "gtkutil.h"
 #endif
 #ifdef WINDOWSNT
@@ -6148,7 +6148,7 @@ garbage_collect (void)
   mark_pgtkterm();
 #endif
 
-#if defined(USE_GTK)
+#ifdef USE_GTK
   xg_mark_data ();
 #endif
 
diff --git a/src/emacs.c b/src/emacs.c
index 925f167..790740d 100644
--- a/src/emacs.c
+++ b/src/emacs.c
@@ -2287,7 +2287,7 @@ Using an Emacs configured with --with-x-toolkit=lucid 
does not have this problem
 #ifdef HAVE_DBUS
   init_dbusbind ();
 #endif
-#if defined(USE_GTK)
+#ifdef USE_GTK
 #ifndef HAVE_PGTK
   init_xterm ();
 #endif
diff --git a/src/image.c b/src/image.c
index f911da5..d03e16e 100644
--- a/src/image.c
+++ b/src/image.c
@@ -5088,7 +5088,7 @@ xpm_load_image (struct frame *f,
     }
 
   if (!image_create_x_image_and_pixmap (f, img, width, height, 0, &ximg, 0)
-#if !defined(HAVE_NS)
+#ifndef HAVE_NS
       || !image_create_x_image_and_pixmap (f, img, width, height, 1,
                                           &mask_img, 1)
 #endif
@@ -5216,7 +5216,7 @@ xpm_load_image (struct frame *f,
 
          PUT_PIXEL (ximg, x, y,
                     FIXNUMP (color_val) ? XFIXNUM (color_val) : frame_fg);
-#if !defined(HAVE_NS)
+#ifndef HAVE_NS
          PUT_PIXEL (mask_img, x, y,
                     (!EQ (color_val, Qt) ? PIX_MASK_DRAW
                      : (have_mask = true, PIX_MASK_RETAIN)));
@@ -5237,7 +5237,7 @@ xpm_load_image (struct frame *f,
     IMAGE_BACKGROUND (img, f, ximg);
 
   image_put_x_image (f, img, ximg, 0);
-#if !defined(HAVE_NS)
+#ifndef HAVE_NS
   if (have_mask)
     {
       /* Fill in the background_transparent field while we have the
@@ -5968,7 +5968,7 @@ image_disable_image (struct frame *f, struct image *img)
   if (n_planes < 2 || cross_disabled_images)
     {
 #ifndef HAVE_NTGUI
-#if !defined(HAVE_NS)  /* TODO: NS support, however this not needed for 
toolbars */
+#ifndef HAVE_NS  /* TODO: NS support, however this not needed for toolbars */
 
 #ifndef USE_CAIRO
 #define CrossForeground(f) BLACK_PIX_DEFAULT (f)
@@ -6046,7 +6046,7 @@ image_build_heuristic_mask (struct frame *f, struct image 
*img,
     image_clear_image_1 (f, img, CLEAR_IMAGE_MASK);
 
 #ifndef HAVE_NTGUI
-#if !defined HAVE_NS
+#ifndef HAVE_NS
   /* Create an image and pixmap serving as mask.  */
   if (! image_create_x_image_and_pixmap (f, img, img->width, img->height, 1,
                                         &mask_img, 1))
@@ -6108,7 +6108,7 @@ image_build_heuristic_mask (struct frame *f, struct image 
*img,
       if (XGetPixel (ximg, x, y) == bg)
         ns_set_alpha (ximg, x, y, 0);
 #endif /* HAVE_NS */
-#if !defined HAVE_NS
+#ifndef HAVE_NS
   /* Fill in the background_transparent field while we have the mask handy. */
   image_background_transparent (img, f, mask_img);
 



reply via email to

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