ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/rxvt-unicode/src/background.C
(Generate patch)

Comparing rxvt-unicode/src/background.C (file contents):
Revision 1.50 by sf-exg, Tue Aug 31 15:14:06 2010 UTC vs.
Revision 1.51 by sf-exg, Wed Sep 1 09:40:08 2010 UTC

642 free (layers); 642 free (layers);
643 } 643 }
644 } 644 }
645 TIMING_TEST_PRINT_RESULT (asim); 645 TIMING_TEST_PRINT_RESULT (asim);
646 646
647 if (pixmap) 647 bool ret = false;
648 {
649 if (result == NULL
650 || pmap_width != new_pmap_width
651 || pmap_height != new_pmap_height
652 || pmap_depth != target->depth)
653 {
654 XFreePixmap (target->dpy, pixmap);
655 pixmap = None;
656 }
657 }
658 648
659 if (result) 649 if (result)
660 { 650 {
661 XGCValues gcv; 651 XGCValues gcv;
662 GC gc; 652 GC gc;
653
654 if (pixmap)
655 {
656 if (pmap_width != new_pmap_width
657 || pmap_height != new_pmap_height
658 || pmap_depth != target->depth)
659 {
660 XFreePixmap (target->dpy, pixmap);
661 pixmap = None;
662 }
663 }
663 664
664 /* create Pixmap */ 665 /* create Pixmap */
665 if (pixmap == None) 666 if (pixmap == None)
666 { 667 {
667 pixmap = XCreatePixmap (target->dpy, target->vt, new_pmap_width, new_pmap_height, target->depth); 668 pixmap = XCreatePixmap (target->dpy, target->vt, new_pmap_width, new_pmap_height, target->depth);
693 if (result != background && result != original_asim) 694 if (result != background && result != original_asim)
694 destroy_asimage (&result); 695 destroy_asimage (&result);
695 696
696 XFreeGC (target->dpy, gc); 697 XFreeGC (target->dpy, gc);
697 TIMING_TEST_PRINT_RESULT (asim); 698 TIMING_TEST_PRINT_RESULT (asim);
699
700 ret = true;
698 } 701 }
699 702
700 if (background) 703 if (background)
701 destroy_asimage (&background); 704 destroy_asimage (&background);
702 705
703 return true; 706 return ret;
704} 707}
705# endif /* HAVE_AFTERIMAGE */ 708# endif /* HAVE_AFTERIMAGE */
706 709
707bool 710bool
708bgPixmap_t::set_file (const char *file) 711bgPixmap_t::set_file (const char *file)

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines