repo: rxvt-unicode-sixel
action: commit
revision: 
path_from: 
revision_from: 2c6f74af3343040d69ac83fde635deff8fdd5b64:
path_to: 
revision_to: 
git.thebackupbox.net
rxvt-unicode-sixel
git clone git://git.thebackupbox.net/rxvt-unicode-sixel
commit 2c6f74af3343040d69ac83fde635deff8fdd5b64
Author: Emanuele Giaquinta 
Date:   Fri Oct 22 18:03:10 2010 +0000

    Deobfuscate.

diff --git a/src/background.C b/src/background.C
index 480c7bef3c4f3ff9e615af65bac4333852320677..
index ..7b971ebe0527c8c004becbba3eb417c63c771d65 100644
--- a/src/background.C
+++ b/src/background.C
@@ -1540,8 +1540,6 @@ bgPixmap_t::apply ()
 {
   if (target)
     {
-      flags &= ~isVtOrigin;
-
       if (pixmap != None)
         {
           /* set target's background to pixmap */
@@ -1557,7 +1555,6 @@ bgPixmap_t::apply ()
           else
 # endif
             {
-              flags |= isVtOrigin;
               /* force old pixmap dereference in case it was transparent before :*/
               XSetWindowBackground (target->dpy, target->parent[0], target->pix_colors[Color_border]);
               XSetWindowBackgroundPixmap (target->dpy, target->vt, pixmap);
diff --git a/src/background.h b/src/background.h
index d656f866a9b6036a804ba15e97cc1d836f7c370b..
index ..d5c646dc01678c13ab5736997e5fb3cfb545df2e 100644
--- a/src/background.h
+++ b/src/background.h
@@ -39,8 +39,6 @@ struct bgPixmap_t

     isTransparent   = 1 << 16,
     isInvalid       = 1 << 17,
-    isVtOrigin      = 1 << 18,  /* if set pixmap has origin at corner of
-                                   vt window instead of parent[0]! */
     hasChanged      = 1 << 19,
     sizeSensitive   = 1 << 20,
   };
@@ -54,13 +52,6 @@ struct bgPixmap_t
     transpTransformations = tintNeeded | blurNeeded,
   }; /* these flags are returned by make_transparency_pixmap if called */

-  bool check_clearChanged ()
-  {
-    bool r = flags & hasChanged;
-    flags &= ~hasChanged;
-    return r;
-  };
-
 # ifdef  BG_IMAGE_FROM_FILE
 #  ifdef HAVE_AFTERIMAGE
   ASImage *original_asim;
@@ -130,11 +121,6 @@ struct bgPixmap_t
   bool window_size_sensitive ();
   bool window_position_sensitive ();

-  bool is_parentOrigin ()
-  {
-    return !(flags & isVtOrigin);
-  };
-
   bool need_client_side_rendering ();
   void apply ();
   bool render ();
diff --git a/src/command.C b/src/command.C
index 1eaaf5f1d089dc424ea18ebe0cf9972676c55ac6..
index ..0cfa37af45d540611bbdbd666e8f618837f73283 100644
--- a/src/command.C
+++ b/src/command.C
@@ -977,8 +977,9 @@ rxvt_term::flush ()
   flush_ev.stop ();

 #ifdef HAVE_BG_PIXMAP
-  if (bgPixmap.check_clearChanged ())
+  if (bgPixmap.flags & bgPixmap_t::hasChanged)
     {
+      bgPixmap.flags &= ~bgPixmap_t::hasChanged;
 //      scr_clear (true); This needs to be researched further!
       scr_touch (false);
     }
diff --git a/src/rxvtfont.C b/src/rxvtfont.C
index 0f3761f255932d750991cbb12a3a17462aeb1aa0..
index ..5747a96ea09df54e82f5db5aa9c77f29ae234867 100644
--- a/src/rxvtfont.C
+++ b/src/rxvtfont.C
@@ -1405,7 +1405,7 @@ rxvt_font_xft::draw (rxvt_drawable &d, int x, int y,
             {
               int src_x = x, src_y = y;

-              if (term->bgPixmap.is_parentOrigin ())
+              if (term->bgPixmap.flags & bgPixmap_t::isTransparent)
                 {
                   src_x += term->window_vt_x;
                   src_y += term->window_vt_y;

-----END OF PAGE-----